Kryptographie


Hauptthemen der Kryptographie für Pentester

1. Symmetrische Kryptographie

  • AES (insb. AES-GCM & AES-CTR)
  • Betriebsmodi (CBC, CTR, GCM)
  • IV/Nonce-Handling
  • MAC/HMAC
  • Authenticated Encryption (AEAD)

2. Asymmetrische Kryptographie

  • RSA (Verschlüsselung & Signaturen)
  • ECC (ECDSA, ECDH)
  • Diffie-Hellman (DH, ECDH)
  • Key Exchange & Padding (PKCS#1, OAEP)

3. Hashfunktionen

  • SHA-2 / SHA-3
  • BLAKE2/BLAKE3
  • Unsichere Hashes: MD5, SHA-1
  • Kollisionen, Präbilder, Integrität

4. Passwort-Hashing & Cracking

  • bcrypt, PBKDF2, scrypt, Argon2
  • Salt, Pepper
  • Offline-Cracking (hashcat, JtR)
  • Hash-Misuse in Apps

5. Digitale Signaturen & PKI

  • RSA-PSS, ECDSA, EdDSA
  • X.509-Zertifikate
  • TLS-Zertifikatsvalidierung
  • Certificate Pinning (Web/Mobile)

6. TLS/SSL & SSH Kryptographie

  • TLS 1.2/1.3 Handshake
  • Cipher Suites
  • Perfect Forward Secrecy
  • SSH Key Exchange, Ciphers, MACs
  • Häufige Fehlkonfigurationen

7. Krypto-Misuse in Anwendungen

  • Hardcoded Keys
  • Falsche Modi (z. B. ECB)
  • Unsichere Randomness
  • Nonce/IV Reuse
  • Custom Crypto
  • Fehlimplementierte JWT/Cookies

8. Krypto-Angriffe (praktisch für Pentester)

  • Padding Oracle Attacks
  • Bleichenbacher RSA
  • Replay & Downgrade Attacks
  • Weak Key/Short Key Attacks
  • Timing Attacks (High-Level)
  • JWT None-Exploit, Algorithm Switch

9. Token, API-Auth & Web-Kryptographie

  • JWT (HS256/RS256, kid-Parameter, JWK)
  • OAuth2/OIDC Signaturen
  • HMAC-gesicherte API-Requests
  • Signed Cookies
  • CSRF-Tokens (kryptographisch)

10. Cryptographic Storage in Apps

  • Secure Storage vs. Plaintext
  • Mobile App KeyStore/KeyChain
  • Datenbanken: TDE, Application-Level-Encryption
  • Secret Management (Vault, KMS)

11. Key Management & Lifecycle

  • Key-Generierung
  • Key Rotation
  • Secrets Management
  • Cloud KMS / Vault
  • Umgang mit kompromittierten Schlüsseln

12. Post-Quanten Kryptographie (nur Überblick)

  • Kyber (KEM)
  • Dilithium (Signatur)
  • Relevanz für TLS/SSH
  • Hybrid-Kex