diff options
| author | tb <> | 2023-03-07 07:01:35 +0000 |
|---|---|---|
| committer | tb <> | 2023-03-07 07:01:35 +0000 |
| commit | e67f9e65948ede08383b3f3e867520b37c8f7553 (patch) | |
| tree | e4d2a98e8592dfa1bd9b06ca9374670ac8f778eb /src | |
| parent | 9a319239aa9791b8d59bd245ae1eb82cd3d46720 (diff) | |
| download | openbsd-e67f9e65948ede08383b3f3e867520b37c8f7553.tar.gz openbsd-e67f9e65948ede08383b3f3e867520b37c8f7553.tar.bz2 openbsd-e67f9e65948ede08383b3f3e867520b37c8f7553.zip | |
Fix another return value check for CMS_SharedInfo_encode()
This should have been included in a previous diff/commit...
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libcrypto/ec/ec_ameth.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/libcrypto/ec/ec_ameth.c b/src/lib/libcrypto/ec/ec_ameth.c index a3ac989e6f..e47dcbc7c0 100644 --- a/src/lib/libcrypto/ec/ec_ameth.c +++ b/src/lib/libcrypto/ec/ec_ameth.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ec_ameth.c,v 1.37 2023/03/06 08:37:24 tb Exp $ */ | 1 | /* $OpenBSD: ec_ameth.c,v 1.38 2023/03/07 07:01:35 tb Exp $ */ |
| 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
| 3 | * project 2006. | 3 | * project 2006. |
| 4 | */ | 4 | */ |
| @@ -814,7 +814,7 @@ ecdh_cms_set_shared_info(EVP_PKEY_CTX *pctx, CMS_RecipientInfo *ri) | |||
| 814 | goto err; | 814 | goto err; |
| 815 | 815 | ||
| 816 | plen = CMS_SharedInfo_encode(&der, kekalg, ukm, keylen); | 816 | plen = CMS_SharedInfo_encode(&der, kekalg, ukm, keylen); |
| 817 | if (!plen) | 817 | if (plen <= 0) |
| 818 | goto err; | 818 | goto err; |
| 819 | 819 | ||
| 820 | if (EVP_PKEY_CTX_set0_ecdh_kdf_ukm(pctx, der, plen) <= 0) | 820 | if (EVP_PKEY_CTX_set0_ecdh_kdf_ukm(pctx, der, plen) <= 0) |
