I am writing a server that uses the telnet protocol to communicate with clients.
One of the commands I would like to implement will allow the client to edit their user-info with vi. Two concerns:
1. How do I invoke vi, such that the input from the socket goes into vi, and vi's output goes back to the client?
2. How do I start vi in such a way that prohibits the user from opening any files other than the one specified on the command line?
I realize this might be a dumb question, however I am coming from a Microsoft background and am just beginning to learn about Unix programming.
But thanks in advance, for all your help.
Will
One of the commands I would like to implement will allow the client to edit their user-info with vi. Two concerns:
1. How do I invoke vi, such that the input from the socket goes into vi, and vi's output goes back to the client?
2. How do I start vi in such a way that prohibits the user from opening any files other than the one specified on the command line?
I realize this might be a dumb question, however I am coming from a Microsoft background and am just beginning to learn about Unix programming.
But thanks in advance, for all your help.
Will