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 + 2 + 4, so you'll want to find 21, 22, 24 (mod 11).
Secretly compute:
21 = (mod 11)
22 = (mod 11)
24 = (mod 11)
Now tell you “friend” your final number
bA = 27 = 21 × 22 × 24 = (mod 11).
Your friend publicly tells your their final number is
c=.
Secretly compute:
41 = (mod 11)
42 = (mod 11)
44 = (mod 11)
So that means your shared secret number is
cA = 47 = 41 × 42 × 44 = (mod 11).