1193645Ssimon/* ==================================================================== 2193645Ssimon * Copyright (c) 2003 The OpenSSL Project. All rights reserved. 3193645Ssimon * 4193645Ssimon * Redistribution and use in source and binary forms, with or without 5193645Ssimon * modification, are permitted provided that the following conditions 6193645Ssimon * are met: 7193645Ssimon * 8193645Ssimon * 1. Redistributions of source code must retain the above copyright 9296465Sdelphij * notice, this list of conditions and the following disclaimer. 10193645Ssimon * 11193645Ssimon * 2. Redistributions in binary form must reproduce the above copyright 12193645Ssimon * notice, this list of conditions and the following disclaimer in 13193645Ssimon * the documentation and/or other materials provided with the 14193645Ssimon * distribution. 15193645Ssimon * 16193645Ssimon * 3. All advertising materials mentioning features or use of this 17193645Ssimon * software must display the following acknowledgment: 18193645Ssimon * "This product includes software developed by the OpenSSL Project 19193645Ssimon * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" 20193645Ssimon * 21193645Ssimon * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 22193645Ssimon * endorse or promote products derived from this software without 23193645Ssimon * prior written permission. For written permission, please contact 24193645Ssimon * openssl-core@openssl.org. 25193645Ssimon * 26193645Ssimon * 5. Products derived from this software may not be called "OpenSSL" 27193645Ssimon * nor may "OpenSSL" appear in their names without prior written 28193645Ssimon * permission of the OpenSSL Project. 29193645Ssimon * 30193645Ssimon * 6. Redistributions of any form whatsoever must retain the following 31193645Ssimon * acknowledgment: 32193645Ssimon * "This product includes software developed by the OpenSSL Project 33193645Ssimon * for use in the OpenSSL Toolkit (http://www.openssl.org/)" 34193645Ssimon * 35193645Ssimon * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 36193645Ssimon * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 37193645Ssimon * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 38193645Ssimon * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 39193645Ssimon * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 40193645Ssimon * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 41193645Ssimon * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 42193645Ssimon * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 43193645Ssimon * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 44193645Ssimon * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 45193645Ssimon * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 46193645Ssimon * OF THE POSSIBILITY OF SUCH DAMAGE. 47193645Ssimon * 48193645Ssimon */ 49193645Ssimon 50193645Ssimon#ifdef OPENSSL_FIPS 51193645Ssimon 52193645Ssimon#ifdef __cplusplus 53193645Ssimonextern "C" { 54193645Ssimon#endif 55193645Ssimon 56193645Ssimonvoid fips_w_lock(void); 57193645Ssimonvoid fips_w_unlock(void); 58193645Ssimonvoid fips_r_lock(void); 59193645Ssimonvoid fips_r_unlock(void); 60193645Ssimonint fips_is_started(void); 61193645Ssimonvoid fips_set_started(void); 62193645Ssimonint fips_is_owning_thread(void); 63193645Ssimonint fips_set_owning_thread(void); 64193645Ssimonvoid fips_set_selftest_fail(void); 65193645Ssimonint fips_clear_owning_thread(void); 66193645Ssimonunsigned char *fips_signature_witness(void); 67205128Ssimonint fips_check_rsa(RSA *rsa); 68193645Ssimon 69296465Sdelphij# define FIPS_MAX_CIPHER_TEST_SIZE 16 70193645Ssimon 71193645Ssimon#ifdef __cplusplus 72193645Ssimon} 73193645Ssimon#endif 74193645Ssimon#endif 75