I need to run any remote shell daemon (ssh, telnet, netcat, socat... I don't mind) as non-root user. The remote shell should provide tab-completion and I want to be able to browse history using arrows.I am currently using a netcat-based solution, but I loose tab-completion and I am unable to browse history using arrowsOn server side :#Run the remote shell daemon$ mkfifo fifo$ nc -l 2000 <fifo | /bin/bash &> fifo$ rm fifoOn client side : #Connect to the remote shell$ nc $REMOTE_ADDR 2000Adding the -i or -l argument to bash does not help.
Run remote shell daemon as non root user with tab-completion
shell;telnet
socat(1) could be of some help.From http://stuff.mit.edu/afs/sipb/machine/penguin-lust/src/socat-1.7.1.2/EXAMPLES:// poor mans 'telnetd' replacement# socat tcp-l:2023,reuseaddr,fork exec:/bin/login,pty,setsid,setpgid,stderr,ctty// and here an appropriate client:$ socat -,raw,echo=0 tcp:172.16.181.130:2023Here, the example uses login which obviously requires a root access but I succesfully tested with /bin/zsh. This implies that security is not a problem... Otherwise, as they say in the webpage where I found out this tip, you could use a client authentication with SSL to make sure only you can actually log in.