3 ms·
I think it is better to call this a noncommutative operation and phrase it as such. Duals are often in fact, different things. But I think what you are doing i
by mikorym 6y ago
I think it is better to call this a noncommutative operation and phrase it as such. Duals are often in fact, different things.
But I think what you are doing is pretty cool! I don't know much about machine code, but whenever XOR becomes noncommutative, for whatever reason, but executes commutatively, then this should become possible.
Of course, by the way, XOR also has the vanilla ability to reveal information through: plaintext XOR cypher = cyphertext and then you do cyphertext XOR cypher to get back plaintext. In this case, XOR is commutative, as we are only looking at execution, and moreover each binary string is it's own inverse: thing XOR thing = 0-string. So, you can think of XOR as reversible sequences of encypherment.
- saagarjha 6y agoI'm not sure what xor's commutativity has to do with this?
- mikorym 6y agoOP is treating XOR as though it were not commutative between registers and memory: > Consequently, there are actually two ways to encode xor eax, eax: ; r/m32, r 31 C0 ; r, r/m32 33 C0 So, what I am saying is that write(memory,register) != write(register,memory) in the byte code, meaning that writing the XOR itself is a noncommutative operation. The machine running the code does however treat both option ultimately to get the same result. The XOR algorithm remains unchanged and remains commutative. The execution routine of the XOR is noncommutative. So, there are two operations here: XOR and executeXOR and OPs article is about using the machine level noncommutativity in the form of different byte strings for executeXOR. The machine still thinks that is is commutative for the end result of the calculation/routine. My comment about cypher XOR plaintext = cyphertext is just a general comment about XOR.
- woodruffw 6y agoI think you might have misunderstood the modr/m encoding: steg86 never touches memory-register or register-memory operations, only register-register ones. Nothing about this either requires or implies commutativity.
- mikorym 6y agoAlright, but the principle still holds: You have some action act(x,y). The encoding in the bitstream can either differ for act(x,y) or act(y,x) or it is the same. The original article states that the effect of act(x,y) and act(y,x) is the same. But the bitstream may differ. So it is commutative in the operations of the computer, but not in the bitstream instruction.