1 |
/* |
2 |
* ircd-hybrid: an advanced, lightweight Internet Relay Chat Daemon (ircd) |
3 |
* |
4 |
* Copyright (c) 2015 Attila Molnar <attilamolnar@hush.com> |
5 |
* Copyright (c) 2015 Adam <Adam@anope.org> |
6 |
* Copyright (c) 2015-2017 ircd-hybrid development team |
7 |
* |
8 |
* This program is free software; you can redistribute it and/or modify |
9 |
* it under the terms of the GNU General Public License as published by |
10 |
* the Free Software Foundation; either version 2 of the License, or |
11 |
* (at your option) any later version. |
12 |
* |
13 |
* This program is distributed in the hope that it will be useful, |
14 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
15 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16 |
* GNU General Public License for more details. |
17 |
* |
18 |
* You should have received a copy of the GNU General Public License |
19 |
* along with this program; if not, write to the Free Software |
20 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 |
21 |
* USA |
22 |
*/ |
23 |
|
24 |
/*! \file tls_openssl.h |
25 |
* \brief OpenSSL-specific TLS types |
26 |
* \version $Id$ |
27 |
*/ |
28 |
|
29 |
|
30 |
#ifndef INCLUDED_tls_openssl_h |
31 |
#define INCLUDED_tls_openssl_h |
32 |
|
33 |
#ifdef HAVE_LIBCRYPTO |
34 |
|
35 |
#define HAVE_TLS |
36 |
#define HAVE_TLS_OPENSSL |
37 |
|
38 |
#include <openssl/ssl.h> |
39 |
#include <openssl/err.h> |
40 |
|
41 |
typedef SSL * tls_data_t; |
42 |
typedef const EVP_MD * tls_md_t; |
43 |
|
44 |
typedef struct |
45 |
{ |
46 |
SSL_CTX *server_ctx; |
47 |
SSL_CTX *client_ctx; |
48 |
} tls_context_t; |
49 |
|
50 |
#endif /* HAVE_LIBCRYPTO */ |
51 |
#endif /* INCLUDED_tls_openssl_h */ |