AES-GCM
AES in Galois/Counter Mode: the most widely used way to encrypt data so that it stays secret and any tampering is detected.
In more detail
AES-GCM is AES in counter mode plus an authentication tag, usually 16 bytes, calculated over the ciphertext and any associated data; decryption checks the tag first and releases nothing if it fails. It needs a 96-bit (12-byte) nonce that is never reused under the same key, and with random nonces NIST limits one key to about 4 billion (2^32) messages. It is fast on processors with built-in AES instructions and is the usual choice for TLS, disk and cloud storage encryption.
Examples
sent, tag = seal("AES-256-GCM", KEY, NONCE, header, b"pay 0100.00 GBP to 12345678")tampered: rejected, authentication failed, nothing releasedRelated terms
- AEAD — Authenticated encryption with associated data: encryption that keeps data secret and also detects any change to it or to an attached readable header.
- CTR mode — Counter mode: a way of using a block cipher that encrypts a running counter to make keystream, then combines that with the message using XOR.
- nonce — A value meant to be used only once, such as a unique number given to a cipher or a random token that marks trusted scripts in a web page.
- ChaCha20-Poly1305 — An authenticated encryption scheme that pairs the ChaCha20 stream cipher with the Poly1305 authenticator, and runs fast even on devices without AES hardware.
Taught in
- Symmetric Encryption: AES-GCM & ChaCha20 — Cybersecurity Fundamentals, GRC & Cryptography
- Data States: Security at Rest, in Transit, and in Use — Cybersecurity Fundamentals, GRC & Cryptography