Skip to content
CryptoAcademy logo CryptoAcademy
Menu
Intermediate Cryptography

Symmetric encryption

Encryption where the same key both locks and unlocks the data.

Symmetric encryption at a glance
Symmetric encryption uses one shared key; asymmetric uses a public and a private key Symmetric — AES-GCM Same key encrypts and decrypts Plaintext pay 1 BTC Ciphertext a9f3…1c Shared key K secret, 256-bit Fast · problem: how to share the key safely? Asymmetric — RSA / ECDSA A public key and its private key are a pair Public key shared with everyone Private key never leaves the owner mathematically linked (trapdoor) Anyone encrypts → only owner decrypts Slower · solves key distribution and signatures How the web combines both (TLS) 1. Your browser fetches the site's public key inside a certificate. 2. Both sides derive a temporary symmetric session key (key exchange). 3. Everything after that is encrypted fast with AES-GCM — signatures only prove who you are.

In simple terms

One shared secret protects the message in both directions. AES is the standard algorithm; GCM is the standard mode.

Analogy

A padlock you can snap shut yourself: whoever has the matching key opens it — so the hard part is handing over that key safely.

Going deeper

AES processes 128-bit blocks with 128/192/256-bit keys; in GCM mode it doubles as a GHASH-based authenticator. Reusing a nonce with the same key can leak the XOR of plaintexts and even expose the authentication key — libraries enforce nonce discipline for you.

Common mistake

Choosing the mode matters more than choosing the cipher: ECB leaks patterns even though AES itself is unbroken.

Share this page

Send this link to a friend, or scan the QR code to open it on your phone.