Re: telnet session to read or write a file

2010-02-20 Thread Jim Gibson
At 3:20 PM +0530 2/20/10, suresh kumar wrote: Hi Folks, I am trying to connect to a server where i want to create a file or read a existing file. This is my code. #!/usr/bin/perl use Net::Telnet (); $t = new Net::Telnet (Timeout => 10, Prompt => '/] $/'); You are ask

Re: TELNET

2009-07-03 Thread Peter Scott
On Fri, 03 Jul 2009 15:24:14 +0530, Swayam wrote: > Hi ,, > >I want to test a scenario where it is required to check that >the > server *should not allow telnet .Please* let me know what is the best > way to do this If you just want to see if anything is there, make a TCP

RE: Telnet exits after time out

2007-07-27 Thread Lakshmi Sailaja
Thanks for the input. Will try it out and see!! Thanks & Regards, Lakshmi 952-833-1220 -Original Message- From: Chas Owens [mailto:[EMAIL PROTECTED] Sent: Friday, July 27, 2007 12:47 PM To: [EMAIL PROTECTED] Cc: beginners@perl.org Subject: Re: Telnet exits after time out On 7/2

Re: Telnet exits after time out

2007-07-27 Thread Chas Owens
On 7/27/07, Lakshmi Sailaja <[EMAIL PROTECTED]> wrote: snip > What is the solution? Is there a way that I don't specify the time out value > and let it run until the exe completes its execution? snip You should never disable the timeout. If you do then there is a chance your program will hang for

Re: Telnet question in Perl

2007-03-27 Thread Tom Phoenix
On 3/26/07, Dukelow, Don <[EMAIL PROTECTED]> wrote: I'm using Net::Telnet in my Perl script and I can get through the user login ok. But when I try to "sudo" to root I can't get there. Any ideas? It might be that sudo is (mis-)configured not to allow you root access. But I suspect you've jus

Re: Telnet question in Perl

2007-03-27 Thread jm
no difference! Its only after I sudo to root thaat I have this problem. Don Dukelow -Original Message- From: jm [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 27, 2007 12:01 PM To: Beginners List Subject: Re: Telnet question in Perl i can't find any reference to a "cmw" opt

Re: Telnet question in Perl

2007-03-27 Thread jm
"@VENDER\n"; Don't work where as they did when I was just loged in as myself. The Input_log file says the command was exicuted but the array didn't pick it up. Don Dukelow -Original Message- From: jm [mailto:[EMAIL PROTECTED] Sent: Monday, March 26, 2007 5:13 PM To: b

Re: Telnet question in Perl

2007-03-26 Thread jm
e "/"s I'm not sure which one you mean but I was tring all kinds of thinks to get it to work. That is just what I ended up with. Don Dukelow -Original Message----- From: jm [mailto:[EMAIL PROTECTED] Sent: Monday, March 26, 2007 4:22 PM To: beginners@perl.org Subject: Re: Teln

Re: Telnet question in Perl

2007-03-26 Thread jm
simplest questions first... is "sudo" a valid command on that particular system? if so, is "sudo su -" a valid syntax in that environment? is "/Password/" a valid prompt being returned by that system? should the "/"s be a part of the prompt text? i've never included "/"s in my expected returns u

RE: :Telnet Updating Prompt?

2005-10-11 Thread Thomas Bätzler
Bastian Angerstein <[EMAIL PROTECTED]> asked: [net::Telnet] > Is it possible to update the internal Object-attribute ($last_prompt)? >From the documentation: last_prompt - last prompt read $string = $obj->last_prompt; $prev = $obj->last_prompt($string); With no argument this metho

Re: telnet problems

2003-08-21 Thread James Edward Gray II
On Thursday, August 21, 2003, at 06:15 AM, Miguel Angel Morales wrote: Hi all! I'm programming a tunnelbroker with perl. We are already able to create tunnels by means of a telnet session using a telnet library of perl, but, when I try to delete the tunnel (delete -r tunnel tb-008, for exampl

Re: :Telnet

2003-08-17 Thread SilverFox
David Storrs wrote: > On Mon, Aug 11, 2003 at 09:42:40AM -0400, Stephen Gilbert wrote: >> > -Original Message- >> > From: SilverFox [mailto:[EMAIL PROTECTED] >> > Sent: Sunday, August 10, 2003 4:58 PM >> > To: [EMAIL PROTECTED] >> > Subject: Net::Telnet >> > >> > >> > hey anyone know how

RE: :Telnet - Variable won't change

2003-08-14 Thread Dan Muey
> Hey can someone help me figure out why the value of > $file_exists won't > change even when the file is mssing Thx. > $file_exists = $t->cmd ("perl -e 'print 1 if (-s > \"$newdir[$x]\")'") or > warn "Unable to execute: $!\n"; You probably need to escape the single quotes as well. Try tha

Re: :Telnet

2003-08-14 Thread David Storrs
On Mon, Aug 11, 2003 at 09:42:40AM -0400, Stephen Gilbert wrote: > > -Original Message- > > From: SilverFox [mailto:[EMAIL PROTECTED] > > Sent: Sunday, August 10, 2003 4:58 PM > > To: [EMAIL PROTECTED] > > Subject: Net::Telnet > > > > > > hey anyone know how to check if a file exists usin

RE: :Telnet

2003-08-14 Thread Stephen Gilbert
> -Original Message- > From: SilverFox [mailto:[EMAIL PROTECTED] > Sent: Sunday, August 10, 2003 4:58 PM > To: [EMAIL PROTECTED] > Subject: Net::Telnet > > > hey anyone know how to check if a file exists using the Telnet module? > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For a

RE: telnet problems

2003-07-25 Thread NYIMI Jose (BMB)
Type y :-) No, i don't know how to do that ... -Original Message- From: Miguel Angel Morales [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 12:56 PM To: [EMAIL PROTECTED] Subject: telnet problems Hi all! I open a telnet session to a router for creating IPv6 tunnels. The creating

Re: Telnet using IO:Socket module

2003-01-18 Thread Randal L. Schwartz
> "Pankajwarade" == Pankajwarade <[EMAIL PROTECTED]> writes: Pankajwarade> I am tring to use IO::Socket module in order to execute Pankajwarade> the commands on remote server. Perl script connects Pankajwarade> remote server on port 23, and waits for login prompt Pankajwarade> forever. It re

Re: Telnet using IO:Socket module

2003-01-18 Thread Tim Musson
Hey david, My MUA believes you used KNode/0.7.1 to write the following on Friday, January 17, 2003 at 4:54:23 PM. d> Telent doesn't use the tcp protocol, it uses TELNET. Telnet does use TCP. In the TCP/IP world, just about everything uses either TCP or UDP (a couple I can think of that

Re: Telnet using IO:Socket module

2003-01-17 Thread kevin reynolds
et;. That might work. http://search.cpan.org/author/RSE/lcwa-1.0.0/lib/io/IO/Socket/INET.pm Kevin From: david <[EMAIL PROTECTED]> Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: Telnet using IO:Socket module Date: Fri, 17 Jan 2003 13:54:23 -0800 Pankajwarade wrote: >

Re: Telnet using IO:Socket module

2003-01-17 Thread david
Pankajwarade wrote: > my $sock = new IO::Socket::INET ( > Proto => 'tcp', > PeerAddr=> 10.38.3.3, > PeerPort=> 23, > ) or > > die "

Re: :Telnet question

2002-08-12 Thread drieux
On Monday, August 12, 2002, at 11:21 , Joe Mecklin wrote: > Thanks Drieux, > > You put me on the right track. Working through your suggestion made me > realize I also needed a sleep between seeing the prompt and sending the > data (something also required in the Expect script but inconveniently

Re: :Telnet question

2002-08-12 Thread Joe Mecklin
Thanks Drieux, You put me on the right track. Working through your suggestion made me realize I also needed a sleep between seeing the prompt and sending the data (something also required in the Expect script but inconveniently forgotten ). I've been able to successfully connect multiple concur

Re: :Telnet question

2002-08-12 Thread drieux
On Monday, August 12, 2002, at 09:48 , Joe Mecklin wrote: > I had not tried that because login() requires "login:" or "username:" as > the prompt (as I read the documentation); my prompt is "User ID:". I > did go ahead and try it just now and it doesn't work either... doesn't > even send out th

RE: :Telnet question

2002-08-12 Thread Joe Mecklin
I had not tried that because login() requires "login:" or "username:" as the prompt (as I read the documentation); my prompt is "User ID:". I did go ahead and try it just now and it doesn't work either... doesn't even send out the username since it doesn't see the expected prompt. I do appreciat

RE: :Telnet question

2002-08-12 Thread Akens, Anthony
Have you tried using $ion->login($username, $passwd); Instead of doing it the hard way? Here's a sample script I use with net::telnet that works just fine... Might want to try modifying it. I use a hosts file, because my script hits a number of machines. The only bit that might be confusing

Re: Telnet Program

2002-05-23 Thread drieux
On Thursday, May 23, 2002, at 01:01 , Felix Geerinckx wrote: > on Thu, 23 May 2002 19:51:07 GMT, Drieux wrote: > >> the trick of course is that to an arbitrary port you may >> really want to be at the > > You can specify a port number in Net::Telnet->new(...) oh heavens yes... but that would be

Re: Telnet Program

2002-05-23 Thread Felix Geerinckx
on Thu, 23 May 2002 19:51:07 GMT, Drieux wrote: > the trick of course is that to an arbitrary port you may > really want to be at the You can specify a port number in Net::Telnet->new(...) -- felix -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTE

RE: Telnet Program

2002-05-23 Thread Beau E. Cox
Jason - You might want to grab Net::Telnet from CPAN. This snippet is from the documentation: use Net::Telnet (); $t = new Net::Telnet (Timeout => 10, Prompt => '/bash\$ $/'); $t->open("sparky"); $t->login($username, $passwd); @lines = $t->cmd("/usr/bin/who"); print @lines;

Re: Telnet Program

2002-05-23 Thread Felix Geerinckx
on Thu, 23 May 2002 19:37:47 GMT, Jason Frisvold wrote: > I need to write a program that telnets to a specific port and logs all > the output to a file. Is there an easy way to do this in perl? I tried > this via the command line (telnet 1.2.3.4 23 > my.log &) but it > apparently buffers every

Re: Telnet Program

2002-05-23 Thread drieux
On Thursday, May 23, 2002, at 12:37 , Jason Frisvold wrote: > I need to write a program that telnets to a specific port and logs all > the output to a file. Is there an easy way to do this in perl? I tried > this via the command line (telnet 1.2.3.4 23 > my.log &) but it > apparently buffers

Re: telnet?

2002-05-10 Thread Felix Geerinckx
on Fri, 10 May 2002 11:58:14 GMT, [EMAIL PROTECTED] (Perl Hunter) wrote: > Is there any sample code or way of "opening a telnet > session with other username&password and then execute > some commands like 'ls, ps, etc.' "? use Net::Telnet; See

Re: telnet...???

2002-03-25 Thread jbajin
You can use the Use::Telnet(); function.. . Here's a snippit of code: $t = new Net::Telnet (Timeout => 10, Prompt => '/[>]$/', Errmode => "return" ); $t->open("$hostname.db"); if ($t->login($username, $passwd) ) { @lines = $t->cmd("

Re: telnet...???

2002-03-25 Thread subbu
thanq Mr sudharsan, but can we use only Expect module to do that.. pl reply regards keshav - Original Message - From: Sudarsan Raghavan <[EMAIL PROTECTED]> To: subbu <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Monday, March 25, 2002 1:54 AM Subject: Re: telne

Re: telnet...???

2002-03-25 Thread Sudarsan Raghavan
Take a look at Net::Telnet on cpan subbu wrote: > hi to all.. > can we use perl expect module to telnet to a specified > machine and to execute a specified command on a > remote machine..? > > regards > keshav -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMA

RE: :telnet and read eof error

2002-03-13 Thread Craig Williams
solved my own problem reinstalled the net::telnet module, somebody screwed with the module code -Original Message- From: Craig Williams [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 12:31 PM To: Beginners@Perl. Org (E-mail) Subject: net::telnet and read eof error In m

RE: :Telnet to change password

2001-11-01 Thread Bob Showalter
> -Original Message- > From: Stephen M [mailto:[EMAIL PROTECTED]] > Sent: Thursday, November 01, 2001 8:04 AM > To: [EMAIL PROTECTED] > Subject: Net::Telnet to change password > > > Hi, > > I have lots of unix machines to change the password on the > root account, the following code I

Re: telnet problem

2001-09-22 Thread Troy Denkinger
Saran, On Friday 21 September 2001 15:33, Kumar wrote: > I have several files written in perl and batch files. Here is the problem > i'm facing, i was unbale to kickoff builds by telneting it. Its trying to > access local files rather than to the files in the server. when ever i > type in the loc

Re: Telnet ..... send control characters in oct or hex?

2001-08-12 Thread Karthik Krishnamurthy
As an aside ^] needs to be handled by the telnet client itself. /kk On Thu, Aug 09, 2001 at 01:21:49PM -0700, Atul Vohra wrote: > Hi, > > I am using Telnet.pm module where I telnet to a router successfully. Now, I would >like to send some control characters like "ctrl]". Is there a way to send

RE: Telnet ..... send control characters in oct or hex?

2001-08-09 Thread Bob Showalter
> -Original Message- > From: Atul Vohra [mailto:[EMAIL PROTECTED]] > Sent: Thursday, August 09, 2001 4:22 PM > To: [EMAIL PROTECTED] > Subject: Telnet . send control characters in oct or hex? > > > Hi, > > I am using Telnet.pm module where I telnet to a router > successfully. Now,

Re: :Telnet

2001-07-03 Thread Vrunda Prabhu
Thanks, I will look at the documents you point to right away. Even though the task may not be for abeginner, I do not have too much of a choice, so I will dig in. Thanks Vrunda On 3 Jul 2001 [EMAIL PROTECTED] wrote: > > "Prabhu" == Prabhu, Vrunda P (UMC-Student) <[EMAIL PROTECTED]> writes:

Re: :Telnet

2001-07-03 Thread Vrunda Prabhu
asily? > > > > > > > > > > > > Thanks for any help in advance. > > > > Vrunda > > > > > > > > On Mon, 25 Jun 2001, Gary Stainburn wrote: > > > > > Hi Vrunda, > > > > > > > > > > I've just re-r

Re: :Telnet

2001-07-03 Thread Gary Stainburn
> > > > > > protocol. To do that you need to use port 110. > > > > > > > > Before trying to do it with your script tho', try doing it > > directly > > > by > > > > > > calling the telnet program. If that

Re: :Telnet

2001-06-29 Thread Gary Stainburn
s on most unix systems \windows\services under > > windows. > > > > Gary > > > > > > On Friday 22 June 2001 4:39 pm, Prabhu, Vrunda P (UMC-Student) > > wrote: > > > > Gary: > > > > I used port 23 with the same outcome: read timed out. >

Re: :Telnet

2001-06-28 Thread Gary Stainburn
: > > > I used port 23 with the same outcome: read timed out. > > > > > > John Edwards (thanks very much John) suggested a document at : > > > http://www.perlfect.com/articles/telnet.shtml > > > > > > which seems to be pretty good, an dmight have so

Re: :Telnet

2001-06-27 Thread Vrunda Prabhu
w.perlfect.com/articles/telnet.shtml > > > > which seems to be pretty good, an dmight have solutions. > > Vrunda > > > > -Original Message----- > > From: Gary Stainburn > > To: Prabhu, Vrunda P (UMC-Student); '[EMAIL PROTECTED] ' > >

RE: Telnet Tucow's ?

2001-06-27 Thread John Edwards
If you're starting to learn Perl. Take a look at this site. It might be a better starting point than trying to write a script to telnet to a website. http://www.netcat.co.uk/rob/perl/win32perltut.html HTH John -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent:

Re: :Telnet

2001-06-25 Thread Gary Stainburn
unda P (UMC-Student); '[EMAIL PROTECTED] ' > Sent: 6/22/01 10:31 AM > Subject: Re: :Telnet > > Hi, > > why are you telnetting to port 80? That's the http port. > To use telnet, use port 23, which I think is the default anyway. > > Gary > > On Friday 2

RE: :Telnet

2001-06-22 Thread Tom Yarrish
pt=>'/>$ $/i'); > $telnet->open('...'); > $telnet->login('...', '...'); > print $telnet->cmd('who'); > > (I have deleted host, user and passwd). > > Could anyone suggest what I should change? > Thanks very much. &

RE: :Telnet

2001-06-22 Thread Prabhu, Vrunda P (UMC-Student)
change? Thanks very much. Vrunda [ Wrote 8 lines ] [c151@myclass router]ic./newtry.cgi -Original Message- From: John Edwards To: 'Prabhu, Vrunda P (UMC-Student)'; '[EMAIL PROTECTED] ' Sent: 6/22/01 10:18 AM Subject: RE: :Teln

Re: :Telnet

2001-06-22 Thread Gary Stainburn
Hi, why are you telnetting to port 80? That's the http port. To use telnet, use port 23, which I think is the default anyway. Gary On Friday 22 June 2001 4:07 pm, Prabhu, Vrunda P (UMC-Student) wrote: > I too have questions on the same topic - Net::Telnet. I tried the > following code: (I h

RE: :Telnet

2001-06-22 Thread John Edwards
This might be of use to you http://www.perlfect.com/articles/telnet.shtml -Original Message- From: Prabhu, Vrunda P (UMC-Student) [mailto:[EMAIL PROTECTED]] Sent: 22 June 2001 16:07 To: '[EMAIL PROTECTED] ' Subject: RE: :Telnet I too have questions on the same topic - Net::

RE: :Telnet

2001-06-22 Thread Prabhu, Vrunda P (UMC-Student)
I too have questions on the same topic - Net::Telnet. I tried the following code: (I have deleted the hostname, username and passwd), and get the error: read timed-out at ./teltry.cgi line 13 #!/usr/bin/perl my ($hostname, $line, $passwd, $pop, $username); $hostname="..."; $username="...

Re: Telnet

2001-06-20 Thread Joel Divekar
Thanks Brett Will surely download CygWin32... anyway I wanted to install it for Perl Regards Joel At 10:44 AM 6/20/2001 -0400, Brett W. McCoy wrote: >On Wed, 20 Jun 2001, SAWMaster wrote: > > > Yes and no. You cannot do it with telnet, but you can get what you want by > > using an x-term clie

Re: Telnet

2001-06-20 Thread Joel Divekar
Thanks SAWMaster (Not your real name I suppose) Will surely give it a try but I am looking for a free software Regards Joel At 09:25 AM 6/20/2001 -0500, SAWMaster wrote: >Yes and no. You cannot do it with telnet, but you can get what you want by >using an x-term client and setting up the ser

Re: Telnet

2001-06-20 Thread Joel Divekar
Thanks Derek Regards Joel At 03:01 PM 6/20/2001 +0100, Derek Harding wrote: >On Saturday 16 June 2001 07:28, Joel Divekar wrote: > > Hi > > > > Hey can we run KDE or Xwindows by telneting to Linux servers ??? > > > > Regards > >Not by telnet but certainly it is possible to run "dumb" terminals

Re: Telnet

2001-06-20 Thread Brett W. McCoy
On Wed, 20 Jun 2001, SAWMaster wrote: > Yes and no. You cannot do it with telnet, but you can get what you want by > using an x-term client and setting up the server box to allow x connections. > One commercial example of an X-Term client for a windows box would be > X-Win32. Do a search on the

Re: Telnet

2001-06-20 Thread Dave Young
ummm, if you set the display variable correctly and have an Xserver running on the PC, sure you can. Why anyone would want to is beyond me.. use xterm for shell access and run any gui utils you like by hand. Running a window manager over the network isn't really a pleasant experience... $.02 U

Re: Telnet

2001-06-20 Thread SAWMaster
Yes and no. You cannot do it with telnet, but you can get what you want by using an x-term client and setting up the server box to allow x connections. One commercial example of an X-Term client for a windows box would be X-Win32. Do a search on the net for "X-Win32" and you'll find plenty of in

Re: Telnet

2001-06-15 Thread John Fox
Sorry to contribute to this off-topic thread, but I have useful information. Verily, on Thursday June 14, 2001, the Sainted Derek Harding spake: > What Javier says is very true about using ssh but if something happens to > lock up at the remote computer it can be hard to get out with ssh without

Re: Telnet

2001-06-15 Thread Derek Harding
What Javier says is very true about using ssh but if something happens to lock up at the remote computer it can be hard to get out with ssh without resorting to killing processes whereas, if the network is secure from peeking, one can end a telnet session with the "Ctrl-]" combination. I'm not

RE: Telnet

2001-06-14 Thread Doug Johnson
Telnet is a method used to communicate to another machine. You use telnet to access a terminal window on a remote machine. It is as if you were sitting at the console of that machine (character based). You cannot however transfer files through telnet. You would use ftp to do that with. It is some

RE: Telnet

2001-06-14 Thread Sally
Thanks guys, that's exactly what I needed to know (the lack of technical terms was fab!!!) -Original Message- From: n6tadam [mailto:[EMAIL PROTECTED]] Sent: 14 June 2001 14:21 To: Sally; perl Subject: Re: Telnet Hi, Telnet, gives you the ability to access a remote machine acr

Re: Telnet

2001-06-14 Thread EDonnelly
et.sch.uk> cc: Subject: Re: Telnet

Re: Telnet

2001-06-14 Thread n6tadam
Hi, Telnet, gives you the ability to access a remote machine across a network, however, I would advise against using telnet. Instead, I recommend using SSH (Secure SHell), which is much more secure. Regards, Thomas Adam - Original Message - From: Sally <[EMAIL PROTECTED]> To: perl <[EM