It seams there is a problem in "LocalForward,RemoteForward directives with bind_address". ssh expects the argument and source details as follows. -o "LocalForward port [bind_address:]host:hostport ". But in the coding bindaddress and port are interchanged in the assignment the file readconf.c 1111 fwd->listen_host = xstrdup(cleanhostname(fwdarg[0])); 1112 fwd->listen_port = a2port(fwdarg[1]); Sample run : ssh -N -vvv -o "LocalForward 2000 172.16.1.182:172.16.1.165:22" localhost Where fwdarg[0]= 2000 fwdarg[1]= 172.16.1.182 fwdarg[2]= 172.16.1.165 fwdarg[3]= 22.
Created attachment 855 [details] Patch for LocalForward,RemoteForward directives with bind_address option Attched patch fixes above problem.
(In reply to comment #0) > Sample run : > ssh -N -vvv -o "LocalForward 2000 172.16.1.182:172.16.1.165:22" localhost The bind address is optional before the port, same as -L/-R. That should be: LocalForward 172.16.1.182:2000 172.16.1.165:22 I see that ssh_config(5) says that the first argument must be a port, though, so it ought to be fixed.
yes, the manpage is wrong.
The documentation has been updated in OpenBSD and will be appear in Portable shortly. The relevant part of the description of LocalForward now reads: The first argument must be [bind_address:]port and the second argument must be host:hostport. IPv6 addresses can be specified by enclosing addresses in square brackets or by using an alternative syntax: [bind_address/]port and host/hostport. Thanks for the report.
Change all RESOLVED bug to CLOSED with the exception of the ones fixed post-4.4.