6 Block Cipher Cryptosystems
6 Block Cipher Cryptosystems
.Prof. Dr
Qasim Mohammed Hussein
Block cipher
• A block cipher is a symmetric encryption that
operates on a plaintext block of n bits to
produce a ciphertext block of n bits.
• Typically, a block size of 64 or a block128 bits is
used There are 2n possible different plaintext
blocks and, for the encryption to be reversible,
each must produce a unique ciphertext block.
• Such a transformation is called reversible, or
nonsingular
Block cipher
Block cipher
• A nonsingular and singular transformations for n = •
2 illustrate as
• DES Example:
• http://page.math.tu-berlin.de/~
kant/teaching/hess/krypto-ws2006/des.htm
XOR & Substitution Boxes
• XOR (Whitener). The XOR operation on the
expanded right section and the round key.
• Substitution Boxes. S-boxes carry out the real
mixing (confusion). DES uses 8 S-boxes, each
with a 6-bit input and a 4-bit output.
S-boxes
• There are a total of eight S-box tables. The
output of all eight s-boxes is then combined in
to 32 bit section.
S-boxes
Straight Permutation :32-bit output of S-boxes
is then subjected to the straight permutation
with following rule.
Key Generation
• The round-
key generator
creates
sixteen 48-bit
keys out of a
56-bit cipher
key.
DES Analysis
• The DES satisfies both the desired properties of block
cipher that make cipher very strong.
• Avalanche effect : A small change in plaintext results
in the very great change in the ciphertext.
• Completeness :Each bit of ciphertext depends on
many bits of plaintext.
• During the last few years, cryptanalysis have found
some weaknesses in DES when key selected are weak
keys. These keys shall be avoided.
• There have been no significant cryptanalytic attacks
on DES other than exhaustive key search.
DES example
• There is an example about how DES Works in
Detail, it is available at the link:
• https://
uomustansiriyah.edu.iq/media/lectures/9/9_2
018_12_30!04_26_44_PM.pdf
Triple DES
• There are two variants of Triple DES known as
3-key Triple DES (3TDES) and 2-key Triple DES
(2TDES).
• Before using 3TDES, user first generate three
different DES keys K1, K2 and K3 , length 3×56 =
168 bits.
Triple DES
TDES encryption-decryption process
• Encrypt the plaintext blocks using single DES with
key K1.
• Decrypt the output of step 1 using single DES with
key K2.
• Finally, encrypt the output of step 2 using single
DES with key K3.
• The output of step 3 is the ciphertext.
• Decryption of a ciphertext is a reverse process.
User first decrypt using K3, then encrypt with
K2, and finally decrypt with K1.
Advanced Encryption Standard (AES)
• The more popular and widely adopted
symmetric encryption algorithm is the
Advanced Encryption Standard (AES).
• The features of AES are as follows −
• Symmetric key symmetric block cipher
• 128-bit data, 128/192/256-bit keys
• Stronger and six time faster than Triple-DES
• Provide full specification and design details
• Software implementable in C and Java
AES
• AES performs all its computations on bytes rather than
bits.
• AES treats the 128 bits of a plaintext block as 16 bytes.
• The 16 bytes are arranged in four columns and four
rows for processing as a matrix.
• Number of rounds in AES is variable and depends on
the length of the key.
• AES uses 10 rounds for 128-bit keys, 12 rounds for 192-
bit keys and 14 rounds for 256-bit keys.
• Each of these rounds uses a different 128-bit round key,
which is calculated from the original AES key.
AES structure
AES Encryption Process
If last round
outputciphertext
Else go to next
round