diff options
author | Ingela Anderton Andin <[email protected]> | 2010-08-24 11:05:28 +0200 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2010-08-31 15:08:11 +0200 |
commit | 1c3ed28fc20b64a8419a939c7417000be1e63c5c (patch) | |
tree | 2a94ac05abd324db4113f726ad95994c138936a8 /lib/ssl/test/ssl_test_lib.erl | |
parent | 82d430853eb1f53e6022de647c26254fe5681454 (diff) | |
download | otp-1c3ed28fc20b64a8419a939c7417000be1e63c5c.tar.gz otp-1c3ed28fc20b64a8419a939c7417000be1e63c5c.tar.bz2 otp-1c3ed28fc20b64a8419a939c7417000be1e63c5c.zip |
Add tests for crypto RC4 bug
Changed test so that the test cases testing all different ciphers
also sends data so that that the calls to crypto cipher functions
are also tested.
Diffstat (limited to 'lib/ssl/test/ssl_test_lib.erl')
-rw-r--r-- | lib/ssl/test/ssl_test_lib.erl | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/ssl/test/ssl_test_lib.erl b/lib/ssl/test/ssl_test_lib.erl index c7ff015034..c35178460f 100644 --- a/lib/ssl/test/ssl_test_lib.erl +++ b/lib/ssl/test/ssl_test_lib.erl @@ -623,3 +623,20 @@ pem_to_der(File) -> der_to_pem(File, Entries) -> PemBin = public_key:pem_encode(Entries), file:write_file(File, PemBin). + +cipher_result(Socket, Result) -> + Result = ssl:connection_info(Socket), + test_server:format("Successfull connect: ~p~n", [Result]), + %% Importante to send two packets here + %% to properly test "cipher state" handling + ssl:send(Socket, "Hello\n"), + receive + {ssl, Socket, "Hello\n"} -> + ssl:send(Socket, " world\n"), + receive + {ssl, Socket, " world\n"} -> + ok + end; + Other -> + {unexpected, Other} + end. |