3 ms·
The math behind DH is pretty simple and really interesting.
by mikefallen 5y ago
The math behind DH is pretty simple and really interesting.
- eru 5y agoYes. Though having heard of modulo arithmetic before helps a lot. So eg simple enough for your typical HN crowd. There's also an interesting public key encryption system you can build on top of DH called ElGamal. https://en.wikipedia.org/wiki/ElGamal_encryption https://en.wikipedia.org/wiki/ElGamal_encryption What makes ElGamal so interesting, is that it's probabilistic and that you can easily prove its semantic security (from relatively straightforward assumptions), and more importantly 'indistinguishability under Chosen Plaintext Attack' (https://en.wikipedia.org/wiki/Ciphertext_indistinguishability#IND-CPA https://en.wikipedia.org/wiki/Ciphertext_indistinguishabilit...) Ie even if the attacker can guess your plaintext and knows the public key, they can't be sure that they guessed right.