projects
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
35426b2
)
PEM: Have pem_read_bio_key() set the OSSL_STORE expected type
author
Richard Levitte
<levitte@openssl.org>
Wed, 28 Oct 2020 18:11:24 +0000
(19:11 +0100)
committer
Richard Levitte
<levitte@openssl.org>
Wed, 11 Nov 2020 10:42:06 +0000
(11:42 +0100)
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/13248)
crypto/pem/pem_pkey.c
patch
|
blob
|
history
diff --git
a/crypto/pem/pem_pkey.c
b/crypto/pem/pem_pkey.c
index 5ecae8651b4363cee745bfd04702762112891747..e6c07b8fd6065910b0257b979930d2ac6a0bf45e 100644
(file)
--- a/
crypto/pem/pem_pkey.c
+++ b/
crypto/pem/pem_pkey.c
@@
-67,6
+67,9
@@
static EVP_PKEY *pem_read_bio_key(BIO *bp, EVP_PKEY **x,
# endif
#endif
+ if (!OSSL_STORE_expect(ctx, expected_store_info_type))
+ goto err;
+
while (!OSSL_STORE_eof(ctx)
&& (info = OSSL_STORE_load(ctx)) != NULL) {
if (OSSL_STORE_INFO_get_type(info) == expected_store_info_type) {