Cryptography Algorithms

Every algorithm you are expected to know, with a plain status: broken, legacy, safe for now, or current. Plus what replaced it, and why key sizes do not compare across families.

Last updated

Download PDF

Free, no signup - 1 page - all 5 families with statuses

Know these cold

If you remember nothing else from this page, remember these sixteen.

  • MD5Broken
  • SHA-1Broken
  • 3DESLegacy
  • RC4 / DESBroken
  • AES-128 / 256Current
  • SHA-256Current
  • RSA-2048~112-bit security
  • RSA-3072~128-bit security
  • ECC-256~128-bit security
  • Argon2idPreferred password hash
  • PBKDF2FIPS-friendly password KDF
  • ML-KEMwas Kyber
  • ML-DSAwas Dilithium
  • SLH-DSAwas SPHINCS+
  • ShorBreaks public-key crypto
  • GroverQuadratic search speedup

Is it still safe? Quick lookup

The nine questions people actually arrive with.

QuestionShort answerWhy
Is MD5 still secure?NoCollisions have been practical since 2004. Fine as a download checksum, never for signatures or passwords.
Is MD5 encryption?NoIt is hashing. Encryption is reversible with a key; a hash is one-way by design and has no key.
Is SHA-1 broken?YesA real collision was produced in 2017, and chosen-prefix collisions in 2020. Certificates stopped accepting it years ago.
Is 3DES deprecated?LegacyWithdrawn by NIST, but not mathematically broken. It still works — it is just slow, small-blocked and superseded by AES.
Is AES-128 good enough?YesSecure today. CNSA 2.0 asks for AES-256 because Grover halves the effective strength, not because 128 is failing.
Is RSA-2048 still safe?For nowFine today, and on a clock. NIST’s draft transition plan deprecates 112-bit RSA and ECDSA after 2030 and disallows them after 2035, with everything quantum-vulnerable gone by 2035.
Can I use SHA-256 for passwords?NoIts speed is the problem. Use Argon2id, scrypt, bcrypt or PBKDF2, all of which are slow on purpose.
bcrypt or Argon2?Argon2idArgon2id is the usual first recommendation. bcrypt remains perfectly acceptable, and is the right answer in a FIPS environment where neither is approved and PBKDF2 wins.
Is Kyber the same as ML-KEM?YesKyber was the submission name; ML-KEM is the standardised name in FIPS 203. Same algorithm.

What the four statuses mean

Broken and legacy are not the same claim. One is mathematics, the other is policy, and they lead to different decisions.

Broken
Defeated in practice. Not a policy matter.
Legacy
Not broken, but superseded. Do not choose it for anything new.
Safe for now
Secure today, with a known end date.
Current
Appropriate for new systems.

These are our labels, not official classifications. No standards body publishes a four-state scale like this one. It is editorial shorthand, chosen so that a reader can act on a row without reading the specification behind it.

One caveat worth stating plainly. When NIST withdraws an algorithm, that binds United States federal systems. It is not a law, and it is not a statement that the algorithm stopped working. 3DES was withdrawn and still works perfectly functional. MD5 as a signature is a different situation entirely, because there the mathematics actually failed.

Symmetric

One shared key encrypts and decrypts. Fast, and what actually protects your data in transit and at rest.

AlgorithmSizeSecurity levelStatusWhat you need to know
AES-256256-bit key256CurrentThe largest quantum margin of the family: ~128-bit even on the idealised Grover estimate. Required by CNSA 2.0.
AES-192192-bit key192CurrentRarely chosen deliberately. Fine where it appears.
AES-128128-bit key128CurrentSecure today. CNSA 2.0 asks for 256 to leave a larger margin against future quantum attack, not because 128 is weak now.
ChaCha20-Poly1305256-bit key256CurrentStream cipher, RFC 8439, in TLS 1.3. Preferred where there is no AES hardware acceleration.RFC 8439
3DES / TDEA168-bit key112LegacyTriple DES. It is DES applied three times. 64-bit block makes it vulnerable to Sweet32 vulnerability.CVE-2016-2183 (Sweet32)
Blowfish32–448-bitvariesLegacy64-bit block, same Sweet32 exposure. Its own designer recommends moving on.CVE-2016-2183 (Sweet32)
Twofish128–256-bit128–256LegacyNever broken. An AES finalist that simply lost, so nothing was built around it.
DES56-bit key56BrokenBrute-forced in 1998 in 56 hours by purpose-built hardware. Trivial today.
RC440–2048-bitBrokenBiased keystream. Prohibited in TLS by RFC 7465.RFC 7465

