diff options
author | Péter Dimitrov <[email protected]> | 2019-02-11 16:29:16 +0100 |
---|---|---|
committer | Péter Dimitrov <[email protected]> | 2019-02-11 16:29:16 +0100 |
commit | 578524273019737549e3ef9c7bde4ee6a6c42be3 (patch) | |
tree | 631fc424d234d94e4315c903a4461f4d40717606 /lib/ssl | |
parent | 934f9974eb6bec43cd9445ec0f5019a4d1389428 (diff) | |
download | otp-578524273019737549e3ef9c7bde4ee6a6c42be3.tar.gz otp-578524273019737549e3ef9c7bde4ee6a6c42be3.tar.bz2 otp-578524273019737549e3ef9c7bde4ee6a6c42be3.zip |
ssl: Use sha256 in test certificates if supported
This commit fixes ssl_test_lib:appropriate_sha/1 that returns sha256
if it is supported by crypto. It returns sha1 otherwise.
Change-Id: I0bfa4d50bbe3c788551a81d418db2cabc36a4344
Diffstat (limited to 'lib/ssl')
-rw-r--r-- | lib/ssl/test/ssl_test_lib.erl | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/ssl/test/ssl_test_lib.erl b/lib/ssl/test/ssl_test_lib.erl index 7767d76a0d..294aeb0211 100644 --- a/lib/ssl/test/ssl_test_lib.erl +++ b/lib/ssl/test/ssl_test_lib.erl @@ -825,7 +825,8 @@ make_rsa_cert(Config) -> Config end. appropriate_sha(CryptoSupport) -> - case proplists:get_bool(sha256, CryptoSupport) of + Hashes = proplists:get_value(hashs, CryptoSupport), + case lists:member(sha256, Hashes) of true -> sha256; false -> |