Diffie-Hellman key exchange uses powers to find a shared secret.
One has to choose a
generator base b for the power (usually 2, 3, or 5) and a safe prime number N to be
the modulus, the (mod N) part. Typically this is done using a program like openssl dhgen -text
16
which for instance tells me to use N=35963 and b=2 for 16 bits of
security (can be broken in much less than a second; real world uses 2048 bits).
A=1 + 8, so you'll want to find 21, 22, 24, 28 (mod 11).
Secretly compute:
21 = (mod 11)
22 = (mod 11)
24 = (mod 11)
28 = (mod 11)
Now tell you “friend” your final number
bA = 29 = 21 × 28 = (mod 11).
Your friend publicly tells your their final number is
c=.
Secretly compute:
81 = (mod 11)
82 = (mod 11)
84 = (mod 11)
88 = (mod 11)
So that means your shared secret number is
cA = 89 = 81 × 88 = (mod 11).