Modern Block Cipher Standards (DES) : Debdeep Mukhopadhyay
Modern Block Cipher Standards (DES) : Debdeep Mukhopadhyay
Modern Block Cipher Standards (DES) : Debdeep Mukhopadhyay
(DES)
Debdeep Mukhopadhyay
Assistant Professor
Department of Computer Science and
Engineering
Indian Institute of Technology Kharagpur
INDIA -721302
DES Numerology
Initial Permutations
DES has an initial permutation and a final
permutation after 16 rounds.
These permutations are inverses of each
other and operate on 64 bits.
They have no cryptographic significance.
The designers did not disclose their
purpose.
key
R
32
28
expand
32
28
shift
48
28
Ki
48
48
S-boxes
shift
28
compress
28
28
32
32
Function f
P box
32
One
Round
of
DES
32
key
DES Expansion
Input 32 bits
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Output 48 bits
31 0 1 2 3 4 3 4 5 6 7 8
7 8 9 10 11 12 11 12 13 14 15 16
15 16 17 18 19 20 19 20 21 22 23 24
23 24 25 26 27 28 27 28 29 30 31 0
| 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111
-----------------------------------------------------------------------------------00 | 1110 0100 1101 0001 0010 1111 1011 1000 0011 1010 0110 1100 0101 1001 0000 0111
01 | 0000 1111 0111 0100 1110 0010 1101 0001 1010 0110 1100 1011 1001 0101 0011 1000
10 | 0100 0001 1110 1000 1101 0110 0010 1011 1111 1100 1001 0111 0011 1010 0101 0000
11 | 1111 1100 1000 0010 0100 1001 0001 0111 0101 1011 0011 1110 1010 0000 0110 1101
Column=0100=4
Output 32 bits
15 6 19 20 28 11 27 16 0 14 22 25 4 17 30 9
1 7 23 13 31 26 2 8 18 12 29 5 21 10 3 24
DES Subkey
Input key size: 64 bits, of which 8 are parity
bits.
56 bit DES key, 0,1,2,,55
Left half key bits, LK
49 42 35 28 21 14 7
0 50 43 36 29 22 15
8 1 51 44 37 30 23
16 9 2 52 45 38 31
DES Subkey
For rounds i=1,2,....,n
Let LK = (LK circular shift left by ri)
Let RK = (RK circular shift left by ri)
Left half of subkey Ki is of 24 bits
13 16 10 23 0 4 2 27 14 5 20 9
22 18 11 3 25 7 15 6 26 19 12 1
DES Subkey
For rounds 1, 2, 9 and 16 the shift ri is 1, and in
all other rounds ri is 2
Bits 8,17,21,24 of LK omitted each round
Bits 6,9,14,25 of RK omitted each round
Compression permutation yields 48 bit subkey
Ki from 56 bits of LK and RK
Key schedule generates subkey
Exercise
Prove that decryption in DES can be done
by applying the encryption algorithm to the
ciphertext, with the key schedule reversed.
Weak keys
A weak key is the one which after parity
drop operation, consists either of all 0s, all
1s or half 0s and half 1s.
Four out of the 256 keys are weak keys.
Actual key
(56 bits)
0000000 0000000
0000000 FFFFFFF
FFFFFFF 0000000
10
9153E54319BD
6EAC1ABCE642
6EAC1ABCE642
9153E54319BD
6EAC1ABCE642
9153E54319BD
9153E54319BD
6EAC1ABCE642
6EAC1ABCE642
9153E54319BD
6EAC1ABCE642
9153E54319BD
6EAC1ABCE642
9153E54319BD
6EAC1ABCE642
9153E54319BD
9153E54319BD
6EAC1ABCE642
10
9153E54319BD
6EAC1ABCE642
11
9153E54319BD
6EAC1ABCE642
12
9153E54319BD
6EAC1ABCE642
6EAC1ABCE642
13
9153E54319BD
14
9153E54319BD
6EAC1ABCE642
15
9153E54319BD
6EAC1ABCE642
16
6EAC1ABCE642
9153E54319BD
Multiple DES
The major criticism against DES is the key
length.
So, we may try cascading several DES
applications.
Luckily, DES does not form a group under
the composition operation. Thus, it is highly
improbable that we can obtain k3 st.
Ek2(Ek1(P))=Ek3(P)
11
2DES
Uses two applications of the DES cipher.
The total key size is 56x2=112 bits.
However 2DES is vulnerable to a known
plaintext attack.
DES
cipher
middle text
DES
cipher
64 bit ciphertext
12
Security of 2 DES
Then the attacker checks for a match in the table
in the value of M. He notes the key pair (K1,K2)
If there are more than one keys, he takes another
(P,C) pair.
The attacker continues until there is only key left.
Thus attack complexity is around 257.
What does this say about the security of 2DES?
Triple DES
Since 2DES was a bad design, people
consider 3 applications of DES.
The first and third stages use K1 as key.
The second stage use K2 as the key.
Also, the middle stage uses decryption.
Thus, setting K1=K2 we have simple DES.
13
Clefia:
128 bit block
cipher
designed by
Sony
Corporation
Further Reading
B. A Forouzan, Cryptography & Network
Security, Tata Mc Graw Hills, Chapter 5
Douglas Stinson, Cryptography Theory and
Practice, 2nd Edition, Chapman &
Hall/CRC
14
Exercises
Exercises
15
Exercises
16