diff options
author | Pierre Pronchery <pierre@freebsdfoundation.org> | 2023-05-31 22:06:50 +0000 |
---|---|---|
committer | Ed Maste <emaste@FreeBSD.org> | 2023-06-23 13:13:27 +0000 |
commit | b84c4564effd02dfdc047dd6cbeaf910bbb1a888 (patch) | |
tree | 39604e7e6f13fced003ef2f77c35f3989aa574ca /crypto/dsa/dsa_backend.c | |
parent | e4520c8bd1d300a7a338d0ed4af171a2d0e583ef (diff) |
Diffstat (limited to 'crypto/dsa/dsa_backend.c')
-rw-r--r-- | crypto/dsa/dsa_backend.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/crypto/dsa/dsa_backend.c b/crypto/dsa/dsa_backend.c index f9a71bdc9e0b..389df304bdce 100644 --- a/crypto/dsa/dsa_backend.c +++ b/crypto/dsa/dsa_backend.c @@ -1,5 +1,5 @@ /* - * Copyright 2020-2022 The OpenSSL Project Authors. All Rights Reserved. + * Copyright 2020-2023 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy @@ -173,7 +173,10 @@ DSA *ossl_dsa_key_from_pkcs8(const PKCS8_PRIV_KEY_INFO *p8inf, ERR_raise(ERR_LIB_DSA, DSA_R_BN_ERROR); goto dsaerr; } - DSA_set0_key(dsa, dsa_pubkey, dsa_privkey); + if (!DSA_set0_key(dsa, dsa_pubkey, dsa_privkey)) { + ERR_raise(ERR_LIB_DSA, ERR_R_INTERNAL_ERROR); + goto dsaerr; + } goto done; |