4 ms·
> You would need something else in the mix to generate some nonlinearity, like integer addition, multiplication, etc. Worth noting that bitwise AND also works
by a1369209993 5y ago
> You would need something else in the mix to generate some nonlinearity, like integer addition, multiplication, etc.
Worth noting that bitwise AND also works (indeed, you can build addition from it), if you don't want to implement anything that operates on bits in non-parallel for some reason. (Which is to say/emphasize that it's linear GF(2) operations that are insufficient, not GF(2) operations in general.)
- pbsd 5y agoYeah that is true. Also you could still stick with xor and shift/rotate, but make the shifts data-dependent. That would make it nonlinear (technically a multiplication), but analysis is generally more difficult.
- a1369209993 5y ago> but make the shifts data-dependent Ah, yes; cryptography usually assumes only fixed-amount shifts since some early shifters were non-contant-time, but variable-amount shifts are a thing you can do (and don't necessarily have side-channel problems on modern hardware).