26.10.2012 Views

Internet Security - Dang Thanh Binh's Page

Internet Security - Dang Thanh Binh's Page

Internet Security - Dang Thanh Binh's Page

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The final decrypted plaintext is:<br />

b267af31 6d8a59e7 b16ac385 f2a072be<br />

SYMMETRIC BLOCK CIPHERS 105<br />

Example 3.20 Consider RC6-32/20/24. Suppose the plaintext and user key are given<br />

as follows:<br />

Plaintext: 35241302 79685746 bdac9b8a f1e0dfce<br />

User key: 01 23 45 67 89 ab cd ef<br />

01 12 23 34 45 56 67 78<br />

89 9a ab bc cd de ef f0<br />

The user supplies a key of b = 24 bytes, where 0 ≤ b ≤ 255. Fromthiskey,2r + 4 = 44<br />

words are derived and stored in the array S[0, 1,...,2r + 3]. This array is used in both<br />

encryption and decryption.<br />

Key array<br />

S[0] = 4d80ade S[1] = c85296a3 S[2] = c7ca853c S[3] = d665bea0<br />

S[4] = 4d34492f S[5] = e110bf65 S[6] = 9f4acf83 S[7] = ed85cb10<br />

S[8] = f9f0f8eb S[9] = 2275ea3f S[10] = e5dc8714 S[11] = a1b4b8b4<br />

S[12] = 1a28cd0a S[13] = 618fbe87 S[14] = 6fc1ede0 S[15] = 8eaf634d<br />

S[16] = 7d213901 S[17] = bed7ab73 S[18] = 79ba092e S[19] = 6179bc8a<br />

S[20] = aa35b6f6 S[21] = 0091b3ca S[22] = 65f970e9 S[23] = 687e9e94<br />

S[24] = f17e5188 S[25] = 7ec55cf7 S[26] = fe2c8e93 S[27] = 2e7b3dae<br />

S[28] = 56093cb8 S[29] = ed28fa03 S[30] = ab2eaaec S[31] = d049366f<br />

S[32] = fcd4cbd3 S[33] = 84b3906f S[34] = 8eced9f1 S[35] = e02a2453<br />

S[36] = 123b6e03 S[37] = a6192a81 S[38] = 8648252c S[39] = b29fbd04<br />

S[40] = 735d2dc1 S[41] = 97447b58 S[42] = 362b46b2 S[43] = 7c310342<br />

RC6 works with four 32-bit registers A, B, C and D which contain the initial input<br />

plaintext as well as the output ciphertext at the end of encryption. Both encryption and<br />

decryption using RC6-32/20/24 are processed as shown below.<br />

Initial values in registers:<br />

A = 35241302 B = 79685746<br />

C = bdac9b8a D = f1e0dfce<br />

Encryption with RC6-32/20/24<br />

Round A B C D<br />

0 35241302 7e406224 bdac9b8a ba337671<br />

1 7e406224 bf73145b ba337671 ae7fec22<br />

2 bf73145b 8223f9cc ae7fec22 d96ddcb2<br />

3 8223f9cc 823d1be2 d96ddcb2 8ad786e7<br />

4 823d1be2 30fa9e1e 8ad786e7 3439983d

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!