424 B
424 B
toy Diffie-Hellman key exchange
Only works for ~most 32 bit unsigned-integers.
nix run git+https://git.pyrope.net/mbk/diffie-hellman
Run with
- 0 arguments to generate a public
pandg - 2 arguments (
pandg) to generate the publicg^a mod p - 3 arguments (
p,g, andg^b mod p) to generate the final shared secret
a is provided with a passwordlike input.
You have to make your own a, sorry