Prove forward secrecy by looking at what a key recovers

short · 50 min · Objective 3.3

Task

Capture two sessions -- one negotiated with forward secrecy and one without -- and demonstrate that possession of the server key decrypts only one of them.

Steps

  1. Stand up the server with a certificate and key you hold, and configure it to permit a non-forward-secret key exchange. That exists only up to TLS 1.2 -- TLS 1.3 removed RSA key transport, so every full TLS 1.3 handshake is forward-secret -- so cap the server at TLS 1.2 for the whole lab and allow an RSA key-exchange suite: openssl s_server -tls1_2 -cipher AES256-GCM-SHA384 ..., or ssl_protocols TLSv1.2; in nginx.
  2. Capture a session negotiated WITHOUT forward secrecy, then decrypt the capture using the server private key, and record the result in lab/fs-without.txt.
  3. Restrict the server to forward-secret suites only, still at TLS 1.2 (-cipher ECDHE-RSA-AES256-GCM-SHA384), capture another session, attempt the same decryption with the same key, and record the failure in lab/fs-with.txt.
  4. Record the negotiated cipher suite for each session in lab/fs-suites.txt, as the client reports it (Cipher is ... in openssl s_client output). Keep both sessions at TLS 1.2: a TLS 1.3 suite name such as TLS_AES_256_GCM_SHA384 does not mention the key exchange at all, so it would not show the forward secrecy the Verify looks for.
  5. Write lab/fs-note.md on what this means for an organisation that decrypts traffic for inspection by giving a device the server key, and where inspection has to move instead.

Verify

grep -Eic 'decrypt|plaintext|http' lab/fs-without.txt
grep -Eic 'cannot|unable|no session key|fail' lab/fs-with.txt
grep -Eic 'ecdhe|dhe' lab/fs-suites.txt
grep -Eci 'endpoint|terminating proxy|inspection' lab/fs-note.md

A successful decryption WITHOUT forward secrecy and a failed one WITH it, the suites recorded, and the note naming where inspection has to move. The pair is the evidence; either alone proves nothing.

This is an independent study companion for CompTIA SecurityX CAS-005 and is not produced by or endorsed by CompTIA.