Skip to content

Commit

Permalink
update crypto calls for OTP 19 and added to travis otps
Browse files Browse the repository at this point in the history
  • Loading branch information
tsloughter committed Jan 13, 2017
1 parent d347e59 commit 19ba274
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
language: erlang

otp_release:
- 19.2
- 18.2.1

before_script: kerl list installations
Expand Down
2 changes: 1 addition & 1 deletion test/client_server_SUITE.erl
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ echo_body(_Config) ->

http2c:send_unaltered_frames(Client, [HeaderFrame]),

Body = crypto:rand_bytes(128),
Body = crypto:strong_rand_bytes(128),
BodyFrames = h2_frame_data:to_frames(3, Body, #settings{max_frame_size=64}),
http2c:send_unaltered_frames(Client, BodyFrames),

Expand Down
2 changes: 1 addition & 1 deletion test/flow_control_SUITE.erl
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ send_n_bytes(N) ->
%% window, but not the connections

%% So now, send N bytes and we should get some desired error.
Data = crypto:rand_bytes(N),
Data = crypto:strong_rand_bytes(N),
Frames = h2_frame_data:to_frames(3, Data, #settings{}),

http2c:send_unaltered_frames(Client, Frames),
Expand Down
4 changes: 2 additions & 2 deletions test/flow_control_handler.erl
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ on_request_end_stream(State=#state{conn_pid=ConnPid,
{<<":status">>,<<"200">>}
],
h2_connection:send_headers(ConnPid, StreamId, ResponseHeaders),
h2_connection:send_body(ConnPid, StreamId, crypto:rand_bytes(?SEND_BYTES),
h2_connection:send_body(ConnPid, StreamId, crypto:strong_rand_bytes(?SEND_BYTES),
[{send_end_stream, false}]),
timer:sleep(200),
h2_connection:send_body(ConnPid, StreamId, crypto:rand_bytes(?SEND_BYTES)),
h2_connection:send_body(ConnPid, StreamId, crypto:strong_rand_bytes(?SEND_BYTES)),
{ok, State}.
2 changes: 1 addition & 1 deletion test/http2_spec_5_5_SUITE.erl
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ sends_unknown_extension_frame(_Config) ->
http2c:send_binary(Client, Bin),

%% It should be ignored, so let's send a ping and get one back
Data = crypto:rand_bytes(8),
Data = crypto:strong_rand_bytes(8),
http2c:send_unaltered_frames(
Client,
[
Expand Down

0 comments on commit 19ba274

Please sign in to comment.