I asked about my previously discussed problems with
ssh on the daemon-users list, and received a very prompt reply from Raf (thanks Raf!). Apparently the solution is to use the
-t option to
ssh. This is described in the man page as:
Force pseudo-tty allocation. This can be used to execute arbitrary screen-based programs on a remote machine, which can be very useful, e.g., when implementing menu services. Multiple -t options force tty allocation, even if ssh has no local tty.
ssh to allocate a pseudo-terminal,
stdin will no longer be a socket, so it won’t think it’s being started from
inetd. It will then
fork() and the
ssh session will end immediately as desired.