Solved

Telnet using c#

Posted on 2011-02-17
5
1,519 Views
Last Modified: 2012-08-13
I want to build an application in c# which is used to send file via telnet and receive acknowledgement.


Suppose I use cmd and type o 10.200.5.2 and connect to the remote server...
then it ask me to type login name
then it ask me to type password
then it show a screen with a list of options of me.

I want to choose option 1
then I type 1 and press enter

how can I do such things in PHP?
0
Comment
Question by:sam000
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 12

Expert Comment

by:Praveen Kumar
ID: 34914201
0
 

Author Comment

by:sam000
ID: 34914441
It is ok, but I need to get back the response and process that in the code using switch
0
 
LVL 16

Expert Comment

by:Kalpesh Chhatrala
ID: 34915343
Hope this helpful to you

Asynchronous socket communication example

http://www.codeproject.com/KB/IP/socketsincs.aspx
0
 
LVL 15

Accepted Solution

by:
Russell_Venable earned 500 total points
ID: 34922014
Actually this is exactly what your need. It waits for and reads for specific text in the console and then respondes if it matches. It was made for talking to Cisco Routers, but it easily configurable for this purpose.
CSharp Telnet client
0
 
LVL 15

Expert Comment

by:Russell_Venable
ID: 34922140
If PHP is what you are looking for and not C# first off your in the wrong section ;)

Next you should be looking at something that is already made for that purpose.
PHP Telnet

Make sure you parse the results with for your commands by using the switch example and then $Telnet->DoCommand("Command", $result); to send your command in response. Simple and easy enough.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
We all know how boring and exhausting it is to transfer huge web projects developed locally to a webserver simply via FTP. The File Transfer Protocol is a really nice solution if you need to transfer small amounts of files, but if you're plannin…
Viewers will learn how to properly install and use Secure Shell (SSH) to work on projects or homework remotely. Download Secure Shell: Follow basic installation instructions: Open Secure Shell and use "Quick Connect" to enter credentials includi…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question