Modes are a separate axis. GCM authenticates as well as encrypts and is the default choice, provided a nonce is never reused. CBC needs a separate MAC and has a long history of padding-oracle attacks. ECB leaks the structure of whatever it encrypts and should never be used.

Asymmetric (public key)

A key pair: public to encrypt or verify, private to decrypt or sign. Slow, so it is used to establish keys and prove identity, not to bulk-encrypt data.

AlgorithmSizeSecurity levelStatusWhat you need to know
X25519 / ECDH255-bit128Safe for nowThe default key exchange in TLS 1.3. Quantum clock applies to all of this family.
Ed25519 (EdDSA)255-bit128Safe for nowDeterministic signatures, so it avoids the nonce-reuse failure that has broken real ECDSA deployments.
ECDSA P-256256-bit128Safe for nowUbiquitous in certificates. A repeated or predictable nonce leaks the private key.
ECDSA P-384384-bit192Safe for nowCNSA 1.0 tier.
RSA-20482048-bit112Safe for nowThe headline number of this sheet: a 2048-bit key does not give 2048-bit security.
RSA-30723072-bit128Safe for nowWhat you need to match AES-128.
Diffie-Hellman (finite field) ≥ 20482048-bit+112+Safe for nowLogjam killed the small and export-grade groups. Size and group choice both matter.
RSA-10241024-bit80LegacyNever publicly factored, but below the NIST floor since 2013 and assumed within reach of a well-resourced attacker.
DSALegacyFIPS 186-5 disallows it for signature generation. Same catastrophic nonce sensitivity as ECDSA.

Hashing (general purpose)

One-way fingerprints for integrity, signatures and deduplication. Speed is a feature here, which is exactly why these are the wrong tool for passwords.

AlgorithmSizeSecurity levelStatusWhat you need to know
SHA-256 / SHA-512256 / 512-bit128 / 256CurrentThe default choice. SHA-512 is often faster on 64-bit hardware despite the larger output.
SHA-384384-bit192CurrentThe CNSA 2.0 hash.
SHA-3 / SHAKE224–512-bit112–256CurrentA sponge construction, structurally unlike SHA-2. Insurance against a SHA-2 break, not a replacement for it.
HMAC-SHA256128CurrentA construction, not an algorithm. Authenticates a message with a shared key.
BLAKE2 / BLAKE3variable128–256CurrentVery fast and unbroken, but not FIPS-approved, which rules it out of regulated environments.
RIPEMD-160160-bit80LegacyLargely gone, except that Bitcoin addresses still depend on it.
SHA-1160-bit< 80BrokenSHAttered demonstrated a real collision in 2017; chosen-prefix collisions followed in 2020.shattered.io
MD5128-bitBrokenCollisions practical since 2004. Acceptable as a non-security checksum and nothing else.
CRC3232-bitNot cryptoAn error-detection checksum, never a hash function. Listed because it keeps getting used as one.

A note on the security level column. For hash functions it refers to collision resistance, which is half the output length. Preimage resistance is the full length, so SHA-256 offers roughly 128-bit collision resistance and 256-bit preimage resistance. Saying flatly that “SHA-256 has 128-bit security” is only true of the first.

Password hashing and key derivation

A separate family, not a subset of hashing, because the goal is inverted: these are deliberately SLOW and memory-hungry so that guessing at scale stops being economic.

AlgorithmSizeSecurity levelStatusWhat you need to know
Argon2idtunableCurrentWon the Password Hashing Competition and is OWASP’s first recommendation. Memory-hard, so GPUs and ASICs gain far less. Minimum 19 MiB memory, 2 iterations, 1 degree of parallelism. Not FIPS-approved.OWASP Password Storage
scrypttunableCurrentAlso memory-hard (RFC 7914). A solid choice where Argon2 is unavailable.RFC 7914
bcrypttunableCurrentWork factor 10 or more. Two traps: it silently truncates input at 72 bytes, and the work factor must be raised as hardware improves. Note that OWASP now scopes bcrypt to legacy systems where Argon2 and scrypt are unavailable.OWASP Password Storage
PBKDF2tunableCurrentThe weakest of the four against GPU cracking because it is not memory-hard, and the FIPS-approved password KDF commonly used where that matters (SP 800-132). If you need it, OWASP asks for 600,000+ iterations with HMAC-SHA-256.SP 800-132OWASP Password Storage
Raw SHA-256 / MD5BrokenBroken FOR THIS USE. Not because the hash is weak, but because it is fast — which is what lets an attacker try billions of guesses a second.
LM / NTLMBrokenWindows legacy. LM is trivially cracked; NTLM is unsalted and fast, so rainbow tables apply.
HKDFCurrentA different job entirely: derives keys from material that is ALREADY high-entropy. Never use it on a password.

