Files
wolfssl/tests/api/test_blake2.h
T
Daniele Lacamera 45a98467e4 tests: MC/DC decision coverage for remaining wolfCrypt primitives
Add DecisionCoverage/FeatureCoverage tests and tests/unit-mcdc white-box
supplements for the remaining reachable wolfCrypt primitive sources in the
ISO 26262 per-module MC/DC campaign (excluding asn* and the EVP/OpenSSL
compat layer, which are out of the MC/DC boundary).

tests/api:
- legacy ciphers / digests: des3, camellia, ascon, blake2, siphash
- niche PK: srp, eccsi, sakke, hpke
- native PQC KEM: frodokem
- math: wolfmath

tests/unit-mcdc white-box drivers (#include the .c to reach file-static
helpers and impl-selected paths, standalone main()/WB_NOTE harness):
- blake2b, blake2s
- eccsi, sakke, hpke
- SP host backends: sp_x86_64, sp_c64, sp_c32
- infra: cryptocb (dev && dev->cb dispatch three-vector, 127/127),
  logging (per-thread + global error-queue impls, 19/19),
  memory (static-pool allocator, 46/48)

Registrations in tests/api.c, tests/api/include.am and CMakeLists.txt.
2026-07-31 12:56:51 +02:00

62 lines
2.4 KiB
C

/* test_blake2.h
*
* Copyright (C) 2006-2026 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL 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 3 of the License, or
* (at your option) any later version.
*
* wolfSSL 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-1335, USA
*/
#ifndef WOLFCRYPT_TEST_BLAKE2_H
#define WOLFCRYPT_TEST_BLAKE2_H
#include <tests/api/api_decl.h>
int test_wc_InitBlake2b(void);
int test_wc_InitBlake2b_WithKey(void);
int test_wc_Blake2bUpdate(void);
int test_wc_Blake2bFinal(void);
int test_wc_Blake2b_KATs(void);
int test_wc_Blake2b_other(void);
int test_wc_blake2b_decision_coverage(void);
int test_wc_InitBlake2s(void);
int test_wc_InitBlake2s_WithKey(void);
int test_wc_Blake2sUpdate(void);
int test_wc_Blake2sFinal(void);
int test_wc_Blake2s_KATs(void);
int test_wc_Blake2s_other(void);
int test_wc_blake2s_decision_coverage(void);
#define TEST_BLAKE2B_DECLS \
TEST_DECL_GROUP("blake2b", test_wc_InitBlake2b), \
TEST_DECL_GROUP("blake2b", test_wc_InitBlake2b_WithKey), \
TEST_DECL_GROUP("blake2b", test_wc_Blake2bUpdate), \
TEST_DECL_GROUP("blake2b", test_wc_Blake2bFinal), \
TEST_DECL_GROUP("blake2b", test_wc_Blake2b_KATs), \
TEST_DECL_GROUP("blake2b", test_wc_Blake2b_other), \
TEST_DECL_GROUP("blake2b", test_wc_blake2b_decision_coverage)
#define TEST_BLAKE2S_DECLS \
TEST_DECL_GROUP("blake2s", test_wc_InitBlake2s), \
TEST_DECL_GROUP("blake2s", test_wc_InitBlake2s_WithKey), \
TEST_DECL_GROUP("blake2s", test_wc_Blake2sUpdate), \
TEST_DECL_GROUP("blake2s", test_wc_Blake2sFinal), \
TEST_DECL_GROUP("blake2s", test_wc_Blake2s_KATs), \
TEST_DECL_GROUP("blake2s", test_wc_Blake2s_other), \
TEST_DECL_GROUP("blake2s", test_wc_blake2s_decision_coverage)
#endif /* WOLFCRYPT_TEST_BLAKE2_H */