From 8aeacc0ac2c5e336ea169f227b4ce37a05402b53 Mon Sep 17 00:00:00 2001 From: Paul Duncan Date: Tue, 5 Sep 2023 02:03:12 -0400 Subject: sha3.[hc]: add header w/ spdx license identifier and library description --- sha3.c | 32 +++++++++++++++++++++++++++++--- sha3.h | 30 ++++++++++++++++++++++++++++-- 2 files changed, 57 insertions(+), 5 deletions(-) diff --git a/sha3.c b/sha3.c index b03e0f3..8439b5b 100644 --- a/sha3.c +++ b/sha3.c @@ -1,6 +1,32 @@ -// -// FIPS202 (SHA-3) implementation. -// +/** + * sha3 + * https://pablotron.org/sha3 + * + * Copyright (c) 2023 Paul Duncan + * SPDX-License-Identifier: MIT-0 + * + * C11 implementations of the following SHA-3 algorithms: + * + * - SHA3-224 + * - SHA3-256 + * - SHA3-384 + * - SHA3-512 + * - HMAC-SHA3-224 + * - HMAC-SHA3-256 + * - HMAC-SHA3-384 + * - HMAC-SHA3-512 + * - SHAKE128 and SHAKE128-XOF + * - SHAKE256 and SHAKE256-XOF + * - cSHAKE128 and cSHAKE128-XOF + * - cSHAKE256 and cSHAKE256-XOF + * - KMAC128 and KMAC128-XOF + * - KMAC256 and KMAC256-XOF + * - TupleHash128 and TupleHash128-XOF + * - TupleHash256 and TupleHash256-XOF + * - ParallelHash128 and ParallelHash128-XOF + * - ParallelHash256 and ParallelHash256-XOF + * - TurboHash128 and TurboHash256 (incomplete) + */ #include // true, false #include // uint64_t diff --git a/sha3.h b/sha3.h index eb6ffd8..aa21303 100644 --- a/sha3.h +++ b/sha3.h @@ -1,7 +1,33 @@ /** - * C11 implementations of SHA-3 algorithms from FIPS 202 and NIST SP - * 800-185. + * sha3 + * https://pablotron.org/sha3 + * + * Copyright (c) 2023 Paul Duncan + * SPDX-License-Identifier: MIT-0 + * + * C11 implementations of the following SHA-3 algorithms: + * + * - SHA3-224 + * - SHA3-256 + * - SHA3-384 + * - SHA3-512 + * - HMAC-SHA3-224 + * - HMAC-SHA3-256 + * - HMAC-SHA3-384 + * - HMAC-SHA3-512 + * - SHAKE128 and SHAKE128-XOF + * - SHAKE256 and SHAKE256-XOF + * - cSHAKE128 and cSHAKE128-XOF + * - cSHAKE256 and cSHAKE256-XOF + * - KMAC128 and KMAC128-XOF + * - KMAC256 and KMAC256-XOF + * - TupleHash128 and TupleHash128-XOF + * - TupleHash256 and TupleHash256-XOF + * - ParallelHash128 and ParallelHash128-XOF + * - ParallelHash256 and ParallelHash256-XOF + * - TurboHash128 and TurboHash256 (incomplete) */ + #ifndef SHA3_H #define SHA3_H -- cgit v1.2.3