MAC Concepts & Length-Extension Attacks
Explain why appending a secret prefix is insecure against length extension.
Welcome
Message Authentication Codes (MACs) provide integrity and authenticity with a shared secret key. In this lesson we understand MACs, their properties, and a critical vulnerability in naive keyed hashes.
What Is a MAC?
A MAC is a short authentication code computed from a message and a secret key. Receiver with the same key recomputes the MAC and verifies. Prevents forgery without the key.
All lessons in this course
- MAC Concepts & Length-Extension Attacks
- HMAC Construction & Security Proof
- HMAC in APIs: Request Signing
- CMAC & Poly1305: Block-Cipher MACs