Symmetric Cryptography
Create simple round function
As you can see in picture basic operation splits the plaintext block into two equal pieces and applies round function F to one half on each round.
In your round function you can use opearations like:
- Y = X ^ V
- Y = Table [X, V
- Y = X <<V
- cyclic shift to left
- cyclic shift to right
- Y = X >>V
- Y = (X * V) % Math.Pow(2, N)
We set Block Size to 32 bits, so we should create round function F that gets 16 bits positive integer and returns the same data type.
Lets implement simple round function like:
using System; using System.Text; p...
Page 5 of 11