Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles
(untagged)

NT Telnet server and client

0.00/5 (No votes)
22 Nov 1999 1  
CTelnetView is a class derived from CView that implements a telnet client session with history.
  • Download client source - 22 Kb
  • Download server source - 22 Kb

    Sample Image

    The Telnet Client view

    CTelnetView is a class derived from CView that implements a telnet client session with history. It can be useful in building a remote administration tool or a full-blown telnet client. As implemented the terminal emulation is for TTY only and no escape sequences (VT100) or ANSI control codes are recognized

    The socket instance and connect logic are all resident in the view. As a result an MDI app that allows acces to multiple servers is easily built.

    All of the interesting stuff is in the class CTelnetView and in the Socket class. All of the other classes are exactly as made by the DevStudio Project Wizard EXCEPT that a call to initialize winsock has been added to the App class.

    The Telnet Server

    In addition to the client above I have included a complete Telnet Server (Daemon). I had a hard time finding a good one for NT (it will not work for 95/98, don't know about 2000) so I wrote this one. It is a SINGLE USER server, only one session at a time can be running. It is, however a nice example of how to use the NT CreateProcessAsUser facility.

    It is an NT service. To install use:

    TelnetServer_NT -i
    

    To start it use:

    TelnetServer_NT -s
    

    Acknowledgements

    The TelnetServer project uses the excellent NT Service wrapper class by Joerg Koenig. Thanks for the great code.

  • License

    This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

    A list of licenses authors might use can be found here