summaryrefslogtreecommitdiff
path: root/lib/ssl/src/tls_handshake_1_3.erl
diff options
context:
space:
mode:
authorIngela Anderton Andin <ingela@erlang.org>2022-02-25 09:22:23 +0100
committerIngela Anderton Andin <ingela@erlang.org>2022-02-28 09:51:23 +0100
commit15023dc182b84b966abb7fec55612adf3263970d (patch)
tree01f123162087cca247cf3e2d318b5b426d893bb6 /lib/ssl/src/tls_handshake_1_3.erl
parentcf698cd8ede551670bd8bb8b231bed67a0f5aa3b (diff)
downloaderlang-15023dc182b84b966abb7fec55612adf3263970d.tar.gz
ssl: Enhance internal configuration handling
When a client has not provided certs or configurations using anonymous cipher suites are enabled use an empty list and empty map to indicate the undefined certificate key pair, so that values are true to the type spec.
Diffstat (limited to 'lib/ssl/src/tls_handshake_1_3.erl')
-rw-r--r--lib/ssl/src/tls_handshake_1_3.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ssl/src/tls_handshake_1_3.erl b/lib/ssl/src/tls_handshake_1_3.erl
index 87104d1df4..755f9e407f 100644
--- a/lib/ssl/src/tls_handshake_1_3.erl
+++ b/lib/ssl/src/tls_handshake_1_3.erl
@@ -2995,7 +2995,7 @@ select_server_cert_key_pair(Session, [#{private_key := Key, certs := [Cert| _] =
end.
select_client_cert_key_pair(Session0,
- [#{private_key := undefined = NoKey, certs := undefined = NoCerts}],
+ [#{private_key := NoKey, certs := [[]] = NoCerts}],
_,_,_,_,_,_) ->
%% No certificate supplied : send empty certificate
Session0#session{own_certificates = NoCerts,