From 8495b92047543113282c7304c2fcfb649c5f19d1 Mon Sep 17 00:00:00 2001 From: Theo Buehler Date: Sun, 23 Feb 2020 17:51:37 +0000 Subject: According to RFC 8446, Section 4.4.4, recipients of incorrect Finished messages must terminate the connection with a decrypt_error alert, so replace the use of the deprecated decryption_failed alert accordingly. ok beck inoguchi jsing --- lib/libssl/tls13_client.c | 4 ++-- lib/libssl/tls13_server.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/libssl') diff --git a/lib/libssl/tls13_client.c b/lib/libssl/tls13_client.c index e9eee19bff9..1c9debc4e5f 100644 --- a/lib/libssl/tls13_client.c +++ b/lib/libssl/tls13_client.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_client.c,v 1.44 2020/02/18 16:12:14 tb Exp $ */ +/* $OpenBSD: tls13_client.c,v 1.45 2020/02/23 17:51:36 tb Exp $ */ /* * Copyright (c) 2018, 2019 Joel Sing * @@ -868,7 +868,7 @@ tls13_server_finished_recv(struct tls13_ctx *ctx, CBS *cbs) goto err; if (!CBS_mem_equal(cbs, verify_data, verify_data_len)) { - ctx->alert = TLS1_AD_DECRYPTION_FAILED; + ctx->alert = TLS1_AD_DECRYPT_ERROR; goto err; } diff --git a/lib/libssl/tls13_server.c b/lib/libssl/tls13_server.c index bb06b0f3989..eb865bcfb1a 100644 --- a/lib/libssl/tls13_server.c +++ b/lib/libssl/tls13_server.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_server.c,v 1.25 2020/02/18 16:12:14 tb Exp $ */ +/* $OpenBSD: tls13_server.c,v 1.26 2020/02/23 17:51:36 tb Exp $ */ /* * Copyright (c) 2019, 2020 Joel Sing * Copyright (c) 2020 Bob Beck @@ -893,7 +893,7 @@ tls13_client_finished_recv(struct tls13_ctx *ctx, CBS *cbs) goto err; if (!CBS_mem_equal(cbs, verify_data, verify_data_len)) { - ctx->alert = TLS1_AD_DECRYPTION_FAILED; + ctx->alert = TLS1_AD_DECRYPT_ERROR; goto err; } -- cgit v1.2.3