示例#1
0
 public override byte[] Sign(byte[] p_hashcode)
 {
     if (NeedToGenerateKey())
     {
         CreateKeyPair(KeySizeValue);
     }
     return(ElGamalSignature.CreateSignature(p_hashcode, o_key_struct));
 }
示例#2
0
 public override bool VerifySignature(byte[] p_hashcode, byte[] p_signature)
 {
     if (NeedToGenerateKey())
     {
         CreateKeyPair(KeySizeValue);
     }
     return(ElGamalSignature.VerifySignature(p_hashcode,
                                             p_signature, o_key_struct));
 }
示例#3
0
 public override byte[] Sign(byte[] p_hashcode)
 {
     if (NeedToGenerateKey())
     {
         // we need to create a new key before we can export
         CreateKeyPair(KeySizeValue);
     }
     return(ElGamalSignature.CreateSignature(p_hashcode, o_key_struct));
 }