tc26 paramSetA 512 for GOST 34.1002012

This commit is contained in:
orignal 2017-03-14 21:15:17 -04:00
parent af2a3f3a65
commit da2c49ab66
3 changed files with 10 additions and 1 deletions

View file

@ -535,7 +535,7 @@ namespace crypto
{
uint8_t digest[Hash::hashLen];
Hash::CalculateHash (buf, len, digest);
BIGNUM * d = BN_bin2bn (digest, 32, nullptr);
BIGNUM * d = BN_bin2bn (digest, Hash::hashLen, nullptr);
BIGNUM * r = BN_new (), * s = BN_new ();
GetGOSTR3410Curve (m_ParamSet)->Sign (m_PrivateKey, d, r, s);
bn2buf (r, signature, keyLen);