diff options
author | jsing <> | 2015-02-11 07:01:10 +0000 |
---|---|---|
committer | jsing <> | 2015-02-11 07:01:10 +0000 |
commit | 53b67cf53ae755b09e315a3bd30e87b66c4ea769 (patch) | |
tree | c6f7f9e067233df00a99495d7e346482bb70b61e /src/lib/libtls/tls.h | |
parent | c6f3fe1fbc8da2fa6de30b10f1f219ab1f809438 (diff) | |
download | openbsd-53b67cf53ae755b09e315a3bd30e87b66c4ea769.tar.gz openbsd-53b67cf53ae755b09e315a3bd30e87b66c4ea769.tar.bz2 openbsd-53b67cf53ae755b09e315a3bd30e87b66c4ea769.zip |
Provide a tls_connect_servername() function that has the same behaviour
as tls_connect(), however allows the name to use for verification to be
explicitly provided, rather than being inferred from the host value.
Requested by reyk@
ok reyk@ tedu@
Diffstat (limited to 'src/lib/libtls/tls.h')
-rw-r--r-- | src/lib/libtls/tls.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/libtls/tls.h b/src/lib/libtls/tls.h index c266832c80..0a6f8d7258 100644 --- a/src/lib/libtls/tls.h +++ b/src/lib/libtls/tls.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: tls.h,v 1.6 2015/02/11 06:46:33 jsing Exp $ */ | 1 | /* $OpenBSD: tls.h,v 1.7 2015/02/11 07:01:10 jsing Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2014 Joel Sing <jsing@openbsd.org> |
4 | * | 4 | * |
@@ -71,6 +71,8 @@ int tls_accept_socket(struct tls *ctx, struct tls **cctx, int socket); | |||
71 | int tls_connect(struct tls *ctx, const char *host, const char *port); | 71 | int tls_connect(struct tls *ctx, const char *host, const char *port); |
72 | int tls_connect_fds(struct tls *ctx, int fd_read, int fd_write, | 72 | int tls_connect_fds(struct tls *ctx, int fd_read, int fd_write, |
73 | const char *servername); | 73 | const char *servername); |
74 | int tls_connect_servername(struct tls *ctx, const char *host, const char *port, | ||
75 | const char *servername); | ||
74 | int tls_connect_socket(struct tls *ctx, int s, const char *servername); | 76 | int tls_connect_socket(struct tls *ctx, int s, const char *servername); |
75 | int tls_read(struct tls *ctx, void *buf, size_t buflen, size_t *outlen); | 77 | int tls_read(struct tls *ctx, void *buf, size_t buflen, size_t *outlen); |
76 | int tls_write(struct tls *ctx, const void *buf, size_t buflen, size_t *outlen); | 78 | int tls_write(struct tls *ctx, const void *buf, size_t buflen, size_t *outlen); |