SunnyByfleet
Technical User
Hi,
I am trying to automate some telnet sessions.
For instance, rather than typing:
telnet 192.168.1.1
admin // (when asked for username)
admin // (when asked for password)
help /? // (Just something to do)
I want the key strokes in a file so I can pipe it into the telnet session.
I have the keystrokes in a file called tempfile
I have tried the following:
type tempfile | telnet 192.168.1.1
I have also tried:
telnet 192.168.1.1 < tempfile
In both cases, I get the following:
Welcome to Microsoft Telnet Client
Escape Character is 'CTRL+]'
Anybody have any idea how I can get this working?
I am trying to automate some telnet sessions.
For instance, rather than typing:
telnet 192.168.1.1
admin // (when asked for username)
admin // (when asked for password)
help /? // (Just something to do)
I want the key strokes in a file so I can pipe it into the telnet session.
I have the keystrokes in a file called tempfile
I have tried the following:
type tempfile | telnet 192.168.1.1
I have also tried:
telnet 192.168.1.1 < tempfile
In both cases, I get the following:
Welcome to Microsoft Telnet Client
Escape Character is 'CTRL+]'
Anybody have any idea how I can get this working?