summaryrefslogtreecommitdiff
path: root/src/lib/libssl/ssl_locl.h
diff options
context:
space:
mode:
authorjsing <>2020-10-14 16:44:15 +0000
committerjsing <>2020-10-14 16:44:15 +0000
commitd01f579537c8999cab6b1bf97cfb2760827ceeae (patch)
tree48a3e74cff5229e78703d45e5305fd0d015a6e1f /src/lib/libssl/ssl_locl.h
parentb78b3da503cdbc1eab982be1760a8fc44c08c508 (diff)
downloadopenbsd-d01f579537c8999cab6b1bf97cfb2760827ceeae.tar.gz
openbsd-d01f579537c8999cab6b1bf97cfb2760827ceeae.tar.bz2
openbsd-d01f579537c8999cab6b1bf97cfb2760827ceeae.zip
Mark DTLS methods as DTLS.
Rather than inferring DTLS from the method version, add a field that marks a method as specifically being DTLS. Have SSL_IS_DTLS condition on this rather than on version. ok tb@
Diffstat (limited to 'src/lib/libssl/ssl_locl.h')
-rw-r--r--src/lib/libssl/ssl_locl.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/libssl/ssl_locl.h b/src/lib/libssl/ssl_locl.h
index f2e1cb97f8..12838bf294 100644
--- a/src/lib/libssl/ssl_locl.h
+++ b/src/lib/libssl/ssl_locl.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: ssl_locl.h,v 1.304 2020/10/11 12:45:52 guenther Exp $ */ 1/* $OpenBSD: ssl_locl.h,v 1.305 2020/10/14 16:44:15 jsing Exp $ */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
@@ -315,7 +315,7 @@ __BEGIN_HIDDEN_DECLS
315 315
316/* Check if an SSL structure is using DTLS. */ 316/* Check if an SSL structure is using DTLS. */
317#define SSL_IS_DTLS(s) \ 317#define SSL_IS_DTLS(s) \
318 (s->method->internal->version == DTLS1_VERSION) 318 (s->method->internal->dtls)
319 319
320/* See if we use signature algorithms extension. */ 320/* See if we use signature algorithms extension. */
321#define SSL_USE_SIGALGS(s) \ 321#define SSL_USE_SIGALGS(s) \
@@ -362,6 +362,7 @@ __BEGIN_HIDDEN_DECLS
362#define NAMED_CURVE_TYPE 3 362#define NAMED_CURVE_TYPE 3
363 363
364typedef struct ssl_method_internal_st { 364typedef struct ssl_method_internal_st {
365 int dtls;
365 int version; 366 int version;
366 367
367 uint16_t min_version; 368 uint16_t min_version;