MAC
- MAC verifies whether the sender has access to the shared secret
- Digital Signature verifies the identity of a sender using asymmetric cryptography.
How to verify the authenticity and integrity of a message with a given shared secret during encrypted communication? (Authenticity and integrity of a message).
We need MAC because there's no way to check what has been modified when the content sent along with the key is very large. Therefore, we use the value that results from the computation between the key and the message.
- Attach MAC to encrypted messages, and have the receiver verify MAC.
- Attackers should NOT be able to compute MACs for attacker-chosen messages.
Message Authentication Codes