1 / 20

PIS : Unit III Message Authentication

PIS : Unit III Message Authentication. Sanjay Rawat Sanjay_r@vnrvjiet.in. Based on the slides of Lawrie Brown together with the book “Cryptography and Network Security” by William Stalling. Message Authentication. So far, we covered secrecy of the message i.e. confidentiality.

waldo
Download Presentation

PIS : Unit III Message Authentication

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. PIS: Unit IIIMessage Authentication Sanjay Rawat Sanjay_r@vnrvjiet.in Based on the slides of Lawrie Brown together with the book “Cryptography and Network Security” by William Stalling. PIS Unit 3 Message Auth Sanjay Rawat

  2. Message Authentication • So far, we covered secrecy of the message i.e. confidentiality. • message authentication is concerned with: • protecting the integrity of a message • validating identity of originator • non-repudiation of origin (dispute resolution) • will consider the security requirements • then three alternative functions used: • message encryption • message authentication code (MAC) • hash function PIS Unit 3 Message Auth Sanjay Rawat

  3. Message Authentication • Message authentication is a mechanism or service used to verify the integrity of a message. • Message authentication assures that data received are exactly as sent by (i.e., contain no modification, insertion, deletion, or replay) and • that the purported identity of the sender is valid. PIS Unit 3 Message Auth Sanjay Rawat

  4. Situations wherein Authentication is required • disclosure • traffic analysis • masquerade • content modification • sequence modification • timing modification • source repudiation • destination repudiation confidentiality Message authentication MA + DS PIS Unit 3 Message Auth Sanjay Rawat

  5. Authentication Functions • Message encryption: The ciphertext of the entire message serves as its authenticator • Message authentication code (MAC): A function of the message and a secret key that produces a fixed-length value that serves as the authenticator • Hash function: A function that maps a message of any length into a fixed-length hash value, which serves as the authenticator PIS Unit 3 Message Auth Sanjay Rawat

  6. One Practical Issue PIS Unit 3 Message Auth Sanjay Rawat

  7. Message Authentication Code (MAC) • generated by an algorithm that creates a small fixed-sized block • depending on both message M and some secret key K s.t.MAC = C(K,M), where • M = input message • C = MAC function • K = shared secret key • MAC = message authentication code • 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 PIS Unit 3 Message Auth Sanjay Rawat

  8. MAC conti… PIS Unit 3 Message Auth Sanjay Rawat

  9. Features of MAC • MAC provides authentication • can also use encryption for secrecy of M • generally use separate keys for each process • can compute MAC either before or after encryption • is generally regarded as better done before PIS Unit 3 Message Auth Sanjay Rawat

  10. MAC Features • why use a MAC? • sometimes only authentication is needed • sometimes need authentication to persist longer than the encryption (eg. archival use) • note that a MAC is not a digital signature. • is a many-to-one function • potentially many messages have same MAC • but finding these needs to be very difficult PIS Unit 3 Message Auth Sanjay Rawat

  11. Requirements for MACs • Based on the security analysis, the MAC needs to satisfy the following: • knowing a message and MAC, is infeasible to find another message with same MAC • MACs should be uniformly distributed, i.e. for M and M', the probability that C(K, M) = C(K, M') is 2n. • MAC should depend equally on all bits of the message, e.g. Pr[C(K, M) = C(K, M')] = 2n. PIS Unit 3 Message Auth Sanjay Rawat

  12. Using Symmetric Ciphers for MACs • can use any block cipher chaining mode and use final block as a MAC • Data Authentication Algorithm (DAA) is a widely used MAC based on DES-CBC • using IV=0 and zero-pad of final block • encrypt message using DES in CBC mode • and send just the final block as the MAC • or the leftmost M bits (16≤M≤64) of final block • but final MAC is now too small for security

  13. Data Authentication Algorithm

  14. Hash Functions • Transforms messages of arbitrary length to fixed size h = H(M) • usually assume that the hash function is public and not keyed • cf. MAC which is keyed • hash used to detect changes to message • can use in various ways with message • most often to create a digital signature PIS Unit 3 Message Auth Sanjay Rawat

  15. Application of Hash PIS Unit 3 Message Auth Sanjay Rawat

  16. Requirements for Hash Functions • can be applied to any sized message M • produces fixed-length output h • is easy to compute h=H(M) for any message M • given h is infeasible to find xs.t.H(x)=h • one-way property • given x is infeasible to find ys.t. H(y)=H(x) • weak collision resistance • is infeasible to find any x,ys.t. H(y)=H(x) • strong collision resistance PIS Unit 3 Message Auth Sanjay Rawat

  17. Simple Hash Functions • are several proposals for simple functions • based on XOR of message blocks • The message is arranged into ~m/n blocks, where m:message length, n:hash size. • RXOR (rotate XOR) • need a stronger cryptographic function (next chapter)

  18. Block Ciphers as Hash Functions • can use block ciphers as hash functions • using H0=0 and zero-pad of final block • compute: Hi = EMi [Hi-1] • and use final block as the hash value • similar to CBC but without a key • resulting hash is too small (64-bit) • both due to direct birthday attack • and to “meet-in-the-middle” attack • other variants also susceptible to attack

  19. Hash Functions & MAC Security • brute-forceattacks exploiting • strong collision resistance hash have cost 2m/2 • have proposal for h/w MD5 cracker • 128-bit hash looks vulnerable, 160-bits better

  20. MAC security • Computation resistance: Given one or more text-MAC pairs [xi, C(K, xi)], it is computationally infeasible to compute any text-MAC pair [x, C(K,x)] for any new input x != xi. • MACs with known message-MAC pairs • can either attack keyspace(~2k)(cf key search) or MAC (~2n) • brute-force attack on a MAC algorithm can be expressed as min(2k,2n). • at least 128-bit MAC is needed for security PIS Unit 3 Message Auth Sanjay Rawat

More Related