El Gamal

In[28]:=

elgamalc = Module[{len, m, c}, c = {} ; len = Length[plaintexts] ; Do[j = Random[Integer, {1,  ... exts[[j]] ; c = Append[c, {elgamalpk[[i]], ElGamalEncipher[m, elgamalpk[[i, 2]]]}], {i, len}] ; c]

Out[28]=

{{{Baxter, {601, 7, 82}}, {1, {22, 7, 0, 19, 20, 15}}}, {{Beury, {557, 2, 113}}, {155, {54, 0, ...  77}}, {614, {235, 0, 632, 176, 0, 485}}}, {{Williamson, {719, 11, 199}}, {683, {504, 571, 290}}}}


Created by Mathematica  (November 3, 2004)