summaryrefslogtreecommitdiff
path: root/src/lib/libssl/ssl_locl.h
diff options
context:
space:
mode:
authorjsing <>2021-01-19 18:57:09 +0000
committerjsing <>2021-01-19 18:57:09 +0000
commiteb720c630d40660f4bf00d58faa6f6d59ba82ea2 (patch)
tree1cc6adc2f532c5f987be2b9a01b957de5960ebfa /src/lib/libssl/ssl_locl.h
parentac4995fa26f1a8ba3ff386c0caf843a423a4abc7 (diff)
downloadopenbsd-eb720c630d40660f4bf00d58faa6f6d59ba82ea2.tar.gz
openbsd-eb720c630d40660f4bf00d58faa6f6d59ba82ea2.tar.bz2
openbsd-eb720c630d40660f4bf00d58faa6f6d59ba82ea2.zip
Provide functions to determine if TLSv1.2 record protection is engaged.
Call these functions from code that needs to know if we've changed cipher state and enabled record protection, rather than inconsistently checking various pointers from other places in the code base. This also fixes a minor bug where the wrong pointers are checked if we're operating with AEAD. ok inoguchi@ tb@
Diffstat (limited to 'src/lib/libssl/ssl_locl.h')
-rw-r--r--src/lib/libssl/ssl_locl.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/libssl/ssl_locl.h b/src/lib/libssl/ssl_locl.h
index e09f668121..e0a4c49ccb 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.313 2021/01/19 18:51:08 jsing Exp $ */ 1/* $OpenBSD: ssl_locl.h,v 1.314 2021/01/19 18:57:09 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 *
@@ -479,6 +479,8 @@ void tls12_record_layer_alert(struct tls12_record_layer *rl,
479 uint8_t *alert_desc); 479 uint8_t *alert_desc);
480int tls12_record_layer_write_overhead(struct tls12_record_layer *rl, 480int tls12_record_layer_write_overhead(struct tls12_record_layer *rl,
481 size_t *overhead); 481 size_t *overhead);
482int tls12_record_layer_read_protected(struct tls12_record_layer *rl);
483int tls12_record_layer_write_protected(struct tls12_record_layer *rl);
482void tls12_record_layer_set_version(struct tls12_record_layer *rl, 484void tls12_record_layer_set_version(struct tls12_record_layer *rl,
483 uint16_t version); 485 uint16_t version);
484void tls12_record_layer_set_write_epoch(struct tls12_record_layer *rl, 486void tls12_record_layer_set_write_epoch(struct tls12_record_layer *rl,