summaryrefslogtreecommitdiff
path: root/src/lib/libssl/d1_lib.c
diff options
context:
space:
mode:
authorjsing <>2021-08-30 19:12:25 +0000
committerjsing <>2021-08-30 19:12:25 +0000
commitcedbde20c0ecfb870c00ce4fe4401f89a9397b6d (patch)
tree2d39ac8fc8532fdfcf26841981b52bd4c01b1e0f /src/lib/libssl/d1_lib.c
parentabf6f6607dda2d28fb254cd45e519fec1091fc0d (diff)
downloadopenbsd-cedbde20c0ecfb870c00ce4fe4401f89a9397b6d.tar.gz
openbsd-cedbde20c0ecfb870c00ce4fe4401f89a9397b6d.tar.bz2
openbsd-cedbde20c0ecfb870c00ce4fe4401f89a9397b6d.zip
Replace DTLS r_epoch with the read epoch from the TLSv1.2 record layer.
ok inoguchi@ tb@
Diffstat (limited to '')
-rw-r--r--src/lib/libssl/d1_lib.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/lib/libssl/d1_lib.c b/src/lib/libssl/d1_lib.c
index 3db5629e23..d4280a277c 100644
--- a/src/lib/libssl/d1_lib.c
+++ b/src/lib/libssl/d1_lib.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: d1_lib.c,v 1.58 2021/07/21 08:42:14 jsing Exp $ */ 1/* $OpenBSD: d1_lib.c,v 1.59 2021/08/30 19:12:25 jsing Exp $ */
2/* 2/*
3 * DTLS implementation written by Nagendra Modadugu 3 * DTLS implementation written by Nagendra Modadugu
4 * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. 4 * (nagendra@cs.stanford.edu) for the OpenSSL project 2005.
@@ -191,10 +191,8 @@ dtls1_clear(SSL *s)
191 memset(s->d1, 0, sizeof(*s->d1)); 191 memset(s->d1, 0, sizeof(*s->d1));
192 s->d1->internal = internal; 192 s->d1->internal = internal;
193 193
194 D1I(s)->r_epoch = 194 D1I(s)->unprocessed_rcds.epoch =
195 tls12_record_layer_initial_epoch(s->internal->rl); 195 tls12_record_layer_read_epoch(s->internal->rl) + 1;
196
197 D1I(s)->unprocessed_rcds.epoch = D1I(s)->r_epoch + 1;
198 196
199 if (s->server) { 197 if (s->server) {
200 D1I(s)->cookie_len = sizeof(D1I(s)->cookie); 198 D1I(s)->cookie_len = sizeof(D1I(s)->cookie);