diff options
author | Ingela Anderton Andin <[email protected]> | 2016-06-15 09:09:32 +0200 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2016-06-15 09:09:32 +0200 |
commit | 9a9c5d9ba7ebcbf254c848c006f4681828ea1dce (patch) | |
tree | fcd790942c32a23fca53ccc0ab4b7163bb0d3712 /lib/ssl/src/ssl_handshake.erl | |
parent | eb83cd576340259c1ed1b4a7b02caa7195d2d6d0 (diff) | |
parent | 49b815f872d7e7ea38260ee5bd8bf470fa42c03a (diff) | |
download | otp-9a9c5d9ba7ebcbf254c848c006f4681828ea1dce.tar.gz otp-9a9c5d9ba7ebcbf254c848c006f4681828ea1dce.tar.bz2 otp-9a9c5d9ba7ebcbf254c848c006f4681828ea1dce.zip |
Merge branch 'ingela/ssl/dtls-next-step-flights/OTP-13678'
* ingela/ssl/dtls-next-step-flights/OTP-13678:
dtls: Avoid dialyzer errors
dtls: add implementation for msg sequence
dtls: Remove TODO
dtls: sync dtls_record DTLS version and crypto handling with TLS
dtls: handle Hello and HelloVerify's in dtls_handshake
dtls: rework/simplify DTLS fragment decoder
dtls: add support first packet and HelloVerifyRequest
dtls: sync handle_info for connection close with TLS
dtls: sync handling of ClientHello with TLS
dtls: rework handshake flight encodeing
dtls: implement next_tls_record
dtls: sync init and initial_state with tls_connection
dtls: update start_fsm for new ssl_connection API
ssl: introduce the notion of flights for dtls and tls
ssl: move available_signature_algs to ssl_handshake
Diffstat (limited to 'lib/ssl/src/ssl_handshake.erl')
-rw-r--r-- | lib/ssl/src/ssl_handshake.erl | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/lib/ssl/src/ssl_handshake.erl b/lib/ssl/src/ssl_handshake.erl index acc5ae6bd7..9c3fe9d73b 100644 --- a/lib/ssl/src/ssl_handshake.erl +++ b/lib/ssl/src/ssl_handshake.erl @@ -65,7 +65,7 @@ %% Cipher suites handling -export([available_suites/2, available_signature_algs/3, cipher_suites/2, - select_session/11, supported_ecc/1]). + select_session/11, supported_ecc/1, available_signature_algs/4]). %% Extensions handling -export([client_hello_extensions/6, @@ -2191,3 +2191,14 @@ bad_key(#'RSAPrivateKey'{}) -> unacceptable_rsa_key; bad_key(#'ECPrivateKey'{}) -> unacceptable_ecdsa_key. + +available_signature_algs(undefined, SupportedHashSigns, _, {Major, Minor}) when + (Major >= 3) andalso (Minor >= 3) -> + SupportedHashSigns; +available_signature_algs(#hash_sign_algos{hash_sign_algos = ClientHashSigns}, SupportedHashSigns, + _, {Major, Minor}) when (Major >= 3) andalso (Minor >= 3) -> + sets:to_list(sets:intersection(sets:from_list(ClientHashSigns), + sets:from_list(SupportedHashSigns))); +available_signature_algs(_, _, _, _) -> + undefined. + |