diff options
author | Pauli <paul.dale@oracle.com> | 2019-09-09 11:42:00 +1000 |
---|---|---|
committer | Pauli <paul.dale@oracle.com> | 2019-09-11 10:22:49 +1000 |
commit | 69333af49d8ddba6b551506ddbbccea73aee4a6b (patch) | |
tree | d29169304703cfab4cb5b77e7ff469088e37db9a /providers | |
parent | 2e548ac9a103f9366675d58dd52ced1889688231 (diff) |
Register KDF's using their name macros rather than strings
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/9814)
Diffstat (limited to 'providers')
-rw-r--r-- | providers/default/defltprov.c | 16 | ||||
-rw-r--r-- | providers/fips/fipsprov.c | 8 |
2 files changed, 12 insertions, 12 deletions
diff --git a/providers/default/defltprov.c b/providers/default/defltprov.c index 9ce918aea5..3f2ad610a9 100644 --- a/providers/default/defltprov.c +++ b/providers/default/defltprov.c @@ -212,17 +212,17 @@ static const OSSL_ALGORITHM deflt_macs[] = { }; static const OSSL_ALGORITHM deflt_kdfs[] = { - { "HKDF", "default=yes", kdf_hkdf_functions }, - { "SSKDF", "default=yes", kdf_sskdf_functions }, - { "PBKDF2", "default=yes", kdf_pbkdf2_functions }, - { "SSHKDF", "default=yes", kdf_sshkdf_functions }, - { "X963KDF", "default=yes", kdf_x963_kdf_functions }, - { "TLS1-PRF", "default=yes", kdf_tls1_prf_functions }, + { OSSL_KDF_NAME_HKDF, "default=yes", kdf_hkdf_functions }, + { OSSL_KDF_NAME_SSKDF, "default=yes", kdf_sskdf_functions }, + { OSSL_KDF_NAME_PBKDF2, "default=yes", kdf_pbkdf2_functions }, + { OSSL_KDF_NAME_SSHKDF, "default=yes", kdf_sshkdf_functions }, + { OSSL_KDF_NAME_X963KDF, "default=yes", kdf_x963_kdf_functions }, + { OSSL_KDF_NAME_TLS1_PRF, "default=yes", kdf_tls1_prf_functions }, #ifndef OPENSSL_NO_CMS - { "X942KDF", "default=yes", kdf_x942_kdf_functions }, + { OSSL_KDF_NAME_X942KDF, "default=yes", kdf_x942_kdf_functions }, #endif #ifndef OPENSSL_NO_SCRYPT - { "id-scrypt", "default=yes", kdf_scrypt_functions }, + { OSSL_KDF_NAME_SCRYPT, "default=yes", kdf_scrypt_functions }, #endif { NULL, NULL, NULL } }; diff --git a/providers/fips/fipsprov.c b/providers/fips/fipsprov.c index 98ec491458..e5bb9b41d6 100644 --- a/providers/fips/fipsprov.c +++ b/providers/fips/fipsprov.c @@ -346,10 +346,10 @@ static const OSSL_ALGORITHM fips_macs[] = { }; static const OSSL_ALGORITHM fips_kdfs[] = { - { "HKDF", "fips=yes", kdf_hkdf_functions }, - { "SSKDF", "fips=yes", kdf_sskdf_functions }, - { "PBKDF2", "fips=yes", kdf_pbkdf2_functions }, - { "TLS1-PRF", "fips=yes", kdf_tls1_prf_functions }, + { OSSL_KDF_NAME_HKDF, "fips=yes", kdf_hkdf_functions }, + { OSSL_KDF_NAME_SSKDF, "fips=yes", kdf_sskdf_functions }, + { OSSL_KDF_NAME_PBKDF2, "fips=yes", kdf_pbkdf2_functions }, + { OSSL_KDF_NAME_TLS1_PRF, "fips=yes", kdf_tls1_prf_functions }, { NULL, NULL, NULL } }; |