1 / 11

MESSAGE AUTHENTICATION CODE MAC

MESSAGE AUTHENTICATION CODE MAC. Message Encryption. if public-key encryption is used: encryption provides no confidence of sender since anyone potentially knows public-key however if sender signs message using his private-key then encrypts with recipients public key

brygid
Télécharger la présentation

MESSAGE AUTHENTICATION CODE MAC

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. MESSAGE AUTHENTICATION CODE • MAC

  2. Message Encryption • if public-key encryption is used: • encryption provides no confidence of sender • since anyone potentially knows public-key • however if • sender signs message using his private-key • then encrypts with recipients public key • have both secrecy and authentication • but at cost of two public-key uses on message

  3. Message Authentication Code (MAC) • a small fixed-sized block of data: • depends on both message and a secret key • like encryption though need not be reversible • appended to message as a signature • receiver performs same computation on message and checks it matches the MAC • provides assurance that message is unaltered and comes from sender

  4. Message Authentication Code

  5. HMAC MD= Message Digest M= Input message whose MAC is calculated L= The number of Block in message M b = The no of bits in each block K= Shared symmetric key Ipad= string 00110110 repeated b/8 times Opad = string 01011010 repeated b/8 times

  6. HMAC • STEP – 1 : Make length of K equal to b: • if K < b then add many 0 bits to left of K • if K = b then do not take any action • if K > b then perform Digest function for compress. • STEP – 2 : XOR K with ipad to produce S1 K XOR S1 ipad

  7. HMAC • STEP – 3 : Append M to S1 S1 + Original Message M S1 + Original Message

  8. HMAC • STEP – 4 : Message digest algorithm: • Selected message digest algorithm applied to output of step – 3 : S1 + Original message M Message Digest MD H

  9. HMAC • STEP – 5: XOR K with opad to produce S2: • Now We XOR k with opad to produce variable called S2. K XOR S2 opad

  10. HMAC • STEP – 6 : Append H to S2: S2 + H S1 + H

  11. HMAC • STEP – 7 : Message Digest Algorithm. • Selected message digest (MD5,SHA) IS applied to o/p of step – 6 and finally we find MAC. S1 + H Message Digest MD MAC

More Related