aboutsummaryrefslogtreecommitdiff
path: root/providers
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2020-04-07 11:10:02 +0100
committerMatt Caswell <matt@openssl.org>2020-04-09 16:10:00 +0100
commit5435044fd6007f8a649f8fc75a043221931d4bf1 (patch)
tree1418352b258f90206d4b12f28b787ef607a4ff70 /providers
parentbbe3ed06d7bed1bed75d4816665539c959741d2d (diff)
downloadopenssl-5435044fd6007f8a649f8fc75a043221931d4bf1.zip
openssl-5435044fd6007f8a649f8fc75a043221931d4bf1.tar.gz
openssl-5435044fd6007f8a649f8fc75a043221931d4bf1.tar.bz2
Enable Ed25519 signing/verifying to use the libctx
Ed25519 needs to fetch a digest and so needs to use the correct libctx. Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org> (Merged from https://github.com/openssl/openssl/pull/11496)
Diffstat (limited to 'providers')
-rw-r--r--providers/implementations/signature/eddsa.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/providers/implementations/signature/eddsa.c b/providers/implementations/signature/eddsa.c
index d2444f9..1a7bf94 100644
--- a/providers/implementations/signature/eddsa.c
+++ b/providers/implementations/signature/eddsa.c
@@ -87,7 +87,8 @@ int ed25519_digest_sign(void *vpeddsactx, unsigned char *sigret,
return 0;
}
- if (ED25519_sign(sigret, tbs, tbslen, edkey->pubkey, edkey->privkey) == 0) {
+ if (ED25519_sign(sigret, tbs, tbslen, edkey->pubkey, edkey->privkey,
+ peddsactx->libctx, NULL) == 0) {
PROVerr(0, PROV_R_FAILED_TO_SIGN);
return 0;
}
@@ -130,7 +131,8 @@ int ed25519_digest_verify(void *vpeddsactx, const unsigned char *sig,
if (siglen != ED25519_SIGSIZE)
return 0;
- return ED25519_verify(tbs, tbslen, sig, edkey->pubkey);
+ return ED25519_verify(tbs, tbslen, sig, edkey->pubkey, peddsactx->libctx,
+ NULL);
}
int ed448_digest_verify(void *vpeddsactx, const unsigned char *sig,