Presentation is loading. Please wait.

Presentation is loading. Please wait.

SOFTWARE IMPLEMENTATION OF OCB MODE

Similar presentations


Presentation on theme: "SOFTWARE IMPLEMENTATION OF OCB MODE"— Presentation transcript:

1 SOFTWARE IMPLEMENTATION OF OCB MODE
Under the guidance of Dr. Jens-Peter Kaps by Paradesi Ravi kiran Baba Prashanth Namatheertham Bharath Govindool Ritesh Suppala 12/19/2006 Software Implementation of OCB

2 Software Implementation of OCB
Need for Encryption Data Confidentiality Data Integrity Sender Authentication 12/19/2006 Software Implementation of OCB

3 Classification of Ciphers
Classical Modern Rotor Machines Substitution Transposition Private Key Public Key Stream Block 12/19/2006 Software Implementation of OCB

4 Private Key Encryption
Symmetric key encryption can be done at high speeds Key distribution problem Block ciphers provide high security DES and AES are the most commonly used block ciphers 12/19/2006 Software Implementation of OCB

5 Software Implementation of OCB
AES or DES? DES encryption uses 64 bit key which is proved to be vulnerable AES encryption uses 128 bit key which is still considered to be secure In the present work AES is used 12/19/2006 Software Implementation of OCB

6 Software Implementation of OCB
Modes of Operation ECB mode CBC mode Counter mode OFB mode OCB mode 12/19/2006 Software Implementation of OCB

7 OCB (Offset Code Book) Mode
New mode of operation Invented by Phil Rogway Authenticated Encryption Scheme Cost efficient algorithm Platform independent 12/19/2006 Software Implementation of OCB

8 Simple representation of OCB Algorithm
1L+R 2L+R 3L+R 4L+R Nonce E E E E E k k k k k 4L+R 1L+R 2L+R 3L+R R 12/19/2006 Software Implementation of OCB

9 Software Implementation of OCB
Steps Involved Message partitioning Random number generation L value generation Hash function generation Encryption Tag generation 12/19/2006 Software Implementation of OCB

10 Software Implementation of OCB
Encryption Scheme Any block cipher can be used Advanced Encryption Standard Rijndael AES Complex and secure 128 bit key AES is faster than 3DES 12/19/2006 Software Implementation of OCB

11 Software Implementation of OCB
AES 128 bit message and 128 bit key Key expansion Ten rounds Substitution Shift rows Mix columns Add round key 12/19/2006 Software Implementation of OCB

12 Software Implementation of OCB
Block diagram of AES Key Plain Text Add Round Key Key expansion Substitute Bytes Round Key 1 Shift rows Round Key 2 Mix Columns Add round Key Round Key 10 Substitute Bytes Shift rows Add round Key Cipher Text 12/19/2006 Software Implementation of OCB

13 Software Implementation of OCB
Message partitioning Input message is a text file AES 128 bits Input message divided into blocks of 128 bits Last block ( 1 to 128 bits) Each block arranged in 4x4 matrix 12/19/2006 Software Implementation of OCB

14 Software Implementation of OCB
Random Number 128 bit random number Generated using special functions offered by C compiler Srand ( ) under the header <math.h> Arranged in a 4x4 matrix Encrypted to generate nonce(R) Used in offset 12/19/2006 Software Implementation of OCB

15 Software Implementation of OCB
L values Significant feature of OCB 128 bits of zeroes are encrypted (L[0]) Number of L values generated is equal to number of message blocks L[-1]= L[0]>>1 if MSB is 0 otherwise L[-1]=L[0]>>1 xored with L[i] for i>0, L[i]=L[i-1]<<1 if MSB is 0 otherwise L[i]=L[i-1]<<1 xor with 12/19/2006 Software Implementation of OCB

16 Software Implementation of OCB
Last Block Contains less than or equal to 128 bits Length is found out Xored with L[-1] Xored with offset (L[m]+R) Encrypted Xored with M[m] (message) 12/19/2006 Software Implementation of OCB

17 Offset value and Encryption
Offset values are generated for each message block Offset value =L[i]+R Before encryption, message xored with offset M[i]=M[i] xor offset (for i=1 to m-1) Last block All messages encrypted with AES After encryption cipher is again xored with offset 12/19/2006 Software Implementation of OCB

18 Software Implementation of OCB
Tag Generation Simple hash function is generated Hash function xored with final offset( L[m]) Encrypted Tag value generated 12/19/2006 Software Implementation of OCB

19 Software Implementation of OCB
Block diagram of OCB Hash M[1] M[2] M [m] Zeroes Random length L[1]+R L[2]+R L[m]+R+C[m] L[-1]+Len[m] L[M]+R AES(K) AES(K) AES(K) AES(K) AES(K) AES(K) L[1]+R L[2]+R L[0] NONCE L[-1] C[1] C[2] C[ m] Tag 12/19/2006 Software Implementation of OCB L[m]

20 Software Implementation of OCB
Comparison Compared with CBC mode More clock cycles than CBC Authentication provided Parallelism can be implemented More efficient than CBC 12/19/2006 Software Implementation of OCB

21 Software Implementation of OCB
12/19/2006 Software Implementation of OCB

22 Software Implementation of OCB
12/19/2006 Software Implementation of OCB


Download ppt "SOFTWARE IMPLEMENTATION OF OCB MODE"

Similar presentations


Ads by Google