Diffie-Hellman for a public-key handshake
Built for hobbyists & makers exploring it for fun. Play with real physics and math, no license and no setup — just open and tinker. Simulate a public-key handshake live below — adjust the inputs and watch it respond, right in your browser.
Controls
Presets
Diffie-Hellman lets two strangers agree on a secret key while an eavesdropper hears everything. Both share public numbers g and p, each picks a private exponent, and they exchange g raised to it. Raising the other's public value to your own secret yields the same shared key — yet recovering it from the public traffic requires solving the discrete logarithm, which is infeasible.
Data Inspector
Governing equation
Runs locally in your browser — free forever. Scale to the cloud when reality gets heavy.
More with Diffie-Hellman
Frequently asked questions
- Is this good for hobbyists & makers?
- Yes — this version of "Diffie-Hellman for a public-key handshake" is framed for hobbyists & makers exploring it for fun. Play with real physics and math, no license and no setup — just open and tinker.
- Do I need to install anything?
- No. It runs in any modern browser, free, with no account required.