Ascon-Hash256 hash function. More...
Go to the source code of this file.
Macros | |
#define | TRACE_LEVEL CRYPTO_TRACE_LEVEL |
Functions | |
__weak_func error_t | asconHash256Compute (const void *data, size_t length, uint8_t *digest) |
Digest a message using Ascon-Hash256. More... | |
void | asconHash256Init (AsconHash256Context *context) |
Initialize Ascon-Hash256 message digest context. More... | |
void | asconHash256Update (AsconHash256Context *context, const void *data, size_t length) |
Update the Ascon-Hash256 context with a portion of the message being hashed. More... | |
void | asconHash256Final (AsconHash256Context *context, uint8_t *digest) |
Finish the Ascon-Hash256 message digest. More... | |
Variables | |
const uint8_t | ASCON_HASH256_OID [1] = {0x00} |
const HashAlgo | asconHash256HashAlgo |
Detailed Description
Ascon-Hash256 hash function.
License
SPDX-License-Identifier: GPL-2.0-or-later
Copyright (C) 2010-2025 Oryx Embedded SARL. All rights reserved.
This file is part of CycloneCRYPTO Open.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
Description
Ascon-Hash256 is a cryptographic hash function that produces a 256-bit hash of the input messages, offering a security strength of 128 bits
- Version
- 2.5.0
Definition in file ascon_hash256.c.
Macro Definition Documentation
◆ TRACE_LEVEL
#define TRACE_LEVEL CRYPTO_TRACE_LEVEL |
Definition at line 37 of file ascon_hash256.c.
Function Documentation
◆ asconHash256Compute()
__weak_func error_t asconHash256Compute | ( | const void * | data, |
size_t | length, | ||
uint8_t * | digest | ||
) |
Digest a message using Ascon-Hash256.
- Parameters
-
[in] data Pointer to the message being hashed [in] length Length of the message [out] digest Pointer to the calculated digest
- Returns
- Error code
Definition at line 76 of file ascon_hash256.c.
◆ asconHash256Final()
void asconHash256Final | ( | AsconHash256Context * | context, |
uint8_t * | digest | ||
) |
Finish the Ascon-Hash256 message digest.
- Parameters
-
[in] context Pointer to the Ascon-Hash256 context [out] digest Calculated digest
Definition at line 195 of file ascon_hash256.c.
◆ asconHash256Init()
void asconHash256Init | ( | AsconHash256Context * | context | ) |
Initialize Ascon-Hash256 message digest context.
- Parameters
-
[in] context Pointer to the Ascon-Hash256 context to initialize
Definition at line 121 of file ascon_hash256.c.
◆ asconHash256Update()
void asconHash256Update | ( | AsconHash256Context * | context, |
const void * | data, | ||
size_t | length | ||
) |
Update the Ascon-Hash256 context with a portion of the message being hashed.
- Parameters
-
[in] context Pointer to the Ascon-Hash256 context [in] data Pointer to the buffer being hashed [in] length Length of the buffer
Definition at line 151 of file ascon_hash256.c.
Variable Documentation
◆ ASCON_HASH256_OID
const uint8_t ASCON_HASH256_OID[1] = {0x00} |
Definition at line 47 of file ascon_hash256.c.
◆ asconHash256HashAlgo
const HashAlgo asconHash256HashAlgo |
Definition at line 50 of file ascon_hash256.c.