The best one and the approved one are different algorithms. Argon2id is the usual recommendation, but it is not FIPS-approved. In a regulated environment you will reach for PBKDF2 with a high iteration count instead, and that is the correct decision there even though it is the weaker algorithm. A compliance constraint, not a claim that PBKDF2 is cryptographically better.

Post-quantum

The replacements for the asymmetric family. NIST renamed each one when it became a standard, which is why the names you searched for are not the names in the specification.

AlgorithmSizeSecurity levelStatusWhat you need to know
ML-KEM (was Kyber)512 / 768 / 1024128–256CurrentFIPS 203. A key encapsulation mechanism: it establishes a shared secret, it does not encrypt your data directly.FIPS 203
ML-DSA (was Dilithium)44 / 65 / 87128–256CurrentFIPS 204. The general-purpose post-quantum signature.FIPS 204
SLH-DSA (was SPHINCS+)128 / 192 / 256128–256CurrentFIPS 205. Hash-based, so its security rests on different maths from the lattice schemes. Slow with large signatures, and the hedge if lattices ever fall.FIPS 205
X25519MLKEM768hybrid128CurrentClassical and post-quantum key exchange run together, so it stays secure if either half holds. Now the default in several major browsers, so this is deployed rather than theoretical.
FN-DSA (was Falcon)512 / 1024128–256Safe for nowFIPS 206 remains in development as of September 2026. Compact signatures, but tricky to implement in constant time.
HQCSafe for nowSelected in March 2025 as a backup KEM, built on error-correcting codes rather than lattices. Not yet a final standard as of September 2026.

Key sizes do not compare across families

Security strength is the work an attacker has to do, measured in bits. It is the only number that lets you compare an RSA key against an AES key, and it is why the two look so wildly mismatched.

Security strengthSymmetricRSA / DHECC
112 bits3DES2048224
128 bitsAES-1283072256
192 bitsAES-1927680384
256 bitsAES-25615360512

Read the bottom row again. Matching AES-256 takes an RSA key of 15,360 bits and an elliptic curve key of 512. That single comparison is the entire reason elliptic curve cryptography exists.

What quantum actually breaks

Not everything, and the asymmetry is the point. A sufficiently large quantum computer running Shor’s algorithm would break RSA, Diffie-Hellman and elliptic curve cryptography. Grover’s algorithm offers only a quadratic speedup against brute-force search, so symmetric ciphers and hashes lose far less ground and AES-256 comes through fine. Key exchange and signatures have to be replaced. Your bulk encryption largely does not.

No machine capable of this exists today, and none is close. The reason to move anyway is harvest now, decrypt later: traffic recorded today can be decrypted whenever the capability arrives, so anything that must stay confidential for a decade is already exposed.

Why Kyber is now ML-KEM, and what quantum actually breaks →The naming map in full, why this migration is happening before anything is broken, and where the September 2026 RSA-260 result does and does not fit.

Where people lose the mark

Eight distinctions that decide most questions on this topic.

Encoding is not encryption, and hashing is not either
Base64 has no key and anyone can reverse it, so it protects nothing. Encryption is reversible with a key. Hashing is one-way and has no key at all. Three different operations that get used interchangeably in conversation and never in an exam answer.
Key sizes do not compare across families
RSA-2048 and AES-256 are not "2048 versus 256". RSA-2048 provides about 112 bits of security and AES-256 provides 256. The numbers measure different things, so comparing them directly is meaningless. Use the security level, never the key length.
AES-256 is not twice AES-128
One extra bit doubles the keyspace, so 256 bits is 2^128 times larger than 128 bits, not double. Neither is brute-forceable, which is why the real argument for AES-256 is quantum resistance rather than present-day strength.
A digital signature does not provide confidentiality
It gives integrity, authenticity and non-repudiation. The message stays perfectly readable. If a question asks how to keep something secret, a signature is never the answer.
Salts are not secret, and they are not pepper
A salt exists to make identical passwords hash differently and to break precomputed tables, so it is stored in plain sight next to the hash. A pepper is a separate secret held outside the database. Confusing the two is a common trap.
HMAC-MD5 is not broken, even though MD5 is
HMAC does not rely on collision resistance, so MD5 being shattered does not defeat it. This is genuinely counterintuitive and is worth knowing precisely, though you should still use HMAC-SHA256 in anything new.
ECB is a mode, and it is the wrong one
Electronic Codebook encrypts each block independently, so identical plaintext blocks produce identical ciphertext and the structure of the data survives. The famous encrypted-penguin image is ECB: the bird is still perfectly recognisable after encryption. Use GCM, and never repeat a nonce. See the ECB penguin
Logical qubits are not physical qubits
Quantum announcements quote physical qubits, and error correction consumes a great many of them to produce one reliable logical qubit. A headline number in the low thousands is nowhere near what breaking RSA-2048 would require.

