Login via telnet

May 20, 2010 at 12:13 PM

Hi all,

I try to use the TelnetClient to connect to a server, login, execute a remote command, and save the output to a file ..

Please can you help me to found the right sequence to login ... since, it doesn't work for me..

 

 

                TelnetClient client = new TelnetClient(socket);
                TelnetStream stream = new TelnetStream(client);
                StreamReader sReader = new StreamReader(stream);
                StreamWriter sWriter = new StreamWriter(stream);

		sWriter.Write("login"); 

 

Regards,

 

Didier

 

 

May 20, 2010 at 12:41 PM

The only place your going to get any help is on the MSDN forums sections. That would be your best bet. Good luck.