summaryrefslogtreecommitdiff
path: root/src/lib/libssl/ssl_locl.h
diff options
context:
space:
mode:
authortb <>2020-08-31 14:04:51 +0000
committertb <>2020-08-31 14:04:51 +0000
commitf551307b25934acd84205155d6286b2d937e2479 (patch)
tree724850986fbe9b93cfd38e922f1d17205d123b6b /src/lib/libssl/ssl_locl.h
parent09997f3d41692022beb138f1e238f51af93a8024 (diff)
downloadopenbsd-f551307b25934acd84205155d6286b2d937e2479.tar.gz
openbsd-f551307b25934acd84205155d6286b2d937e2479.tar.bz2
openbsd-f551307b25934acd84205155d6286b2d937e2479.zip
Send alert on ssl_get_prev_session failure
ssl_get_prev_session() can fail for various reasons some of which may be internal_error others decode_error alerts. Propagate the appropriate alert up to the caller so we can abort the handshake by sending a fatal alert instead of rudely closing the pipe. Currently only 28 of 292 test cases of tlsfuzzer's test-extension.py pass. With this diff, 272 pass. The rest will require fixes elsewhere. ok beck inoguchi jsing
Diffstat (limited to 'src/lib/libssl/ssl_locl.h')
-rw-r--r--src/lib/libssl/ssl_locl.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/libssl/ssl_locl.h b/src/lib/libssl/ssl_locl.h
index e41465419a..036c1dacb2 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.284 2020/08/30 15:40:20 jsing Exp $ */ 1/* $OpenBSD: ssl_locl.h,v 1.285 2020/08/31 14:04:51 tb 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 *
@@ -1161,7 +1161,8 @@ int ssl_cert_add1_chain_cert(CERT *c, X509 *cert);
1161SESS_CERT *ssl_sess_cert_new(void); 1161SESS_CERT *ssl_sess_cert_new(void);
1162void ssl_sess_cert_free(SESS_CERT *sc); 1162void ssl_sess_cert_free(SESS_CERT *sc);
1163int ssl_get_new_session(SSL *s, int session); 1163int ssl_get_new_session(SSL *s, int session);
1164int ssl_get_prev_session(SSL *s, CBS *session_id, CBS *ext_block); 1164int ssl_get_prev_session(SSL *s, CBS *session_id, CBS *ext_block,
1165 int *alert);
1165int ssl_cipher_id_cmp(const SSL_CIPHER *a, const SSL_CIPHER *b); 1166int ssl_cipher_id_cmp(const SSL_CIPHER *a, const SSL_CIPHER *b);
1166SSL_CIPHER *OBJ_bsearch_ssl_cipher_id(SSL_CIPHER *key, SSL_CIPHER const *base, 1167SSL_CIPHER *OBJ_bsearch_ssl_cipher_id(SSL_CIPHER *key, SSL_CIPHER const *base,
1167 int num); 1168 int num);
@@ -1397,7 +1398,7 @@ int ssl_check_clienthello_tlsext_late(SSL *s);
1397int ssl_check_serverhello_tlsext(SSL *s); 1398int ssl_check_serverhello_tlsext(SSL *s);
1398 1399
1399int tls1_process_ticket(SSL *s, CBS *session_id, CBS *ext_block, 1400int tls1_process_ticket(SSL *s, CBS *session_id, CBS *ext_block,
1400 SSL_SESSION **ret); 1401 int *alert, SSL_SESSION **ret);
1401 1402
1402long ssl_get_algorithm2(SSL *s); 1403long ssl_get_algorithm2(SSL *s);
1403 1404