My sincerest apologies for having to repost this but I can't edit or post a comment from the previous one I asked with a guest account.
I'm learning about the Diffie-Hellman and ElGamal ciphers, but I'm really struggling trying to decipher the exercise my lecturer has given me.
The information I've been given (all in decimals) is
a (Alice private key)
A (Alice public key)
B (Bob public key)
I've tried calculating a shared secret S = B^a mod p then inversing it and multiplying that by C as my lecturer described in the lecture but it doesn't work. Is that wrong and if yes what am I supposed to do??
I used this tool to perform the inverse operation (inverseMod(a,b)) http://www.mobilefish.com/services/big_number_equation/big_number_equation.php