From 8ef2a4e5f54c8623c98c396e378ec093629b849b Mon Sep 17 00:00:00 2001 From: Paul Selkirk Date: Sun, 6 Jun 2021 23:01:11 -0400 Subject: Add support for the SHA-3 core. --- hal_internal.h | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'hal_internal.h') diff --git a/hal_internal.h b/hal_internal.h index 15f4c79..d757027 100644 --- a/hal_internal.h +++ b/hal_internal.h @@ -4,7 +4,9 @@ * Internal API declarations for libhal. * * Authors: Rob Austein, Paul Selkirk - * Copyright (c) 2015, NORDUnet A/S All rights reserved. + * Copyright (c) 2015-2018, NORDUnet A/S All rights reserved. + * Copyright: 2021, The Commons Conservancy Cryptech Project + * SPDX-License-Identifier: BSD-3-Clause * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -16,9 +18,9 @@ * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * - * - Neither the name of the NORDUnet nor the names of its contributors may - * be used to endorse or promote products derived from this software - * without specific prior written permission. + * - Neither the name of the the copyright holder nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED @@ -154,8 +156,9 @@ extern hal_error_t hal_free_static_memory(const void * const ptr); * Longest hash block and digest we support at the moment. */ -#define HAL_MAX_HASH_BLOCK_LENGTH SHA512_BLOCK_LEN -#define HAL_MAX_HASH_DIGEST_LENGTH SHA512_DIGEST_LEN +#define HAL_MAX_HASH_BLOCK_LENGTH SHA3_STATE_LEN +#define HAL_MAX_HASH_DIGEST_LENGTH SHA3_512_DIGEST_LEN +#define HAL_MAX_HASH_STATE_LENGTH SHA3_STATE_LEN /* * Locks and critical sections. -- cgit v1.2.3