January 6, 2016
Block Cipher Encryption Method
January 6, 2016
Feistel Cipher consists of a number of identical rounds of processing. In each round, a substitution is preformed on one half of data being processed followed by a permutation that interchanges the two halves. The original key is expanded so that a different key is used for each round.
image courtesy of AmirkiFeistel Encryption Algorithm:The Feistel Encryption Algorithm (the left hand side): inputs to a encryption algorithm are a plaintext block of length - 2w bits and key K.The plaintext is divided into two halves Lo and Ro, which pass through n rounds of processing. Each round i has inputs - Li-1 and Ri-1. Then, they're combined to produce the ciphertext block.The subkey Ki is derived from the overall K; Ki is different from K and from each other. Feistel Cipher actually performs two operations:1- A substitution is performed on the left half of data by applying a round function F to the right half of data, then by doing XOR the output of round function F with the left half of data.The round function F has the same structure every round, but there's a change in parameter subkey Ki for each round.2- A permutation is performed, which consists of interchanges on the two halves of data.Feistel Cipher structure is form of substitution permutation network (SPN). Feistel Decryption Algorithm:Feistel Decryption Algorithm (the right hand side): inputs to decryption algorithm are ciphertext and subkey Ki but in reverse order. It starts start with Kn then Kn-1 ans so on until K1 in the last round.Note#1: At every round the value of encryption algorithm is equal to the corresponding value(n-ith) of decryption algorithm, but the two halves are swapped.For example, in a system with 16 rounds, the value of 5th round in encryption algorithm is equal to the value of 12th round of decryption algorithm, but L and R are swapped.Note#2: The round function F is not required to be a reversible function. Feistel Cipher Parameters and Design Features:1- Block size: Large block size means greater, but reduced encryption and decryption speed.2- Key size: Large key size mean greater security, but may also reduce the encryption and decryption speed.3- Number of rounds: Increasing security can be achieved by increasing the number of rounds.4- Round Function F: Increasing the complexity of round function F increasing the resistance to cryptanalysis.5- Subkey generation algorithm: Increasing of complexity here also increases the resistance to cryptanalysis. Thanks and I hope this was useful to you!