How do you decrypt SSH .pcap file that uses Diffie Hellman encryption. With public and private keys

cchang picture cchang · Oct 26, 2009 · Viewed 24.5k times · Source

How do you decrypt SSH .pcap file that uses Diffie Hellman encryption. With public and private keys.

We are trying through Wireshark with no luck.

Answer

erickson picture erickson · Oct 26, 2009

One of the benefits of ephemeral Diffie-Hellman (the DHE ciphersuites of TLS) is that it provides perfect forward secrecy. This means that even if the private DSA key used to authenticate the server (and possibly client) are obtained by an attacker someday, she won't be able to go back and decrypt any sessions captured in the past.

In other words, you can't decrypt these captures unless you recorded the secret session key; there's no way to recover it afterward.

This is different than the RSA cipher suites, where knowledge of the server private key allows one to decrypt the session.