diff options
author | jsing <> | 2022-01-11 19:03:15 +0000 |
---|---|---|
committer | jsing <> | 2022-01-11 19:03:15 +0000 |
commit | 29dd08f9d36c1e143430c23b6c134c873648b8f4 (patch) | |
tree | 41d4132a79c4a27fd233912019e3d7a523318b29 /src/lib/libssl/ssl_locl.h | |
parent | 1e518bcbf05a26f72d8671b296a6096f39cf402e (diff) | |
download | openbsd-29dd08f9d36c1e143430c23b6c134c873648b8f4.tar.gz openbsd-29dd08f9d36c1e143430c23b6c134c873648b8f4.tar.bz2 openbsd-29dd08f9d36c1e143430c23b6c134c873648b8f4.zip |
Remove peer_pkeys from SSL_SESSION.
peer_pkeys comes from some world where peers can send multiple certificates
- in fact, one of each known type. Since we do not live in such a world,
get rid of peer_pkeys and simply use peer_cert instead (in both TLSv1.2
and TLSv1.3, both clients and servers can only send a single leaf
(aka end-entity) certificate).
ok inoguchi@ tb@
Diffstat (limited to 'src/lib/libssl/ssl_locl.h')
-rw-r--r-- | src/lib/libssl/ssl_locl.h | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/lib/libssl/ssl_locl.h b/src/lib/libssl/ssl_locl.h index 36823d6462..546854b462 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.382 2022/01/11 18:39:28 jsing Exp $ */ | 1 | /* $OpenBSD: ssl_locl.h,v 1.383 2022/01/11 19:03:15 jsing 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 | * |
@@ -475,8 +475,9 @@ struct ssl_session_st { | |||
475 | unsigned int sid_ctx_length; | 475 | unsigned int sid_ctx_length; |
476 | unsigned char sid_ctx[SSL_MAX_SID_CTX_LENGTH]; | 476 | unsigned char sid_ctx[SSL_MAX_SID_CTX_LENGTH]; |
477 | 477 | ||
478 | /* This is the cert for the other end. */ | 478 | /* Peer provided leaf (end-entity) certificate. */ |
479 | X509 *peer_cert; | 479 | X509 *peer_cert; |
480 | int peer_cert_type; | ||
480 | 481 | ||
481 | /* when app_verify_callback accepts a session where the peer's certificate | 482 | /* when app_verify_callback accepts a session where the peer's certificate |
482 | * is not ok, we must remember the error for session reuse: */ | 483 | * is not ok, we must remember the error for session reuse: */ |
@@ -513,14 +514,6 @@ struct ssl_session_st { | |||
513 | 514 | ||
514 | STACK_OF(X509) *cert_chain; /* as received from peer */ | 515 | STACK_OF(X509) *cert_chain; /* as received from peer */ |
515 | 516 | ||
516 | /* The 'peer_...' members are used only by clients. */ | ||
517 | int peer_cert_type; | ||
518 | |||
519 | /* Obviously we don't have the private keys of these, | ||
520 | * so maybe we shouldn't even use the SSL_CERT_PKEY type here. */ | ||
521 | SSL_CERT_PKEY *peer_key; /* points to an element of peer_pkeys (never NULL!) */ | ||
522 | SSL_CERT_PKEY peer_pkeys[SSL_PKEY_NUM]; | ||
523 | |||
524 | size_t tlsext_ecpointformatlist_length; | 517 | size_t tlsext_ecpointformatlist_length; |
525 | uint8_t *tlsext_ecpointformatlist; /* peer's list */ | 518 | uint8_t *tlsext_ecpointformatlist; /* peer's list */ |
526 | size_t tlsext_supportedgroups_length; | 519 | size_t tlsext_supportedgroups_length; |