c_all.c revision 238405
11556Srgrimes/* crypto/evp/c_all.c */
21556Srgrimes/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
31556Srgrimes * All rights reserved.
41556Srgrimes *
51556Srgrimes * This package is an SSL implementation written
61556Srgrimes * by Eric Young (eay@cryptsoft.com).
71556Srgrimes * The implementation was written so as to conform with Netscapes SSL.
81556Srgrimes *
91556Srgrimes * This library is free for commercial and non-commercial use as long as
101556Srgrimes * the following conditions are aheared to.  The following conditions
111556Srgrimes * apply to all code found in this distribution, be it the RC4, RSA,
121556Srgrimes * lhash, DES, etc., code; not just the SSL code.  The SSL documentation
131556Srgrimes * included with this distribution is covered by the same copyright terms
141556Srgrimes * except that the holder is Tim Hudson (tjh@cryptsoft.com).
151556Srgrimes *
161556Srgrimes * Copyright remains Eric Young's, and as such any Copyright notices in
171556Srgrimes * the code are not to be removed.
181556Srgrimes * If this package is used in a product, Eric Young should be given attribution
191556Srgrimes * as the author of the parts of the library used.
201556Srgrimes * This can be in the form of a textual message at program startup or
211556Srgrimes * in documentation (online or textual) provided with the package.
221556Srgrimes *
231556Srgrimes * Redistribution and use in source and binary forms, with or without
241556Srgrimes * modification, are permitted provided that the following conditions
251556Srgrimes * are met:
261556Srgrimes * 1. Redistributions of source code must retain the copyright
271556Srgrimes *    notice, this list of conditions and the following disclaimer.
281556Srgrimes * 2. Redistributions in binary form must reproduce the above copyright
291556Srgrimes *    notice, this list of conditions and the following disclaimer in the
301556Srgrimes *    documentation and/or other materials provided with the distribution.
311556Srgrimes * 3. All advertising materials mentioning features or use of this software
321556Srgrimes *    must display the following acknowledgement:
331556Srgrimes *    "This product includes cryptographic software written by
341556Srgrimes *     Eric Young (eay@cryptsoft.com)"
351556Srgrimes *    The word 'cryptographic' can be left out if the rouines from the library
361556Srgrimes *    being used are not cryptographic related :-).
371556Srgrimes * 4. If you include any Windows specific code (or a derivative thereof) from
3836150Scharnier *    the apps directory (application code) you must include an acknowledgement:
3936150Scharnier *    "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
4036150Scharnier *
411556Srgrimes * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
4299110Sobrien * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
4399110Sobrien * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
441556Srgrimes * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
4517987Speter * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
4617987Speter * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
4717987Speter * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
4899762Stjr * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
4917987Speter * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
5017987Speter * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
5117987Speter * SUCH DAMAGE.
5217987Speter *
5317987Speter * The licence and distribution terms for any publically available version or
5417987Speter * derivative of this code cannot be changed.  i.e. this code cannot simply be
5569793Sobrien * copied and put under another distribution licence
5618018Speter * [including the GNU Public Licence.]
5717987Speter */
581556Srgrimes
591556Srgrimes#include <stdio.h>
6017987Speter#include "cryptlib.h"
611556Srgrimes#include <openssl/evp.h>
621556Srgrimes#ifndef OPENSSL_NO_ENGINE
6317987Speter#include <openssl/engine.h>
6417987Speter#endif
651556Srgrimes
661556Srgrimes#if 0
671556Srgrimes#undef OpenSSL_add_all_algorithms
681556Srgrimes
691556Srgrimesvoid OpenSSL_add_all_algorithms(void)
701556Srgrimes	{
711556Srgrimes	OPENSSL_add_all_algorithms_noconf();
721556Srgrimes	}
731556Srgrimes#endif
741556Srgrimes
751556Srgrimesvoid OPENSSL_add_all_algorithms_noconf(void)
761556Srgrimes	{
771556Srgrimes	/*
781556Srgrimes	 * For the moment OPENSSL_cpuid_setup does something
791556Srgrimes	 * only on IA-32, but we reserve the option for all
801556Srgrimes	 * platforms...
8128346Ssteve	 */
821556Srgrimes	OPENSSL_cpuid_setup();
8397659Stjr	OpenSSL_add_all_ciphers();
84100308Stjr	OpenSSL_add_all_digests();
851556Srgrimes#ifndef OPENSSL_NO_ENGINE
8638536Scracauer# if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV)
8738950Scracauer	ENGINE_setup_bsd_cryptodev();
8838536Scracauer# endif
8999762Stjr#endif
901556Srgrimes	}
9120425Ssteve