Documente Academic
Documente Profesional
Documente Cultură
The input 32-bits are expanded to 48 bits in the Expansion P-Box module in the following
way
4 4 4 4 4 4 4 4
6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6
+ + + + + + + +
S1 S2 S3 S4 S5 S6 S7 S8
The permutation produces
“spread” among the
4 4 4 4 4 4 4 4
chunks/S-boxes!
Permutation
Each S-box uses a corresponding 4 row by 16 column table i.e. 8 tables.
Given a 6-bit input, the 1st and the 6th bits are used to address one of the
rows and the remaining 4 bits are used to address one of the 16 columns.
Finally, the value found in the corresponding location of the table is the
4bit output of the S-box
S-Box (Substitute and Shrink)
• 48 bits ==> 32 bits. (8*6 ==> 8*4)
• 2 bits used to select amongst 4 substitutions for the
rest of the 4-bit quantity
2 bits I1
row I2
O1
I3 Si O2
I4 O3
I5 O4
4 bits I6
column i = 1,…8.
S-Box Examples
Each row and column contain different numbers.
0 1 2 3 4 5 6 7 8 9…. 15
0 14 4 13 1 2 15 11 8 3
1 0 15 7 4 14 2 13 1 10
2 4 1 14 8 13 6 2 11 15
3 15 12 8 2 4 9 1 7 5
The parity drop module drops the parity bits (bits 8,16,24,..,64) from
the 64-bit key and permutes the rest of the 56 bits according to the
parity drop table.
The Compression permutation module changes the 56 bits to 48 bits
using the key compression table, which are used as the key for a
round.