HMAC
Also called Hash-based Message Authentication Code.
A keyed hash that proves a message's integrity and authenticity.
What it is
A construction that combines a cryptographic hash with a secret key to produce a message authentication code. Only parties holding the key can generate or verify a valid HMAC.
Why it matters
HMAC proves both that data was not tampered with and that it came from someone with the key, which a bare hash cannot. It secures API tokens, session cookies, and protocol messages, so a leaked HMAC key lets an attacker forge trusted requests.
In practice
An API signing each request with HMAC-SHA256 so the server rejects any tampered or unauthenticated call.
What to look for
- Message signatures or webhook secrets using HMAC-SHA256.
- Comparisons done with normal string equality instead of constant time.
- Shared secrets that are short or reused across systems.
Common mistake
Using a plain hash of key plus message. That construction is open to length extension; HMAC is built to avoid it.
Practice it nearby
CyberKit has no tool for this term itself. These are the closest places to practice it.
- File Triage
Drop any file. It names the format from its first bytes, hashes it, and opens the parser that reads it: PE, ELF, Mach-O, Office, PDF, plist, or entropy and strings.
- Decoder
Paste any opaque value. It names what it looks like and why, then decodes it: Base64 and other layers, number bases, hashes, JWTs, certificates, SIDs, User-Agents and MAC addresses.
- Decode Range
Name an opaque value before you read it: timestamps, encodings and hashes, all generated by the site's own converters.
In the field
Well-known tools where this shows up on the job. They are listed to show the landscape, not as a recommendation.
-
OpenSSL Open source
The command line toolkit for inspecting certificates, keys and TLS connections.
-
HashiCorp Vault Source available
Manages secrets and encryption keys, and can encrypt data as a service.
-
AWS Key Management Service Cloud service
AWS's managed service for creating and controlling encryption keys.
Read next
- Cryptographic Hash Function: A one-way function mapping any input to a fixed-size fingerprint.
- Authenticated Encryption: Encryption that guarantees both confidentiality and integrity at once.
- Digital Signature: A cryptographic proof of a message's origin and integrity.