o_init.c (194206) | o_init.c (205128) |
---|---|
1/* o_init.c */ 2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 3 * project. 4 */ 5/* ==================================================================== 6 * Copyright (c) 2007 The OpenSSL Project. All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 44 unchanged lines hidden (view full) --- 53 * This product includes cryptographic software written by Eric Young 54 * (eay@cryptsoft.com). This product includes software written by Tim 55 * Hudson (tjh@cryptsoft.com). 56 * 57 */ 58 59#include <e_os.h> 60#include <openssl/err.h> | 1/* o_init.c */ 2/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 3 * project. 4 */ 5/* ==================================================================== 6 * Copyright (c) 2007 The OpenSSL Project. All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 44 unchanged lines hidden (view full) --- 53 * This product includes cryptographic software written by Eric Young 54 * (eay@cryptsoft.com). This product includes software written by Tim 55 * Hudson (tjh@cryptsoft.com). 56 * 57 */ 58 59#include <e_os.h> 60#include <openssl/err.h> |
61/* Internal only functions: only ever used here */ 62extern void int_ERR_lib_init(void); 63extern void int_EVP_MD_init_engine_callbacks(void ); 64extern void int_EVP_CIPHER_init_engine_callbacks(void ); 65extern void int_RAND_init_engine_callbacks(void ); |
|
61 62/* Perform any essential OpenSSL initialization operations. 63 * Currently only sets FIPS callbacks 64 */ 65 66void OPENSSL_init(void) 67 { 68#ifdef OPENSSL_FIPS 69 static int done = 0; 70 if (!done) 71 { 72 int_ERR_lib_init(); 73#ifdef CRYPTO_MDEBUG 74 CRYPTO_malloc_debug_init(); 75#endif | 66 67/* Perform any essential OpenSSL initialization operations. 68 * Currently only sets FIPS callbacks 69 */ 70 71void OPENSSL_init(void) 72 { 73#ifdef OPENSSL_FIPS 74 static int done = 0; 75 if (!done) 76 { 77 int_ERR_lib_init(); 78#ifdef CRYPTO_MDEBUG 79 CRYPTO_malloc_debug_init(); 80#endif |
76#ifdef OPENSSL_ENGINE | 81#ifndef OPENSSL_NO_ENGINE |
77 int_EVP_MD_init_engine_callbacks(); 78 int_EVP_CIPHER_init_engine_callbacks(); 79 int_RAND_init_engine_callbacks(); 80#endif 81 done = 1; 82 } 83#endif 84 } 85 86 | 82 int_EVP_MD_init_engine_callbacks(); 83 int_EVP_CIPHER_init_engine_callbacks(); 84 int_RAND_init_engine_callbacks(); 85#endif 86 done = 1; 87 } 88#endif 89 } 90 91 |