Consider the following 2x2 s-box
x | S(x)
0 | 3
1 | 1
2 | 0
3 | 2
Consider 2-round SPN (substitution-permutation network) with a block length of 4 bits. If the key mixing is done using a mod-4 addition operation before each round and after the last round, determine the ciphertext corresponding to the message m=15.
Assume the round keys as k1=11, k2=10, and k3=7.
Mod-4 operation is to solved by picking two bits blocks each time and treating them individually without propagating carry forward to next set of two bits blocks.
Numbers, in brackets below, indicate the corresponding 4 bits representation of message and key values.
Bits are numbered from right(0) to left(3).
X10 indicates 2 bits value formed from (bit1 bit0) and X32 indicates 2 bits value formed from (bit3 bit2). Same is the case with Y10, ...
Solution gives detailed step-by-step computation in the sequence "key mixing, first round, key mixing, second round, key mixing".