aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ssh/src
diff options
context:
space:
mode:
authorHans Nilsson <[email protected]>2014-02-13 14:42:58 +0100
committerHans Nilsson <[email protected]>2014-02-14 10:44:14 +0100
commit0179e67a2df1ee12b35eb0220f05fdf3b03cbba2 (patch)
tree945ba2ec8afeb12d9a3d1e617356fc6389f5f8de /lib/ssh/src
parent0ce8bca286c0d283e8ef833ce73284d717c1c161 (diff)
downloadotp-0179e67a2df1ee12b35eb0220f05fdf3b03cbba2.tar.gz
otp-0179e67a2df1ee12b35eb0220f05fdf3b03cbba2.tar.bz2
otp-0179e67a2df1ee12b35eb0220f05fdf3b03cbba2.zip
ssh: Fixes memory crash
Diffstat (limited to 'lib/ssh/src')
-rw-r--r--lib/ssh/src/ssh_message.erl5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/ssh/src/ssh_message.erl b/lib/ssh/src/ssh_message.erl
index 2cb33eff32..219360bb08 100644
--- a/lib/ssh/src/ssh_message.erl
+++ b/lib/ssh/src/ssh_message.erl
@@ -424,8 +424,9 @@ decode(<<?BYTE(?SSH_MSG_KEX_DH_GEX_REQUEST_OLD), ?UINT32(N)>>) ->
#ssh_msg_kex_dh_gex_request_old{
n = N
};
-decode(<<?BYTE(?SSH_MSG_KEX_DH_GEX_GROUP), ?UINT32(Len0), Prime:Len0/big-signed-integer,
- ?UINT32(Len1), Generator:Len1/big-signed-integer>>) ->
+decode(<<?BYTE(?SSH_MSG_KEX_DH_GEX_GROUP),
+ ?UINT32(Len0), Prime:Len0/big-signed-integer-unit:8,
+ ?UINT32(Len1), Generator:Len1/big-signed-integer-unit:8>>) ->
#ssh_msg_kex_dh_gex_group{
p = Prime,
g = Generator