diff options
author | Hans Nilsson <[email protected]> | 2015-12-08 11:54:21 +0100 |
---|---|---|
committer | Hans Nilsson <[email protected]> | 2015-12-08 11:54:21 +0100 |
commit | 45c940463b7fc16d81d023013c21eac36cd57939 (patch) | |
tree | 778673eaa6c8ecc2479991c2f04348ad867ff74f /lib/ssh/src/ssh_transport.erl | |
parent | 5fe8d649b1431d84d559e6c3730de25b54dbde31 (diff) | |
parent | bb1a28deb139c34e2425e08e11f55480f5de6526 (diff) | |
download | otp-45c940463b7fc16d81d023013c21eac36cd57939.tar.gz otp-45c940463b7fc16d81d023013c21eac36cd57939.tar.bz2 otp-45c940463b7fc16d81d023013c21eac36cd57939.zip |
Merge branch 'hans/ssh/defensics_errors' into maint
* hans/ssh/defensics_errors:
ssh: fix error for data fields errors
ssh: fix error for bad packet lengths found by Defensics
Diffstat (limited to 'lib/ssh/src/ssh_transport.erl')
-rw-r--r-- | lib/ssh/src/ssh_transport.erl | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/ssh/src/ssh_transport.erl b/lib/ssh/src/ssh_transport.erl index 67a0d29bb8..18037b8461 100644 --- a/lib/ssh/src/ssh_transport.erl +++ b/lib/ssh/src/ssh_transport.erl @@ -1004,10 +1004,7 @@ handle_packet_part(<<>>, Encrypted0, undefined, #ssh{decrypt = CryptoAlg} = Ssh0 {ok, PacketLen, _, _, _} when PacketLen > ?SSH_MAX_PACKET_SIZE -> %% far too long message than expected - throw(#ssh_msg_disconnect{code = ?SSH_DISCONNECT_PROTOCOL_ERROR, - description = "Bad packet length " - ++ integer_to_list(PacketLen), - language = ""}); + {error, {exceeds_max_size,PacketLen}}; {ok, PacketLen, Decrypted, Encrypted1, #ssh{recv_mac_size = MacSize} = Ssh1} -> |