The problem is:
1) The program will use telnet
2) It will connect to a host that the user will input to a
3) It will send predetermined commands to the running service.
The process I think should be
My question are
1) How to wait for response, e.g. wait for "login" / "Password"
2) How to send "userId", "password" and "myProgram"?
3) How to set a timeout if there is no response from remote machine?
> The problem is:
> 1) The program will use telnet
> 2) It will connect to a host that the user will input to a
> 3) It will send predetermined commands to the running service.
> The process I think should be
> 1)system("telnet remoteIP")
> My question are
> 1) How to wait for response, e.g. wait for "login" / "Password"
> 2) How to send "userId", "password" and "myProgram"?
> 3) How to set a timeout if there is no response from remote machine?
This was done a long time ago .....
Look at the source code for the UUCP programs
uucico in combination with the /etc/uucp/Systems file
waits for ogin: and sword:
In article <email@example.com>, tunla <firstname.lastname@example.org> wrote:
> This was done a long time ago .....
> Look at the source code for the UUCP programs
> uucico in combination with the /etc/uucp/Systems file
> waits for ogin: and sword:
Or better yet, use the 'expect' utility which is a much more robust and
currently maintained solution that can do significant error checking.
email@example.com wrote on 2005-12-02 18:48:
> Where can I find some good stuff about 'expect'?
> Any good example you can give me?
A google for "expect telnet" gives for example http://expect.nist.gov/
- Erlend Leganger
Telnet client in C Hallo,
Am trying to establish a telnet session with my C program. However, I
seem not to able to get the prompt, after supplying the username and
passowrd. could someone assist me in troubleshoot my code and inform me
where i might be getting it wrong.
I would appreciate if I got ideas of how to achieve this in a simpler
way. Below is my code
Unable to telnet to my machine Hello All,
I tried to telnet to my machine it showing
root@ice2# telnet 172.16.10.12
telnet: Unable to connect to remote host: Connection refused
I have checked " /etc/default/login ", "CONSOLE" is commented. I
connected this machine (ice1) to my other server (ice2) via serial
port and made a tip connection. Through this tip window(ice1) I am
able to login to ice2 machine but it not happening in reverse order.
By the way I logged in as root and I am unable to change the passwd :
Not able to telnet in to machine, error Hi.
I have an customer with an Solaris 8.0 server.
We have setup vpn for maintenance and we always use telnet to/for our
Half an year ago this machine went down because of heat problems (the
sun caused to much heat in the room and customer is not willing to
After that crasch we have problems logging in with Telnet it gives
Connected to customer.
Escape character is '^]'.
ld.so.1: login: fatal: /usr/lib/libc.so.1: Too many open files
Connection closed by foreign host.
Remote telnet through firewall failing I have built a replacement 5.0.5e server from a fresh install, which is now
working on my LAN. Telnet from within the LAN to the SCO system works
fine, however if I attempt to telnet to it from outside (the GNet IP0006
router is forwarding port 23 to the SCO system) then the attempted
connection times out with no evidence of contact. I can telnet from
outside to other (Linux) systems on the LAN, so it appears to be a SCO
configuration issue. Any suggestions (other than using SSH) would be
Destination Gateway Flags Refs Use Interface
Net::Telnet, Terminal Programs, Prompts Hi, I have been trying to create a Tk::Text that reads and writes to a
Net::Telnet object. It works fairly well, but doesnt handle terminal
types of programs like vi.
Just looking for any ideas from the experts. I dont know to much about
termianl emulations, etc.
Also, i get two prompts. Anyone know why i might be getting that from
Net::Telnet; I have prompt set to anything and timeout at 0, so i dont
match on prompt or block. I just poll every 1/4 sec. But what i read
with get, comes with two prompts. Any ideas on a better method let me
know. I was trying to keep from using prompt, allowing...
Using fork() with a telnet-esque socket connection Greetings,
Before I get too far into the guts of writing a custom telnet daemon, I
thought i'de test the waters and get some input. Im building an open
source text-based RPG (brings back memories eh? :). Looking to support
anywhere from 50-250 simultaneous connections (just depends on the
host's bandwith), with MySQL as the backend. Majority of my Perl
knowledge is self taught, so my terminology is unique (and thus hard to
ask specific questions). This is my first venture into Perl using socket
connections, and have read about using fork() to create a multithreaded
telnet in buffer using elisp -- is this the best way? Hi
Apologies for the basic nature of the questions, but my area is s/w testing,
not elisp writing. ;-)
I frequently have the need to telnet into routers, via console ports thru a
term server or a native ip address. I've built some *very* basic elisp
functions for doing this, but I'm wondering if there is a better way. The
number of routers in my environment continues to grow (Im in a testing
group, we have hundreds of the things). So, this approach has become a real
problem since each router requires a separate function to access it.
Here are a couple examples:
(defun 5gw-con ()
How to Telnet to Unix Machine without User Interaction Hello all,
Is there is any script, so that if I entered my hostname, Username and
password in the script it should automatically entered into that
machine ie via Telnet.
In article <firstname.lastname@example.org>,
> Hello all,
> Is there is any script, so that if I entered my hostname, Username and
> password in the script it should automatically entered into that
> machine ie via Telnet.
> Velmurugan G
try installing expect
How to pass user name and password when telnet to a machine Hello,
How I can pass username and password as an argument when I telnet or
rlogin to a machine to avoid user interaction.
You can put the machine name, username and password in the .netrc file
and the execute the rlogin command like this :
rlogin -l <user name> <hostname>
>How I can pass username and password as an argument when I telnet or
>rlogin to a machine to avoid user interaction.
PF keyboard mappings for VMS telnet using RDP/Rdesktop This was originally posted to the Thinstation mailing list and then to
the Rdesktop list. They dont seem to be very interested in PF key
support, I think perhaps I am the only one trying to use this.
Thinstation is a small linux distrobution that usings Rdesktop for
terminal services connections to windows.
With Thinstation 2.1, if I launch a telnet session to an OpenVMS
7.2-1 all the keyboard mappings are correct with DEC PF1-PF4.
Everything works great.
When I try the same thing from inside Rdesktop, The PF1 (number lock)
Telnet in PIX I need to have remote telnet to my pix from another office location. I add
telnet x.x.x.x 255.255.255.255
where x is the external IP of the office I will be telneting from, but I
still cannot telnet in from the remote location. I have also tried to add an
access-list outside_acl tcp permit any host x.x.x.x eq telnet
where x is the external IP of my pix box. Am I missing something here? anyw
help would be greatly appreciated. Thank you
Shawn H. Mesiatowsky
On Mon, 22 Nov 2004, Shawn H. Mesiatowsky wrote:
> I need to have remote telnet to my pix from a...
problems with Telnet Could anybody tell me why my telnet doesn't work?
I see this error (bad seg from 192.168.1.20) but i don't know what it
means. I'm using the following IOS
IOS (tm) C2600 Software (C2600-I-M), Version 12.3(9), RELEASE SOFTWARE
Copyright (c) 1986-2004 by cisco Systems, Inc.
Compiled Fri 14-May-04 14:37 by dchih
Image text-base: 0x80008098, data-base: 0x80CC0
2d14h: %SYS-5-CONFIG_I: Configured from console by console
2d14h: tcp66: O ESTAB 192.168.1.20:23 192.168.1.1:3348 seq 1944694475
DATA 12 ACK 853400241 PSH WIN 4128
2d14h: tcp66: O FINWAIT1 192.168.1.2...
telnet logins Is it conventional to exclude the x-client directory (on my system its
/usr/openwin/bin) from the path when logging in over a telnet session?
The problem I'm having is that I often like to telnet into my unix
account from my pc in order to start up an x-client, usually an xterm.
However, on our system the xclient directory is not concatenated to the
path when the source of login is via telnet.
If this startup behavior for telnet logins is conventional, then how do
folks typically start xclients on a remote machine? It seems
unreasonable to require people to know where these applications ...
Reverse telnet I have a 2811 and a concentrator 3005. I connect the Cisco cable, the
RJ-45 end to the aux port of the 2811, and the other end 9-pinF to the
console port of the concentrator.
On the 2811, I setup reverse telnet as follows :
line aux 0
exec-timeout 0 0
transport input all
ip address 10.0.0.10 255.0.0.0
"sh line" on 2811 shows
Tty Line Typ Tx/Rx A Modem Roty AccO AccI Uses Noise Overruns
0 0 CTY - - - - - 0 5
1 1 AUX 9600/9600 - inout - - - 2 0
can not telnet Hi,
When I try to login into a Sun Solaris system, it intitally asks:
"Choose a new password.".
When a new password is entered, it asks:
"Re-enter new Password:".
Once, the new password is entered, it gives the following error, and
hence, could NOT login successfully:
"telnet: System error: repository out of range."
1) Please let me know why it asks to change the password. Also,
2) How to avoid this error?
Can this be done. I want to be able to telnet/ssh into my pix 501. From
the prompt,can I telnet to my windows server?
Outside --> PIX 501 --> Windows machine
I tried it but nothing works.
In article <email@example.com>,
"firstname.lastname@example.org" <email@example.com> wrote:
> Can this be done. I want to be able to telnet/ssh into my pix 501. From
> the prompt,can I telnet to my windows server?
> Outside --> PIX 501 --> Windows machine
How Do I Reverse Telnet I have 3 different networks running to my site that do not touch each
other at all. I only have access to one from my office. My buddy told
me that it's possible to connect a rollover cable to the switches so
that I can telnet into all 3 networks but traffic will not pass between
them. I know that I need a rollover cable and that I have to connect
it to the Con and Aux ports but after that I'm lost. Can anyone help
me out with a step by step on how to do it. I have 3 cisco 3550's
sitting in a box in a bunch of different offices.
You may wish to investigate Cisco's Connec...
telnet backup access Hey Everybody,
Can someone give me a pointer on how to configure a Cisco 2950 or 2600
series router to responde to local telnet crediential if/when an
external radius server goes down?
my current config looks like this,:
aaa authentication login use-radius group radius
aaa authorization exec use-radius if-authenticated
aaa accounting exec use-radius start-stop broadcast group radius
aaa session-id common
radius-server host x.x.x.x auth-port 1645 acct-port 1646
radius-server key 7 cisco
line vty 0 4
login authentication use-radius
> Can someone give me a po...
Reverse Telnet and NAT? I'm having trouble figuring out why this doesn't work...
I have setup reverse telnet from RouterA's AUX port (line 65) to
RouterB's CON port. I created a loopback interface (loop99), address
172.24.1.1 /32 on Router A, added a static route to that address with a
32 bit mask in the routing table of the rest of the companies routers,
pointing to the ethernet interface of RouterA. I can type
telnet 172.24.1.1 2065
from any host and everything works great.
Now, perhaps I'm overthinking this, but couldn't I create a NAT with
another loopback interface to avoid typing i...
CHAP for Telnet session? Hi
I am in the process of setting up authentication for telnet sessions
via RADIUS to a MS IAS server.
Everything is up and running using PAP where I would prefer using CHAP
but can't find any command to facilitate this.
I found loads of references to PPP but PPP is not being used in this
instance. Any ideas?
command radius-server key <secretkey>
BradReese.Com Cisco Repair Service Experts
1293 Hendersonville Road, Suite 17
Asheville, North Carolina USA 28803
U.S. Toll Free: 8...