summaryrefslogtreecommitdiff
path: root/src/lib/libtls/tls_internal.h
diff options
context:
space:
mode:
authorjsing <>2017-01-26 12:56:37 +0000
committerjsing <>2017-01-26 12:56:37 +0000
commitfaeda34edddb798c605b02be985707c383fc2619 (patch)
treeb6f097154c11d0ef88cefdbed8094e57584a2602 /src/lib/libtls/tls_internal.h
parent5f4d6ed4e05cb127aa9702893fbc6baf9ee43f35 (diff)
downloadopenbsd-faeda34edddb798c605b02be985707c383fc2619.tar.gz
openbsd-faeda34edddb798c605b02be985707c383fc2619.tar.bz2
openbsd-faeda34edddb798c605b02be985707c383fc2619.zip
Use a flag to track when we need to call SSL_shutdown(). This avoids an
issue where by calling tls_close() on a TLS context that has not attempted a handshake, results in an unexpected failure. Reported by Vinay Sajip. ok beck@
Diffstat (limited to 'src/lib/libtls/tls_internal.h')
-rw-r--r--src/lib/libtls/tls_internal.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/libtls/tls_internal.h b/src/lib/libtls/tls_internal.h
index 3650ca9462..37737c3499 100644
--- a/src/lib/libtls/tls_internal.h
+++ b/src/lib/libtls/tls_internal.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: tls_internal.h,v 1.51 2017/01/24 01:48:05 claudio Exp $ */ 1/* $OpenBSD: tls_internal.h,v 1.52 2017/01/26 12:56:37 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>
@@ -118,6 +118,7 @@ struct tls_conninfo {
118 118
119#define TLS_EOF_NO_CLOSE_NOTIFY (1 << 0) 119#define TLS_EOF_NO_CLOSE_NOTIFY (1 << 0)
120#define TLS_HANDSHAKE_COMPLETE (1 << 1) 120#define TLS_HANDSHAKE_COMPLETE (1 << 1)
121#define TLS_SSL_NEEDS_SHUTDOWN (1 << 2)
121 122
122struct tls_ocsp_result { 123struct tls_ocsp_result {
123 const char *result_msg; 124 const char *result_msg;