I have an embedded linux application with a simple interactive command line interface.
I\'d like to access the command line from telnet (or network, in general).
I found that by using bash v. >= 4.0 I can use coproc:
coproc
#!/bin/bash coproc myapp nc -kl -p 4000 <&"${COPROC[0]}" >&"${COPROC[1]}"
EDIT
I eventually incorporated a telnet server in my cli library. You can find the result on GitHub: https://github.com/daniele77/cli