I tried to use redir as an SSH ProxyCommand directly, e.g.:
Host qemu-*
ProxyCommand redir --inetd --caddr=localhost --cport=%p
It fails like this:
[pid 3193] read(4, "SSH-2.0-OpenSSH_4.3p2 Debian-5\n", 4096) = 31
[pid 3193] write(0, "SSH-2.0-OpenSSH_4.3p2 Debian-5\n", 31) = -1 EBADF (Bad
file descriptor)
[pid 3193] shutdown(0, 0 /* receive */) = -1 ENOTSOCK (Socket operation on
non-socket)
The shutdown failure's not a problem, but its tendency to write to stdin
instead of stdout is a problem; I presume that this works if the same socket
is connected on stdin and stdout using dup, since sockets are bidirectional.
thanks for noting this. i'm trying to sort out what it means that this doesn't work. Canonically, stdin is FD 0 and stdout is FD 1 (stderr is FD 2). ssh_config(5) describes ProxyCommand as: The command can be basically anything, and should read from its standard input and write to its standard output. But inetd(8) says that: The master socket will then be passed as fd 0 to the server, which will then need to accept the incoming connection. and redir(1) says:
hi tobias-- i've orphaned redir (http://bugs.debian.org/619357) -- would you be interested in taking the package over? If not, i intend to ask ftp-masters to remove it from the archive.