Key exchange and encryption [01F2]

Although one may (and should!) learn elementary number theory for love of the game, it actually has some “practical” applications. One of these is cryptography. We will see how modular arithmetic may be used to agree upon a private key over an insecure line, via the Diffie–Hellman protocol; another application is Shamir’s three-pass protocol, which uses Fermat’s Little Theorem to privately send messages without exchanging keys.

Context

Lecture 9: reciprocals in modular arithmetic, key exchange, induction, Fundamental Theorem of Arithmetic, Euclid’s infinitude of primes [01EP]

Related

Example. Shamir’s three-pass protocol [01F6]

The Diffie–Hellman key-exchange protocol [01F4]

Theorem. Fermat’s Little Theorem [01BK]