# Are SHA-2's $\mathit{Maj}$ and $\mathit{Ch}$ functions non-linear?

SHA-2 has two functions:

$\mathit{Maj}(x, y, z) = (x \land y) \oplus (y \land z) \oplus (x \land z)$

$\mathit{Ch}(x, y, z) = (x \land y) \lor (\neg x \land z)$

Are these two functions non-linear? Can they be used in place of S-boxes in block ciphers?

• Write them out as arithmetic in GF(2): $x \land y = x \cdot y$ (since $(0, 0) \mapsto 0$, $(0, 1) \mapsto 0$, $(1, 0) \mapsto 0$, $(1, 1) \mapsto 1$), $a \oplus b = a + b$, etc. Does that help answer your question? – Squeamish Ossifrage Dec 10 '17 at 18:49
• @SqueamishOssifrage No. – Melab Dec 10 '17 at 19:09