summaryrefslogtreecommitdiff
path: root/src/lib/libssl/tls13_server.c
diff options
context:
space:
mode:
authorbeck <>2020-05-22 02:37:27 +0000
committerbeck <>2020-05-22 02:37:27 +0000
commitcfa7c7d8ea22f50276f89f901780ab7885f495a4 (patch)
treeb00c1435c9fdf8150e39580ad61b4a3ad4eca9ba /src/lib/libssl/tls13_server.c
parent919686e3aeba6fcad99207e3e25b401b339f721c (diff)
downloadopenbsd-cfa7c7d8ea22f50276f89f901780ab7885f495a4.tar.gz
openbsd-cfa7c7d8ea22f50276f89f901780ab7885f495a4.tar.bz2
openbsd-cfa7c7d8ea22f50276f89f901780ab7885f495a4.zip
Ensure we only attach an ocsp staple to a leaf certificate, because
for the moment that is all we support. fixes an issue where gnuTLS cares that mistmatching staples come back on the certs in the chain. This should be fixed correctly later by associating the staple to the individual certs rather than the ssl, so this is temporary. running on www@. ok tb@, "got that's oopy but an interim ok" jsing@
Diffstat (limited to 'src/lib/libssl/tls13_server.c')
-rw-r--r--src/lib/libssl/tls13_server.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/lib/libssl/tls13_server.c b/src/lib/libssl/tls13_server.c
index 42409edbf7..e0ea6b564d 100644
--- a/src/lib/libssl/tls13_server.c
+++ b/src/lib/libssl/tls13_server.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: tls13_server.c,v 1.50 2020/05/21 18:34:34 jsing Exp $ */ 1/* $OpenBSD: tls13_server.c,v 1.51 2020/05/22 02:37:27 beck Exp $ */
2/* 2/*
3 * Copyright (c) 2019, 2020 Joel Sing <jsing@openbsd.org> 3 * Copyright (c) 2019, 2020 Joel Sing <jsing@openbsd.org>
4 * Copyright (c) 2020 Bob Beck <beck@openbsd.org> 4 * Copyright (c) 2020 Bob Beck <beck@openbsd.org>
@@ -461,7 +461,12 @@ tls13_server_certificate_send(struct tls13_ctx *ctx, CBB *cbb)
461 461
462 for (i = 0; i < sk_X509_num(chain); i++) { 462 for (i = 0; i < sk_X509_num(chain); i++) {
463 cert = sk_X509_value(chain, i); 463 cert = sk_X509_value(chain, i);
464 if (!tls13_cert_add(ctx, &cert_list, cert, tlsext_server_build)) 464 /*
465 * XXX we don't send extensions with chain certs to avoid sending
466 * a leaf ocsp stape with the chain certs. This needs to get
467 * fixed
468 */
469 if (!tls13_cert_add(ctx, &cert_list, cert, NULL))
465 goto err; 470 goto err;
466 } 471 }
467 472