Another type of algorithms upbraids always on blocks of specified length.
For example it always encrypts 56 bit or 128 bit blocks this type is called block ciphers most symmetric
ciphers belong to the block type they're more secure than and just as efficient as stream ciphers many
symmetric blocks surfers follow the same structure and utilize the same method for repeating operations
round's they use Feistel network
architecture of this network can be seen in the schema below.
Since the network is based on the assumption that the plaintext has a fixed length.
You need to split it into blocks first while it's good that the cipher encodes 128 bits an email that
you want to encode is shorter than that size.
You need to split the email in some way into 128 bit blocks.
The transformation method depends on the block cipher mode of operation which will be covered later.
Why is Feistel network so popular.
Its structure relies on dividing the plain text block in the halves and then performing a function f
on one part of the plaintext
The output will be combined with the other part of the plaintext and their positions will be switched
left to right right into left.
We switched the message and the blocks
you know already that block ciphers operate on message blocks a specified length.
When one part is transformed by the function f this is the encryption we connect the encryption result
with the remaining part
mix the two part switch positions and the operation is repeated.
What makes this solution so simple and popular this method works with any function even if the function
is irreversible
a message is split into two halves and one part is encoded.
What's crucial here is that a round key is used for the encryption.
If you flip the order of the two parts and go back to the start the internal key will be different.
The key will be the second round's key
the calculated encrypted result is combined using the x our function this again gives us two halves
decryption is parallel which means the operation is symmetric.
It's again enough to define the plaintext into two parts and perform the function f on one half using
around key the output then should be so hard and repeated in as many rounds as required.
The solution doesn't guarantee security.
It's simply a mechanism a mode of operation or a transformation method.
The security as such is only provided by the function f it has critical importance in the structure.
So why should you introduce into this network the function has to mix bits to achieve a non-linear relationship
between the ciphertext and the plain text message.
This is the most crucial and the hardest part the image above shows substitution tables X-boxes they're
actually the substitution tables used in the D.S. algorithm the algorithm will be covered at length
in a moment but let's flesh out this example now when talking about mixing How can a non linear relationship
be discovered.
Note that if you take a look at the values at the intersection of columns and rows it's difficult to
see why h should be at the intersection of the second row and third column or Y-12 is at the intersection
of the third row and first column.
The relationship is non-linear.
If you submitted row and column numbers and looked up the values in the cells this would be a non-linear
relationship between the plain text used to generate coordinates and the ciphertext the output that
set the intersection substitution tables are used in almost all symmetric key block ciphers.
It would be helpful if our function f performed permutation or flipped bits it could be used to obscure
some relationships
the function should also exhibit the avalanche effect so that the change of a small amount of plaintext
bits Ideally one bit would be demonstrated in the significant change of as many ciphertext bits as possible.
Ideally all bits should change.
This can provide the cryptographic system with some immunity to a certain category of attacks to attacks
that manipulate the plaintext.
If an attacker can provide any input into a system they're able to observe how encryption is applied
and draw some conclusions.
If you maximize the diffusion the task will be much harder to pull off.
The function f must also provide compression to let the Feistel round operate the final ciphertext has
to be as long as the initial plaintext.