0

Possible Duplicate:
C# Telnet Library

I wish to do telnet programatically using C# so that once I establish the connection to the server, I can execute the commands like ls, ls -l, mv, rm.. etc on the server.

Is it possible? Are there classes in C# for this purpose similar to the classes for FTP (FtpWebRequest)? If yes, please direct me to the right approach.

When I execute ls, I need the list generated on server to be sent to the client i.e. windows machine in my case.

Community
  • 1
  • 1
Nayan Soni
  • 1,001
  • 3
  • 12
  • 22

1 Answers1

4

Yes, here you have a telnet library http://www.codeproject.com/KB/IP/MinimalisticTelnet.aspx

kamote
  • 76
  • 2
  • Need to know one thing from the Minimalistic Telnet app. I went and debugged to understand the code. Understood most of it.. but have a doubt in one area i.e the user command (like ls) is converted to bytes and written on the socket stream (tcpSocket.GetStream().Write(buf, 0, buf.Length)) and then read byte by byte. I would like to know where is the command actually executed?? Little confused here.. – Nayan Soni Jan 16 '13 at 15:04