Created attachment 1543 [details] patch This provides SOCKS4A support, which allows a SOCKS4 client to provide a host name instead of an IP address. It indicates that it's doing so by using a known-invalid IP address 0.0.0.x (where x != 0), and then appending the NUL-terminated hostname to the connection request. Although we check for the terminating NUL manually and the 'fatal(len %d > have %d)' should never happen, the condition for it (in the existing processing of the username) seems to have been off-by-one; not accounting for the terminating NUL. I've fixed that while I'm at it.
Created attachment 1544 [details] correct patch Oops; wrong patch. Try this one. Sorry.
patch applied - this will be in openssh-5.2
Close bugs fixed/reviewed for openssh-5.2 release