Question

What are the relations and difference between message authentication code and hash function? What is authenticated...

What are the relations and difference between message authentication code and hash function?

What is authenticated encryption (AE)? what kinds of security service doe AE provide?

What are the common approaches to providing both confidentiality and encryption for a message?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer:

1)

A message authentication code (MAC) is similar to a cryptographic hash, except that it is based on a secret key. When secret key information is included with the data that is processed by a cryptographic hash function, the resulting hash is known as an HMAC

A MAC (Message authentication code) is a short tag that can be used to verify the integrity of a message. It involves a shared secret key between the two parties.

It has two basic steps:

Building a tag

From a message “m” and the secret key “k” we can build a short tag that “t”. t = S(k,m).

Verifying a tag

From a message “m” , a tag “t” and a key “k” we can verity that the tag and the message correspond. V(k, t, m) .

For a MAC to be secure the following needs to happen

Without knoledge of the key “k” an attacker can’t create a pair (m,t) that will verify correctly. This implies the attacker can obtain a tag for any chosen plaintext message but with that power can’t create a new pair (m,t) that will be verified.

This can be understood as a chosen-plaintext game:

The attacker can send chosen-plaintext messages m0,m1,…..,mn to Alice who knows the secret key, alice will return the tag of those messages ti = S(k,mi).

The attacker can do this as many times as he wishes but even then he can’t produce a new pair (m’,t) such as V(k,t’,m’) will be verified with m’ different than m0….mn.

This is known as “existential forgery” and it is something that is NOT required from cryptographic hash functions.

So our first answer is that a MAC algorithm has security properties that go beyond cryptographic hash function.

Finally I have to say that a MAC can be built from a cryptographic hash function (HMAC) but can also be built from a private key encryption algorithm (CBC-MAC, etc..). MACs can also be built from non-cryptographic hash functions using Universal hashing.

So to summarize:

  • A MAC has stronger security properties than a cryptographic hash function.
  • A MAC can be built from either a cryptographic hash function, a block-cipher or a non-cyptographic hash function.

tldr; We might use a hash function to build a MAC algorithm but a hash function alone can never be a MAC.

2)

Authenticated encryption (AE) and authenticated encryption with associated data (AEAD) are forms of encryption which simultaneously assure the confidentiality and authenticity of data. These attributes are provided under a single, easy to use programming interface.

The need for AE emerged from the observation that securely combining separate confidentiality and authentication block cipher operation modes could be error prone and difficult.This was confirmed by a number of practical attacks introduced into production protocols and applications by incorrect implementation, or lack of authentication

E mode implementation would provide the following functions:

  • Encryption
    • Input: plaintext, key, and optionally a header in plaintext that will not be encrypted, but will be covered by authenticity protection.
    • Output: ciphertext and authentication tag (message authentication code).
  • Decryption
    • Input: ciphertext, key, authentication tag, and optionally a header.
    • Output: plaintext, or an error if the authentication tag does not match the supplied ciphertext or header.

Add a comment
Know the answer?
Add Answer to:
What are the relations and difference between message authentication code and hash function? What is authenticated...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
Active Questions
ADVERTISEMENT