Frequently asked questions

What is the difference between hashing and encryption?

Encryption is two-way: with the correct key the original data comes back exactly. Hashing is one-way and keyless, producing a fixed-length fingerprint that cannot be reversed to recover the input. You encrypt data you need to read again, such as a file or a network session. You hash data you only ever need to compare, such as a password or a file integrity check. Encoding, like Base64, is a third thing entirely and offers no protection at all, since anyone can decode it without a secret.

Why is RSA-2048 only 112-bit security?

Because security strength measures the work an attacker must do, not the length of the key. Factoring a 2048-bit modulus takes roughly the same effort as brute-forcing a 112-bit symmetric key, thanks to algorithms far better than trial division. Elliptic curve cryptography scales much more efficiently: a 256-bit ECC key delivers 128-bit security, which RSA needs 3072 bits to match. Pushing to 256-bit security would take an RSA key of 15360 bits, and that gap is the reason elliptic curves exist.

Which password hashing algorithm should I use?

Argon2id is the usual first recommendation, since it is memory-hard and therefore resists GPU and ASIC cracking far better than the alternatives. scrypt is a good second choice on the same principle, and bcrypt remains perfectly acceptable provided the work factor is kept current. The exception is a FIPS-regulated environment, where neither Argon2 nor bcrypt is approved and PBKDF2 with a high iteration count is the right answer. The best algorithm and the approved algorithm are not always the same one, which is a distinction worth carrying into any real deployment.

Is Kyber the same as ML-KEM?

Yes. Kyber was the name of the submission to the NIST post-quantum competition, and ML-KEM, short for Module-Lattice-Based Key-Encapsulation Mechanism, is the name it was given on standardisation as FIPS 203. The same renaming happened to the others: Dilithium became ML-DSA in FIPS 204, SPHINCS+ became SLH-DSA in FIPS 205, and Falcon is becoming FN-DSA. Most search results and a great deal of existing documentation still use the competition names, which is the main reason the mapping is confusing.

Is quantum computing a threat to cryptography?

To some of it, yes, and the split is what matters. Public-key cryptography is the part genuinely at risk: RSA, Diffie-Hellman and elliptic curves all rest on problems a sufficiently large quantum computer running Shor algorithm could solve, which is why replacements have been standardised as ML-KEM, ML-DSA and SLH-DSA. Symmetric encryption and hashing are far less exposed, since Grover algorithm offers only a quadratic speedup and is awkward to parallelise, so AES-256 and SHA-256 remain sound. No machine capable of any of this exists today, and published estimates put one several orders of magnitude beyond the largest built so far. The reason it is not simply tomorrow problem is harvest now, decrypt later: an attacker can record encrypted traffic today and decrypt it once the capability arrives, so anything that must stay confidential for a decade or more is already exposed.

Does quantum computing break AES?

No, and the asymmetry here is the single most misunderstood point in the topic. Shor algorithm breaks the asymmetric family outright, which means RSA, Diffie-Hellman and elliptic curve cryptography all fail once a sufficiently large quantum computer exists. Grover algorithm only halves the effective strength of symmetric ciphers, so AES-256 retains about 128 bits of security and remains entirely out of reach. The practical consequence is that key exchange and signatures must be replaced, while your bulk encryption largely does not.

What does deprecated actually mean for an algorithm?

It usually means a standards body has withdrawn approval for its use in their scope, which for NIST means United States federal systems. That is a policy decision and not the same as the algorithm being broken. 3DES is the clearest example: it has been withdrawn, yet it has never been defeated and it still functions correctly. MD5 sits at the other end, where the mathematics genuinely failed and no policy is needed to justify avoiding it. This sheet keeps the two ideas apart deliberately, because they lead to different decisions.

About this cheat sheet

Source
Statuses and key-size guidance follow NIST SP 800-131A Rev 2 and SP 800-57 Part 1. Post-quantum names and parameters come from FIPS 203, 204 and 205.
On the word “deprecated”
NIST guidance binds United States federal systems. This sheet separates that from algorithms that are genuinely defeated, because the two lead to different decisions and are routinely conflated.
Scope
Algorithms that appear in CompTIA Security+ and ISC2 material, plus the post-quantum standards. Not an implementation guide: choosing an algorithm is the easy part of deploying cryptography safely.
Related
Common ports & protocols covers the secure and insecure protocol pairs these algorithms sit behind.