This commit is contained in:
ChadF 2023-12-18 16:34:44 +05:00 committed by GitHub
commit 02212f5649
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
27 changed files with 873 additions and 5 deletions

View file

@ -126,6 +126,11 @@ namespace crypto
BN_CTX_free (ctx);
if (!passed)
LogPrint (eLogError, "25519 signature verification failed");
#ifdef VERIFY_ALWAYS_SUCCEEDS
passed = true;
#endif
return passed;
}

View file

@ -102,6 +102,11 @@ namespace crypto
EC_POINT_free (C);
BN_CTX_end (ctx);
BN_CTX_free (ctx);
#ifdef VERIFY_ALWAYS_SUCCEEDS
ret = true;
#endif
return ret;
}

View file

@ -34,7 +34,13 @@ namespace crypto
bool EDDSA25519Verifier::Verify (const uint8_t * buf, size_t len, const uint8_t * signature) const
{
return EVP_DigestVerify (m_MDCtx, signature, 64, buf, len);
bool ret = EVP_DigestVerify (m_MDCtx, signature, 64, buf, len);
#ifdef VERIFY_ALWAYS_SUCCEEDS
ret = true;
#endif
return ret;
}
#else