๐ŸŽฏ New! Master certifications with Performance-Based Questions (PBQ) โ€” realistic hands-on practice for CompTIA & Cisco exams!

๐Ÿ”

Cryptography Cheat Sheet

Encryption algorithms, hashing, and key exchange methods

Algorithm Type Key Size Use Case Speed Notes
AESSymmetric128/192/256 bitsData encryption, disk encryptionFastCurrent standard, replaces DES
DESSymmetric56 bitsLegacy (insecure)FastDeprecated, easily cracked
3DESSymmetric168 bits (effective 112)Legacy financial systemsSlowApply DES 3 times, deprecated
BlowfishSymmetric32-448 bitsPassword hashing, legacy appsFastReplaced by Twofish
TwofishSymmetric128/192/256 bitsDisk encryption, TrueCryptFastAES finalist
ChaCha20Symmetric256 bitsTLS, mobile devicesVery fastAlternative to AES, no hardware needed
RSAAsymmetric2048-4096 bitsKey exchange, digital signaturesSlowBased on prime factorization
ECCAsymmetric256-521 bitsTLS, mobile, IoTFaster than RSASmaller keys = same security
Diffie-Hellman (DH)Key Exchange2048+ bitsKey agreement over insecure channelMediumVulnerable to MITM without auth
ECDHKey Exchange256-521 bitsTLS key exchangeFastECC-based Diffie-Hellman
MD5Hash128-bit outputChecksums only (insecure)FastCollision attacks, never for security
SHA-1Hash160-bit outputLegacy (deprecated)FastCollision found 2017, avoid
SHA-256Hash256-bit outputDigital signatures, SSL certsFastCurrent standard, SHA-2 family
SHA-384/512Hash384/512-bit outputHigh-security applicationsFastSHA-2 family, longer output
SHA-3Hash224-512-bit outputNext-gen hashingMediumKeccak algorithm, different design
bcryptPassword Hash184-bit outputPassword storageIntentionally slowAdaptive cost factor
scryptPassword HashConfigurablePassword storage, cryptoMemory-hardResistant to GPU attacks
Argon2Password HashConfigurableModern password storageMemory-hardWinner of PHC, recommended
HMACMACVariesMessage authenticationFastHash + secret key
PBKDF2Key DerivationConfigurableDerive keys from passwordsConfigurable iterationsNIST recommended

๐Ÿ”‘ Symmetric vs Asymmetric

Symmetric: Same key encrypts/decrypts. Fast. (AES)
Asymmetric: Public/private key pair. Slower. (RSA, ECC)

โœ… Current Standards

  • โ€ข Encryption: AES-256
  • โ€ข Hashing: SHA-256+
  • โ€ข Passwords: Argon2 or bcrypt