summaryrefslogtreecommitdiff
path: root/src/lib/libtls/tls_internal.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/lib/libtls/tls_internal.h (renamed from src/lib/libressl/ressl_internal.h)36
1 files changed, 18 insertions, 18 deletions
diff --git a/src/lib/libressl/ressl_internal.h b/src/lib/libtls/tls_internal.h
index b752b5fd88..da696e228d 100644
--- a/src/lib/libressl/ressl_internal.h
+++ b/src/lib/libtls/tls_internal.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: ressl_internal.h,v 1.12 2014/10/03 14:14:40 tedu Exp $ */ 1/* $OpenBSD: tls_internal.h,v 1.1 2014/10/31 13:46:17 jsing Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Jeremie Courreges-Anglas <jca@openbsd.org> 3 * Copyright (c) 2014 Jeremie Courreges-Anglas <jca@openbsd.org>
4 * Copyright (c) 2014 Joel Sing <jsing@openbsd.org> 4 * Copyright (c) 2014 Joel Sing <jsing@openbsd.org>
@@ -16,8 +16,8 @@
16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 */ 17 */
18 18
19#ifndef HEADER_RESSL_INTERNAL_H 19#ifndef HEADER_TLS_INTERNAL_H
20#define HEADER_RESSL_INTERNAL_H 20#define HEADER_TLS_INTERNAL_H
21 21
22#include <openssl/ssl.h> 22#include <openssl/ssl.h>
23 23
@@ -25,7 +25,7 @@
25 25
26#define _PATH_SSL_CA_FILE "/etc/ssl/cert.pem" 26#define _PATH_SSL_CA_FILE "/etc/ssl/cert.pem"
27 27
28struct ressl_config { 28struct tls_config {
29 const char *ca_file; 29 const char *ca_file;
30 const char *ca_path; 30 const char *ca_path;
31 const char *cert_file; 31 const char *cert_file;
@@ -42,12 +42,12 @@ struct ressl_config {
42 int verify_depth; 42 int verify_depth;
43}; 43};
44 44
45#define RESSL_CLIENT (1 << 0) 45#define TLS_CLIENT (1 << 0)
46#define RESSL_SERVER (1 << 1) 46#define TLS_SERVER (1 << 1)
47#define RESSL_SERVER_CONN (1 << 2) 47#define TLS_SERVER_CONN (1 << 2)
48 48
49struct ressl { 49struct tls {
50 struct ressl_config *config; 50 struct tls_config *config;
51 uint64_t flags; 51 uint64_t flags;
52 52
53 int err; 53 int err;
@@ -59,14 +59,14 @@ struct ressl {
59 SSL_CTX *ssl_ctx; 59 SSL_CTX *ssl_ctx;
60}; 60};
61 61
62struct ressl *ressl_new(void); 62struct tls *tls_new(void);
63struct ressl *ressl_server_conn(struct ressl *ctx); 63struct tls *tls_server_conn(struct tls *ctx);
64 64
65int ressl_check_hostname(X509 *cert, const char *host); 65int tls_check_hostname(X509 *cert, const char *host);
66int ressl_configure_keypair(struct ressl *ctx); 66int tls_configure_keypair(struct tls *ctx);
67int ressl_configure_server(struct ressl *ctx); 67int tls_configure_server(struct tls *ctx);
68int ressl_configure_ssl(struct ressl *ctx); 68int tls_configure_ssl(struct tls *ctx);
69int ressl_host_port(const char *hostport, char **host, char **port); 69int tls_host_port(const char *hostport, char **host, char **port);
70int ressl_set_error(struct ressl *ctx, char *fmt, ...); 70int tls_set_error(struct tls *ctx, char *fmt, ...);
71 71
72#endif /* HEADER_RESSL_INTERNAL_H */ 72#endif /* HEADER_TLS_INTERNAL_H */