summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortb <>2024-01-27 16:17:32 +0000
committertb <>2024-01-27 16:17:32 +0000
commit2b8845683a31465d2272c7d1ca8fc49201bde55d (patch)
treef2f11063d45306194e7ec83ce5aab699a4ae3a5d /src
parentfa5808c10d4148106c5352199c21acab20f0490c (diff)
downloadopenbsd-2b8845683a31465d2272c7d1ca8fc49201bde55d.tar.gz
openbsd-2b8845683a31465d2272c7d1ca8fc49201bde55d.tar.bz2
openbsd-2b8845683a31465d2272c7d1ca8fc49201bde55d.zip
Support HMAC with truncated SHA-2 as a PBE PRF
ok jsing
Diffstat (limited to 'src')
-rw-r--r--src/lib/libcrypto/evp/evp_pbe.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/lib/libcrypto/evp/evp_pbe.c b/src/lib/libcrypto/evp/evp_pbe.c
index 8553478bc4..ed5f97b6e7 100644
--- a/src/lib/libcrypto/evp/evp_pbe.c
+++ b/src/lib/libcrypto/evp/evp_pbe.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: evp_pbe.c,v 1.34 2023/12/18 13:12:43 tb Exp $ */ 1/* $OpenBSD: evp_pbe.c,v 1.35 2024/01/27 16:17:32 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 1999. 3 * project 1999.
4 */ 4 */
@@ -216,6 +216,16 @@ static const struct pbe_config pbe_prf[] = {
216 .cipher_nid = -1, 216 .cipher_nid = -1,
217 .md_nid = NID_id_tc26_gost3411_2012_512, 217 .md_nid = NID_id_tc26_gost3411_2012_512,
218 }, 218 },
219 {
220 .pbe_nid = NID_hmacWithSHA512_224,
221 .cipher_nid = -1,
222 .md_nid = NID_sha512_224,
223 },
224 {
225 .pbe_nid = NID_hmacWithSHA512_256,
226 .cipher_nid = -1,
227 .md_nid = NID_sha512_256,
228 },
219}; 229};
220 230
221#define N_PBE_PRF (sizeof(pbe_prf) / sizeof(pbe_prf[0])) 231#define N_PBE_PRF (sizeof(pbe_prf) / sizeof(pbe_prf[0]))