Rename the hash implementations KMAC{128,256} to KECCAK_KMAC{128,256}

This avoids getting them confused with the MAC implementations.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/8877)
This commit is contained in:
Richard Levitte 2019-08-13 10:20:05 +02:00
parent 810a1d0320
commit bb31895d87
3 changed files with 10 additions and 10 deletions

View file

@ -203,12 +203,12 @@ static void *kmac_fetch_new(void *provctx, const char *mdname)
static void *kmac128_new(void *provctx)
{
return kmac_fetch_new(provctx, "KMAC128");
return kmac_fetch_new(provctx, "KECCAK_KMAC128");
}
static void *kmac256_new(void *provctx)
{
return kmac_fetch_new(provctx, "KMAC256");
return kmac_fetch_new(provctx, "KECCAK_KMAC256");
}
static void *kmac_dup(void *vsrc)

View file

@ -66,11 +66,11 @@ static const OSSL_ALGORITHM deflt_digests[] = {
{ "SHA3-512", "default=yes", sha3_512_functions },
/*
* KMAC128 and KMAC256 as hashes are mostly useful for the MACs with the
* same names
* KECCAK_KMAC128 and KECCAK_KMAC256 as hashes are mostly useful for
* the KMAC128 and KMAC256.
*/
{ "KMAC128", "default=yes", keccak_kmac_128_functions },
{ "KMAC256", "default=yes", keccak_kmac_256_functions },
{ "KECCAK_KMAC128", "default=yes", keccak_kmac_128_functions },
{ "KECCAK_KMAC256", "default=yes", keccak_kmac_256_functions },
{ "SHAKE128", "default=yes", shake_128_functions },
{ "SHAKE256", "default=yes", shake_256_functions },

View file

@ -253,11 +253,11 @@ static const OSSL_ALGORITHM fips_digests[] = {
{ "SHA3-384", "fips=yes", sha3_384_functions },
{ "SHA3-512", "fips=yes", sha3_512_functions },
/*
* KMAC128 and KMAC256 as hashes are mostly useful for the MACs with the
* same names
* KECCAK_KMAC128 and KECCAK_KMAC256 as hashes are mostly useful for
* the KMAC128 and KMAC256.
*/
{ "KMAC128", "fips=yes", keccak_kmac_128_functions },
{ "KMAC256", "fips=yes", keccak_kmac_256_functions },
{ "KECCAK_KMAC128", "fips=yes", keccak_kmac_128_functions },
{ "KECCAK_KMAC256", "fips=yes", keccak_kmac_256_functions },
{ NULL, NULL, NULL }
};