aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngela Anderton Andin <[email protected]>2013-05-14 17:28:37 +0200
committerIngela Anderton Andin <[email protected]>2013-05-20 08:41:52 +0200
commitb08c5038eea880b401dbb66daef3e439b26f2fa1 (patch)
tree6ace2f1e5665cc87d4b6589ecd885776404be339
parentf706e003a2f6cb3f1f31b9d1294b379c2ab3affe (diff)
downloadotp-b08c5038eea880b401dbb66daef3e439b26f2fa1.tar.gz
otp-b08c5038eea880b401dbb66daef3e439b26f2fa1.tar.bz2
otp-b08c5038eea880b401dbb66daef3e439b26f2fa1.zip
dialyzer: Remove use of deprecated crypto functions
-rw-r--r--lib/dialyzer/test/small_SUITE_data/src/tuple_set_crash.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/dialyzer/test/small_SUITE_data/src/tuple_set_crash.erl b/lib/dialyzer/test/small_SUITE_data/src/tuple_set_crash.erl
index 5503f39412..e6256e5a53 100644
--- a/lib/dialyzer/test/small_SUITE_data/src/tuple_set_crash.erl
+++ b/lib/dialyzer/test/small_SUITE_data/src/tuple_set_crash.erl
@@ -69,8 +69,8 @@ test(TargetId, [Date | DateTail], Key, IVT, IVF) ->
{ok, message_from_server(), binary(), binary()}.
culprit(Message, Key, IVecToServer, IVecFromServer) ->
{Packet, NewIVecToServer} = message_to_packet(Message, Key, IVecToServer),
- Message = crypto:aes_cbc_128_decrypt(Key, IVecFromServer, Packet),
- NewIVecFromServer = crypto:aes_cbc_ivec(Packet),
+ Message = crypto:block_decrypt(aes_cbc128, Key, IVecFromServer, Packet),
+ NewIVecFromServer = crypto:next_iv(aes_cbc, Packet),
ParsedMessage = parse_message(Message),
{ok, ParsedMessage, NewIVecToServer, NewIVecFromServer}.
@@ -185,9 +185,9 @@ parse_audio_output_info(<<Output:?DWORD, BitMap:?BITMAP1, Rest/binary>>) ->
-spec message_to_packet(binary(), binary(), binary()) -> {binary(), binary()}.
message_to_packet(Message, Key, IVec) ->
PaddedMessage = pad_pkcs5(Message),
- Packet = crypto:aes_cbc_128_encrypt(Key, IVec, PaddedMessage),
+ Packet = crypto:block_encrypt(aes_cbc128, Key, IVec, PaddedMessage),
TotalSize = byte_size(Packet),
- NewIVec = crypto:aes_cbc_ivec(Packet),
+ NewIVec = crypto:next_iv(aes_cbc, Packet),
{<<TotalSize:?WORD, Packet/binary>>, NewIVec}.
-spec pad_pkcs5(binary()) -> binary().