Silly me, the bug is there but the reasoning is wrong and the fix would be very 
simple! The enum is wrong, it is actually the one with REQUEST_DENIED and 
FATAL. The solution is to add a new error type that GetErrorCode can return in 
that enum that has the value of 3, and we keep binary compatibility.



Sent from my Windows 10 phone



From: Jason Curl<mailto:[email protected]>
Sent: Sunday 28 May 2017 21:04
To: [email protected]<mailto:[email protected]>
Subject: Minor error in setting error



Hi,

I've found what appears to be a bug in code. the function ssh_set_error
takes an int for an input, but there appears to be an enum for this
called ssh_error_types_e. In almost all cases usage of ssh_set_error
uses a value from the enum, except in messages.c line 864 which has one
line of code:

              ssh_set_error(session, SSH_LOG_PACKET, "USERAUTH_REQUEST:
gssapi-with-mic missing OID");

In this case, SSH_LOG_PACKET=3 which is the same value as SSH_EINTR=3.

Regards,
Jason.


Reply via email to