uran-lajci / AES-Implementation-with-ASP.NET

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Information Security

AES Encryption with ASP.NET

AES (Advanced Encryption Standard)

The Advanced Encryption Standard (AES) is a symmetric block cipher.

• AES-128 uses a 128-bit key length to encrypt and decrypt a block of messages.

• AES-192 uses a 192-bit key length to encrypt and decrypt a block of messages.

• AES-256 uses a 256-bit key length to encrypt and decrypt a block of messages.

Each cipher encrypts and decrypts data in blocks of 128 bits using cryptographic keys of 128, 192 and 256 bits, respectively.

AES operates on a 4 × 4 column-major order array of 16 bytes b0,b1,...,b15 termed the state

b0 b4 b8 b12

b1 b5 b9 b13

b2 b6 b10 b14

b3 b7 b11 b15

The number of rounds are as follows:

• 10 rounds for 128-bit keys.

• 12 rounds for 192-bit keys.

• 14 rounds for 256-bit keys.

image

image

In the SubBytes step, each byte in the state is replaced with its entry in a fixed 8-bit lookup table, S; bij = S(aij).

image

In the ShiftRows step, bytes in each row of the state are shifted cyclically to the left. The number of places each byte is shifted differs incrementally for each row.

image

In the MixColumns step, each column of the state is multiplied with a fixed polynomial c(x).

Tests

317794271_537298731346915_4040557537840596551_n

Encryption
317999139_670590804666507_6700934359952104659_n

Decryption
317913594_1533606840487562_9006076953780702259_n

318053349_1443376229814265_8592709450762097204_n

318298564_2910831972545724_9218231228228026869_n

317951125_985779916144328_236201654989166453_n

318379287_1588939288248464_6269078089986911237_n

About


Languages

Language:C# 100.0%