Copyright (c) 2026 MindMesh Academy. All rights reserved. This content is proprietary and may not be reproduced or distributed without permission.

4.5.1. Cryptographic Foundations: Symmetric and Asymmetric

💡 First Principle: Symmetric encryption uses the same key to encrypt and decrypt — it is fast and efficient but requires a secure channel to share the key before any encrypted communication can begin. Asymmetric encryption uses a mathematically linked key pair (public and private) — it solves the key distribution problem but is orders of magnitude slower than symmetric. In practice, both are used together: asymmetric to securely exchange a symmetric key, symmetric to encrypt the bulk data.

Symmetric Encryption:
AlgorithmKey SizeStatusNotes
DES56-bit❌ DeprecatedBrute-forced in 22 hours (1999); never use
3DES (TDEA)112-bit effective⚠️ LegacyDeprecated by NIST 2023; still in some legacy systems; much slower than AES
AES-128128-bit✅ ApprovedNIST standard; sufficient for most commercial use
AES-192192-bit✅ ApprovedAdditional margin; FIPS 140-3 approved
AES-256256-bit✅ ApprovedRecommended for highly sensitive data and quantum resistance
ChaCha20256-bit✅ ModernTLS 1.3 alternative to AES; hardware-efficient on mobile
Blowfish/TwofishVariable⚠️ NicheTwofish was AES finalist; still used in some applications
RC4Variable❌ DeprecatedMultiple vulnerabilities; prohibited in TLS

AES modes of operation — the mode determines how AES processes data blocks:

ModeDescriptionUseIssue
ECBEach block encrypted independently❌ AvoidIdentical plaintext blocks produce identical ciphertext — patterns preserved
CBCEach block XORed with previous ciphertext before encryptionLegacy file encryptionIV must be random; parallelization difficult
CTRTurns block cipher into stream cipher; counter encrypted then XORed with plaintextHigh-performance, parallelizableCounter must never repeat
GCMCTR mode + GHASH authenticationTLS 1.2/1.3, disk encryptionProvides authenticated encryption (confidentiality + integrity)

GCM is the preferred mode for most modern symmetric encryption because it provides both confidentiality and integrity authentication in a single, efficient operation.

Asymmetric Encryption:
AlgorithmKey SizeStatusPrimary Use
RSA2048-bit minimum; 3072+ recommended✅ Approved (with adequate key size)Key exchange, digital signatures, certificate signing
DSA2048-bit✅ ApprovedDigital signatures only (not encryption)
ECDSA256-bit (equivalent to RSA-3072)✅ Modern preferredDigital signatures in TLS certificates, code signing
ECDH256-bit✅ Modern preferredKey exchange in TLS 1.3; forward secrecy
ElGamal2048-bit⚠️ LegacyBasis for DSA; key exchange and encryption
Diffie-Hellman2048-bit minimum✅ ApprovedKey exchange; DHE/ECDHE provide forward secrecy

Hybrid encryption — how TLS and most practical systems work:

Forward secrecy — a property of key exchange where compromise of the long-term private key does not allow decryption of past sessions. Achieved through ephemeral key exchange (DHE or ECDHE) where a new key pair is generated for each session and discarded afterward. TLS 1.3 mandates forward secrecy; TLS 1.2 supports but doesn't require it.

⚠️ Exam Trap: RSA-1024 is no longer considered secure and has been deprecated. The current minimum for RSA is 2048 bits; 3072 bits is recommended for longer-term security. An exam question specifying RSA-1024 as a choice should be treated as a deprecated, insecure option — the same way DES is obviously wrong for symmetric encryption.

Reflection Question: A legacy application uses 3DES in CBC mode to encrypt database records. A new system is being designed. Which algorithm and mode should replace it, why is 3DES being retired, and what is CBC mode's specific weakness compared to the recommended replacement?

Alvin Varughese
Written byAlvin Varughese
Founder15 professional certifications