From 1e6510105e17f4686509b6cef5e4a607664dd5c0 Mon Sep 17 00:00:00 2001 From: tb <> Date: Tue, 1 Sep 2020 12:40:53 +0000 Subject: copy session id directly in ssl_get_prev_session ssl_get_prev_session() hands the session id down to tls_decrypt_ticket() which then copies it into the session pointer that it is about to return. It's a lot simpler to retrieve the session pointer and copy the session id inside ssl_get_prev_session(). Also, 'goto err' directly in TLS1_TICKET_NOT_DECRYPTED instead of skipping a couple of long if clauses before doing so. ok inoguchi jsing --- src/lib/libssl/ssl_locl.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/lib/libssl/ssl_locl.h') diff --git a/src/lib/libssl/ssl_locl.h b/src/lib/libssl/ssl_locl.h index 2f8ba1fc09..bd210cdce5 100644 --- a/src/lib/libssl/ssl_locl.h +++ b/src/lib/libssl/ssl_locl.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl_locl.h,v 1.287 2020/09/01 05:32:11 tb Exp $ */ +/* $OpenBSD: ssl_locl.h,v 1.288 2020/09/01 12:40:53 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -1403,8 +1403,7 @@ int ssl_check_serverhello_tlsext(SSL *s); #define TLS1_TICKET_NOT_DECRYPTED 2 #define TLS1_TICKET_DECRYPTED 3 -int tls1_process_ticket(SSL *s, CBS *session_id, CBS *ext_block, - int *alert, SSL_SESSION **ret); +int tls1_process_ticket(SSL *s, CBS *ext_block, int *alert, SSL_SESSION **ret); long ssl_get_algorithm2(SSL *s); -- cgit v1.2.3-55-g6feb