Example
Show both sides compute the same toy shared secret.
highlighted = computed this step
Step 1 — Alice secret
Compute the highlighted cryptography value.
B power a mod p2
Step 2 — Bob secret
Compute the highlighted cryptography value.
A power b mod p2
Step 3 — Verdict
Compute the highlighted cryptography value.
verdictmatch
cryptography
The values in this lesson are deliberately tiny so every modular arithmetic step can be checked exactly.