Introduction to the

Feistel Cipher, also known as luby-Rackoff block cipher, is a symmetric structure used to construct block encryption algorithms. It was invented by Horst Feistel, a German cryptographer, while working at IBM. Feistel Cipher is also known as feistel network.

Many block encryption algorithms are developed on the basis of Feistel ciphers, such as the famous DES algorithm.

In feistel ciphers, the encryption and decryption operations are very similar, usually requiring multiple rounds of encryption and decryption.

Feistel Network principle

Feistel networks use a round function, also known as the round function. This function takes two input parameters, the block data (half of the original data) and the subkey, and generates the same length of the block data.

The XOR XOR operation is then performed using the data generated in the previous round and the other half of the original data as input to the next round function.

And so you go round and round and you end up with encrypted data.

The decryption process is similar to the encryption process, but the encryption process is reversed.

Feistel The number of rounds on a network can be increased arbitrarily. No matter how many rounds can be decrypted normally.

Decryption is independent of the round function f, and the round function F does not need to have an inverse function. The round function can be designed to be replicated enough.

Encryption and decryption can be implemented using exactly the same structure. As we can see from the above, there is no difference between encryption and decryption.

Example of Feistel network

Let’s use a diagram to illustrate Feistel’s workflow:

In the figure above, F represents the round function, or round function.

K0,K1,K2… Kn represents the sub-key, which serves as the input of each round.

The raw data is divided into equal parts, (L0,R0).

Each round does the following:

  • Li+1 = Ri

  • Ri+1 = Li XOR F(Ri,Ki)

The final result of the encryption is Ri+1,Li+1.

The decryption process is the reverse of the encryption process. Each round of decryption will carry out the following operations:

  • Ri = Li+1

  • Li = Ri+1 XOR F(Li+1,Ki)

And we end up with our raw data (R0,L0).

Theoretical research on Feistel networks

Michael Luby and Charles Rackoff showed that if the round function is a cryptographically secure pseudo-random function with Ki as the seed, then after three rounds of operation, the generated block cipher is already pseudo-random. A “strong” pseudo-random permutation can be generated after four rounds of operation.

What is a pseudo-random number?

Think about generating random numbers in a computer. Because the data in a computer is made up of zeros and ones, all the data is deterministic, either zero or one, so a computer program can’t really generate random numbers.

If you want a computer to generate random numbers, the usual way is to calculate the input through a certain algorithm function, so as to get the processed number.

If the algorithm function is deterministic, that is, the same input can produce the same output, then the number is not randomly generated and is called a pseudo-random number.

Pseudorandom is a sequence of random numbers uniformly distributed from [0,1] calculated by a deterministic algorithm. Not really random, but with statistical characteristics similar to random numbers, such as uniformity, independence, etc.

Because of the importance of Luby and Rackoff research, Feistel passwords are also known as Luby-Rackoff passwords.

Feistel network expansion

In addition to DES, many algorithms use Feistel network structures, such as Blowfish, Twofish, and so on.

Because of the symmetrical nature of Feistel network and simple operation, making it very simple to achieve Feistel network by hardware, so Feistel network is very widely used.

This article is available at www.flydean.com/feistel-cip…

The most popular interpretation, the most profound dry goods, the most concise tutorial, many tips you didn’t know waiting for you to discover!

Welcome to pay attention to my public number: “procedures those things”, understand technology, more understand you!