For Programmers: Free Programming Magazines  


Home > Archive > PERL Beginners > April 2004 > Password Changer and rexec help









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Password Changer and rexec help
Nandkishore.Sagi

2004-04-21, 1:35 pm

Hi All,

I am looking for some module which would help me in changing the
password on multiple boxes.I have the same login ID and would liketo
change the password for all of them using a Perl script.

Also I am looking for a perl module which can help me to logon
onto different boxes and execute a given script .Something more like
rexec.

Thanks a lot for your help.

Thanks and Regards
Nand Kishore S

Nand Kishore Sagi
ART Support Team
(612)-304-BART

Wc -Sx- Jones

2004-04-21, 2:40 pm

NandKishore.Sagi wrote:

> Also I am looking for a perl module which can help me to logon
> onto different boxes and execute a given script .Something more like
> rexec.
>


wrap-up some ssh commands inside Perl.
--
_Sx_ http://youve-reached-the.endoftheinternet.org/ _____
http://jaxpm.insecurity.org/
http://cis4dl.insecurity.org/
Wiggins D'Anconia

2004-04-21, 9:33 pm

WC -Sx- Jones wrote:
> NandKishore.Sagi wrote:
>
>
>
> wrap-up some ssh commands inside Perl.


Yikes, if you are going to go that route then consider Net::SSH::Perl,
has worked well for me in the past, once you get through the dependency
installation.

http://danconia.org
Wc -Sx- Jones

2004-04-21, 9:34 pm

Wiggins d'Anconia wrote:

>
>
> Yikes, if you are going to go that route then consider Net::SSH::Perl,
> has worked well for me in the past, once you get through the dependency
> installation.



Why yikes? There is another language called expect

http://expect.nist.gov/


(I am now rummaging around for my old flame-suit :)
--
_Sx_ http://youve-reached-the.endoftheinternet.org/ _____
http://jaxpm.insecurity.org/
http://cis4dl.insecurity.org/
Wiggins D'Anconia

2004-04-21, 10:31 pm

WC -Sx- Jones wrote:
> Wiggins d'Anconia wrote:
>
>
>
>
> Why yikes? There is another language called expect
>
> http://expect.nist.gov/
>
>
> (I am now rummaging around for my old flame-suit :)


Good idea, flame-suit. I am familar (meaning I have used it enough to
have gotten serious headaches from it) with expect, yikes. :-) Expect
for me is a next to last resort. Just too many things that can go wrong
and probably will.

http://danconia.org

John W. Krahn

2004-04-21, 11:30 pm

Wc -Sx- Jones wrote:
>
> Wiggins d'Anconia wrote:
>
>
> Why yikes? There is another language called expect
>
> http://expect.nist.gov/


Expect isn't a language, it is a program written in Tcl.

http://www.scriptics.com/


John
--
use Perl;
program
fulfillment
Wc -Sx- Jones

2004-04-22, 1:33 am

> Expect isn't a language, it is a program written in Tcl.


Hmmm, too tempting, but I will pass up this opportunity =)
--
_Sx_ http://youve-reached-the.endoftheinternet.org/ _____
http://jaxpm.insecurity.org/
http://cis4dl.insecurity.org/
Smoot Carl-Mitchell

2004-04-22, 2:34 am

On Thu, 22 Apr 2004 00:37:37 -0400
WC -Sx- Jones <WC-Sx-Jones@insecurity.org> wrote:

>
>
> Hmmm, too tempting, but I will pass up this opportunity =)


You may want to look at the Perl Expect module. It has similar
functionality as expect, but is IMHO a bit more rational.

BTW, expect is not written in Tcl. It uses Tcl syntax for flow control,
but it is a separate language. The Unix version is written in C as is
Tcl.

--
Smoot Carl-Mitchell
Systems/Network Architect
email: smoot@tic.com
cell: +1 602 421 9005
home: +1 480 922 7313
John W. Krahn

2004-04-22, 9:32 am

Smoot Carl-Mitchell wrote:
>
> On Thu, 22 Apr 2004 00:37:37 -0400
> WC -Sx- Jones <WC-Sx-Jones@insecurity.org> wrote:
>
>
> BTW, expect is not written in Tcl. It uses Tcl syntax for flow control,
> but it is a separate language. The Unix version is written in C as is
> Tcl.


From John Ousterhout at http://www.tcl.tk/doc/tclHistory.html

<QUOTE>
One of the people at the USENIX presentation was Don Libes of the
National Institute of Standards and Technology. Don had been wanting for
some time to build a program to automate interactive Unix applications,
but the project had stalled because it needed a good command language
and Don didn't have the time to build one. After hearing my talk, Don
rushed home, downloaded Tcl, built a wonderful application called
Expect, and wrote a paper on it in time for the submission deadline for
the next USENIX Conference. This whole process took just three ws.
Don made Expect freely available after presenting his paper in the
summer of 1990, and it became an instant hit among system
administrators. Expect was not only the first widely distributed Tcl
application, but for many years it was the most popular. Many of the
early Tcl users learned about it by using Expect.
</QUOTE>



John
--
use Perl;
program
fulfillment
Wc -Sx- Jones

2004-04-22, 10:31 am

John W. Krahn wrote:

>
> <QUOTE>
> One of the people at the USENIX presentation was Don Libes of the
> National Institute of Standards and Technology. Don had been wanting for

....

> summer of 1990, and it became an instant hit among system
> administrators. Expect was not only the first widely distributed Tcl
> application, but for many years it was the most popular. Many of the
> early Tcl users learned about it by using Expect.
> </QUOTE>


I wonder, had something similar happened to Larry in early Perl days
would Larry have stopped working on Perl -- Don Libes has more or less
stopped working on Expect.

Semantics of what is a language and what is not I will avoid.
--
_Sx_ http://youve-reached-the.endoftheinternet.org/ _____
http://jaxpm.insecurity.org/
http://cis4dl.insecurity.org/
Smoot Carl-Mitchell

2004-04-22, 2:34 pm

On Thu, 22 Apr 2004 05:55:00 -0700
"John W. Krahn" <krahnj@acm.org> wrote:

> <QUOTE>
> One of the people at the USENIX presentation was Don Libes of the
> National Institute of Standards and Technology. Don had been wanting
> for some time to build a program to automate interactive Unix
> applications, but the project had stalled because it needed a good
> command language and Don didn't have the time to build one. After
> hearing my talk, Don rushed home, downloaded Tcl, built a wonderful
> application called Expect, and wrote a paper on it in time for the
> submission deadline for the next USENIX Conference. This whole process
> took just three ws. Don made Expect freely available after
> presenting his paper in the summer of 1990, and it became an instant
> hit among system administrators. Expect was not only the first widely
> distributed Tcl application, but for many years it was the most
> popular. Many of the early Tcl users learned about it by using Expect.
> </QUOTE>


Thanks! Interesting bit of history I did not know. I am speculating Don
reimplemented expect in C for efficiency. It is an interesting build
process, since you do need the Tcl libraries to build the expect binary
on Unix systems. I went thru that process around 1992 when I first
discovered expect.

--
Smoot Carl-Mitchell
Systems/Network Architect
email: smoot@tic.com
cell: +1 602 421 9005
home: +1 480 922 7313
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com