diff options
author | Matt Caswell <matt@openssl.org> | 2019-03-20 17:51:29 +0000 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2019-04-09 10:24:43 +0100 |
commit | dc46e3dde58c781b5f29942d787a2c8765ba5514 (patch) | |
tree | f259798851a90aa2b7f38c4efa69db285a8ec7b6 /crypto/core_fetch.c | |
parent | 68ca1737ce58173001f2146b913388f872842f69 (diff) |
Use the right NID when putting a method in the store
When we attempt to fetch a method with a given NID we will ask the
providers for it if we don't already know about it. During that process
we may be told about other methods with a different NID. We need to
make sure we don't confuse the two.
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/8541)
Diffstat (limited to 'crypto/core_fetch.c')
-rw-r--r-- | crypto/core_fetch.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/crypto/core_fetch.c b/crypto/core_fetch.c index d38e1325c6..2c4b0d71de 100644 --- a/crypto/core_fetch.c +++ b/crypto/core_fetch.c @@ -35,8 +35,9 @@ static int ossl_method_construct_this(OSSL_PROVIDER *provider, void *cbdata) const OSSL_ALGORITHM *thismap = map++; void *method = NULL; - if ((method = data->mcm->construct(thismap->implementation, provider, - data->mcm_data)) == NULL) + if ((method = data->mcm->construct(thismap->algorithm_name, + thismap->implementation, provider, + data->mcm_data)) == NULL) continue; /* |