xref: /minix3/crypto/external/bsd/openssl/dist/ssl/ssl_utst.c (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1*0a6a1f1dSLionel Sambuc /* ssl_utst.c */
2*0a6a1f1dSLionel Sambuc /*
3*0a6a1f1dSLionel Sambuc  * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
4*0a6a1f1dSLionel Sambuc  * project.
5*0a6a1f1dSLionel Sambuc  */
6*0a6a1f1dSLionel Sambuc /* ====================================================================
7*0a6a1f1dSLionel Sambuc  * Copyright (c) 2014 The OpenSSL Project.  All rights reserved.
8*0a6a1f1dSLionel Sambuc  *
9*0a6a1f1dSLionel Sambuc  * Redistribution and use in source and binary forms, with or without
10*0a6a1f1dSLionel Sambuc  * modification, are permitted provided that the following conditions
11*0a6a1f1dSLionel Sambuc  * are met:
12*0a6a1f1dSLionel Sambuc  *
13*0a6a1f1dSLionel Sambuc  * 1. Redistributions of source code must retain the above copyright
14*0a6a1f1dSLionel Sambuc  *    notice, this list of conditions and the following disclaimer.
15*0a6a1f1dSLionel Sambuc  *
16*0a6a1f1dSLionel Sambuc  * 2. Redistributions in binary form must reproduce the above copyright
17*0a6a1f1dSLionel Sambuc  *    notice, this list of conditions and the following disclaimer in
18*0a6a1f1dSLionel Sambuc  *    the documentation and/or other materials provided with the
19*0a6a1f1dSLionel Sambuc  *    distribution.
20*0a6a1f1dSLionel Sambuc  *
21*0a6a1f1dSLionel Sambuc  * 3. All advertising materials mentioning features or use of this
22*0a6a1f1dSLionel Sambuc  *    software must display the following acknowledgment:
23*0a6a1f1dSLionel Sambuc  *    "This product includes software developed by the OpenSSL Project
24*0a6a1f1dSLionel Sambuc  *    for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
25*0a6a1f1dSLionel Sambuc  *
26*0a6a1f1dSLionel Sambuc  * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
27*0a6a1f1dSLionel Sambuc  *    endorse or promote products derived from this software without
28*0a6a1f1dSLionel Sambuc  *    prior written permission. For written permission, please contact
29*0a6a1f1dSLionel Sambuc  *    openssl-core@openssl.org.
30*0a6a1f1dSLionel Sambuc  *
31*0a6a1f1dSLionel Sambuc  * 5. Products derived from this software may not be called "OpenSSL"
32*0a6a1f1dSLionel Sambuc  *    nor may "OpenSSL" appear in their names without prior written
33*0a6a1f1dSLionel Sambuc  *    permission of the OpenSSL Project.
34*0a6a1f1dSLionel Sambuc  *
35*0a6a1f1dSLionel Sambuc  * 6. Redistributions of any form whatsoever must retain the following
36*0a6a1f1dSLionel Sambuc  *    acknowledgment:
37*0a6a1f1dSLionel Sambuc  *    "This product includes software developed by the OpenSSL Project
38*0a6a1f1dSLionel Sambuc  *    for use in the OpenSSL Toolkit (http://www.openssl.org/)"
39*0a6a1f1dSLionel Sambuc  *
40*0a6a1f1dSLionel Sambuc  * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
41*0a6a1f1dSLionel Sambuc  * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
42*0a6a1f1dSLionel Sambuc  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
43*0a6a1f1dSLionel Sambuc  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE OpenSSL PROJECT OR
44*0a6a1f1dSLionel Sambuc  * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
45*0a6a1f1dSLionel Sambuc  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
46*0a6a1f1dSLionel Sambuc  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
47*0a6a1f1dSLionel Sambuc  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
48*0a6a1f1dSLionel Sambuc  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
49*0a6a1f1dSLionel Sambuc  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
50*0a6a1f1dSLionel Sambuc  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
51*0a6a1f1dSLionel Sambuc  * OF THE POSSIBILITY OF SUCH DAMAGE.
52*0a6a1f1dSLionel Sambuc  * ====================================================================
53*0a6a1f1dSLionel Sambuc  *
54*0a6a1f1dSLionel Sambuc  */
55*0a6a1f1dSLionel Sambuc 
56*0a6a1f1dSLionel Sambuc #include "ssl_locl.h"
57*0a6a1f1dSLionel Sambuc 
58*0a6a1f1dSLionel Sambuc #ifndef OPENSSL_NO_UNIT_TEST
59*0a6a1f1dSLionel Sambuc 
60*0a6a1f1dSLionel Sambuc static const struct openssl_ssl_test_functions ssl_test_functions = {
61*0a6a1f1dSLionel Sambuc     ssl_init_wbio_buffer,
62*0a6a1f1dSLionel Sambuc     ssl3_setup_buffers,
63*0a6a1f1dSLionel Sambuc     tls1_process_heartbeat,
64*0a6a1f1dSLionel Sambuc     dtls1_process_heartbeat
65*0a6a1f1dSLionel Sambuc };
66*0a6a1f1dSLionel Sambuc 
SSL_test_functions(void)67*0a6a1f1dSLionel Sambuc const struct openssl_ssl_test_functions *SSL_test_functions(void)
68*0a6a1f1dSLionel Sambuc {
69*0a6a1f1dSLionel Sambuc     return &ssl_test_functions;
70*0a6a1f1dSLionel Sambuc }
71*0a6a1f1dSLionel Sambuc 
72*0a6a1f1dSLionel Sambuc #endif
73