diff options
author | Ingela Anderton Andin <[email protected]> | 2012-06-20 10:58:04 +0200 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2012-08-22 14:00:45 +0200 |
commit | a3f30e77131de6dc2f9e5746a9274f35d6b0c440 (patch) | |
tree | 66bb2a0c83d81587c4c51ea56b132d3b0284c17f /lib/ssl/test/ssl_test_lib.erl | |
parent | cc8d74769cc49a754598bf914e585d193177a00d (diff) | |
download | otp-a3f30e77131de6dc2f9e5746a9274f35d6b0c440.tar.gz otp-a3f30e77131de6dc2f9e5746a9274f35d6b0c440.tar.bz2 otp-a3f30e77131de6dc2f9e5746a9274f35d6b0c440.zip |
ssl: Run relevant tests for all SSL/TLS versions
Diffstat (limited to 'lib/ssl/test/ssl_test_lib.erl')
-rw-r--r-- | lib/ssl/test/ssl_test_lib.erl | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/lib/ssl/test/ssl_test_lib.erl b/lib/ssl/test/ssl_test_lib.erl index fa8a1826f2..905801fe3d 100644 --- a/lib/ssl/test/ssl_test_lib.erl +++ b/lib/ssl/test/ssl_test_lib.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 2008-2011. All Rights Reserved. +%% Copyright Ericsson AB 2008-2012. All Rights Reserved. %% %% The contents of this file are subject to the Erlang Public License, %% Version 1.1, (the "License"); you may not use this file except in @@ -708,3 +708,20 @@ state([{data,[{"StateData", State}]} | _]) -> State; state([_ | Rest]) -> state(Rest). + +is_tls_version('tlsv1.2') -> + true; +is_tls_version('tlsv1.1') -> + true; +is_tls_version('tlsv1') -> + true; +is_tls_version('sslv3') -> + true; +is_tls_version(_) -> + false. + +init_tls_version(Version) -> + ssl:stop(), + application:load(ssl), + application:set_env(ssl, protocol_version, Version), + ssl:start(). |