## Cryptography: ElGamal

Overview "If you can't explain it simply, you don't understand it well enough" Albert Einstein ElGamal is a public key cryptosystem that is used in encryption , digital signature and homomorphic cryptography.
Here is my take in 12 lines of Python code:
1 p = 7 2 g = [x for x in range(1, p) if len(set([x**i % p for i in range(1, p)])) == p-1][0] 3 k = 4 4 t = g**k % p 5 m = 6 6 import random 7 r = random.
[Read More]