diff options
author | Hans Nilsson <[email protected]> | 2014-02-12 13:48:54 +0100 |
---|---|---|
committer | Hans Nilsson <[email protected]> | 2014-02-14 10:45:44 +0100 |
commit | b59ec053b2c8f7b75cce7448705da96a5fcc849a (patch) | |
tree | 7908264688e5224de67a6e7dfc06b71789cbb419 /lib/ssh | |
parent | 0179e67a2df1ee12b35eb0220f05fdf3b03cbba2 (diff) | |
download | otp-b59ec053b2c8f7b75cce7448705da96a5fcc849a.tar.gz otp-b59ec053b2c8f7b75cce7448705da96a5fcc849a.tar.bz2 otp-b59ec053b2c8f7b75cce7448705da96a5fcc849a.zip |
ssh: Changed order of decode clauses to temp fix decode error
Diffstat (limited to 'lib/ssh')
-rw-r--r-- | lib/ssh/src/ssh_message.erl | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/lib/ssh/src/ssh_message.erl b/lib/ssh/src/ssh_message.erl index 219360bb08..a63881db64 100644 --- a/lib/ssh/src/ssh_message.erl +++ b/lib/ssh/src/ssh_message.erl @@ -380,27 +380,30 @@ decode(<<?BYTE(?SSH_MSG_USERAUTH_BANNER), language = Lang }; +decode(<<?BYTE(?SSH_MSG_USERAUTH_INFO_REQUEST), ?UINT32(Len0), Name:Len0/binary, + ?UINT32(Len1), Inst:Len1/binary, ?UINT32(Len2), Lang:Len2/binary, + ?UINT32(NumPromtps), Data/binary>>) -> + #ssh_msg_userauth_info_request{ + name = Name, + instruction = Inst, + language_tag = Lang, + num_prompts = NumPromtps, + data = Data}; + +%%% Unhandled message, also masked by same 1:st byte value as ?SSH_MSG_USERAUTH_INFO_REQUEST: decode(<<?BYTE(?SSH_MSG_USERAUTH_PK_OK), ?UINT32(Len), Alg:Len/binary, KeyBlob/binary>>) -> #ssh_msg_userauth_pk_ok{ algorithm_name = Alg, key_blob = KeyBlob }; +%%% Unhandled message, also masked by same 1:st byte value as ?SSH_MSG_USERAUTH_INFO_REQUEST: decode(<<?BYTE(?SSH_MSG_USERAUTH_PASSWD_CHANGEREQ), ?UINT32(Len0), Prompt:Len0/binary, ?UINT32(Len1), Lang:Len1/binary>>) -> #ssh_msg_userauth_passwd_changereq{ prompt = Prompt, languge = Lang }; -decode(<<?BYTE(?SSH_MSG_USERAUTH_INFO_REQUEST), ?UINT32(Len0), Name:Len0/binary, - ?UINT32(Len1), Inst:Len1/binary, ?UINT32(Len2), Lang:Len2/binary, - ?UINT32(NumPromtps), Data/binary>>) -> - #ssh_msg_userauth_info_request{ - name = Name, - instruction = Inst, - language_tag = Lang, - num_prompts = NumPromtps, - data = Data}; decode(<<?BYTE(?SSH_MSG_USERAUTH_INFO_RESPONSE), ?UINT32(Num), Data/binary>>) -> #ssh_msg_userauth_info_response{ |