1*b077aed3SPierre Pronchery /* 2*b077aed3SPierre Pronchery * Copyright 2019-2020 The OpenSSL Project Authors. All Rights Reserved. 3*b077aed3SPierre Pronchery * 4*b077aed3SPierre Pronchery * Licensed under the Apache License 2.0 (the "License"). You may not use 5*b077aed3SPierre Pronchery * this file except in compliance with the License. You can obtain a copy 6*b077aed3SPierre Pronchery * in the file LICENSE in the source distribution or at 7*b077aed3SPierre Pronchery * https://www.openssl.org/source/license.html 8*b077aed3SPierre Pronchery */ 9*b077aed3SPierre Pronchery 10*b077aed3SPierre Pronchery #include <openssl/core_dispatch.h> 11*b077aed3SPierre Pronchery #include <openssl/types.h> 12*b077aed3SPierre Pronchery #include <openssl/self_test.h> 13*b077aed3SPierre Pronchery 14*b077aed3SPierre Pronchery typedef struct self_test_post_params_st { 15*b077aed3SPierre Pronchery /* FIPS module integrity check parameters */ 16*b077aed3SPierre Pronchery const char *module_filename; /* Module file to perform MAC on */ 17*b077aed3SPierre Pronchery const char *module_checksum_data; /* Expected module MAC integrity */ 18*b077aed3SPierre Pronchery 19*b077aed3SPierre Pronchery /* Used for KAT install indicator integrity check */ 20*b077aed3SPierre Pronchery const char *indicator_version; /* version - for future proofing */ 21*b077aed3SPierre Pronchery const char *indicator_data; /* data to perform MAC on */ 22*b077aed3SPierre Pronchery const char *indicator_checksum_data; /* Expected MAC integrity value */ 23*b077aed3SPierre Pronchery 24*b077aed3SPierre Pronchery /* Used for continuous tests */ 25*b077aed3SPierre Pronchery const char *conditional_error_check; 26*b077aed3SPierre Pronchery 27*b077aed3SPierre Pronchery /* BIO callbacks supplied to the FIPS provider */ 28*b077aed3SPierre Pronchery OSSL_FUNC_BIO_new_file_fn *bio_new_file_cb; 29*b077aed3SPierre Pronchery OSSL_FUNC_BIO_new_membuf_fn *bio_new_buffer_cb; 30*b077aed3SPierre Pronchery OSSL_FUNC_BIO_read_ex_fn *bio_read_ex_cb; 31*b077aed3SPierre Pronchery OSSL_FUNC_BIO_free_fn *bio_free_cb; 32*b077aed3SPierre Pronchery OSSL_CALLBACK *cb; 33*b077aed3SPierre Pronchery void *cb_arg; 34*b077aed3SPierre Pronchery OSSL_LIB_CTX *libctx; 35*b077aed3SPierre Pronchery 36*b077aed3SPierre Pronchery } SELF_TEST_POST_PARAMS; 37*b077aed3SPierre Pronchery 38*b077aed3SPierre Pronchery int SELF_TEST_post(SELF_TEST_POST_PARAMS *st, int on_demand_test); 39*b077aed3SPierre Pronchery int SELF_TEST_kats(OSSL_SELF_TEST *event, OSSL_LIB_CTX *libctx); 40*b077aed3SPierre Pronchery 41*b077aed3SPierre Pronchery void SELF_TEST_disable_conditional_error_state(void); 42