On Saturday, April 20, 2002, at 04:28 , Mayank Ahuja wrote:
[..]
>
> Summary: Is there a PERL equivalent of rsh or remsh or rlogin on UNIX?

        my ($user , $hostname , $command_to_run ) = ThatFunkThatSetsTheses();
        my $cmd = "rsh -n -l $user $hostname $command_to_run";

        if( system($cmd) != 0) {
                do_our_Fail_To_System_CMD($cmd);
        }

the two functions

        ThatFunkThatSetsTheses()
        do_our_Fail_To_System_CMD()

are left as an exercise....

Why do the heavy lifting when you can do the simple?

this of course presumes that you can do that

        rsh -n -l That_User That_host hostname

because you have the .rhost file set up....

If you really wanted to get funky you could of course
run a mini-webServer on the hosts, with interesting
..htaccess alternatives - and write it as a CGI request

In which case you can avoid some of the issues of needing
to have the .rhost or host.equiv ....

You might want to think in terms of using ssh in lieu
of rsh/remsh....

ciao
drieux

---

the various funkadelics are in:


http://www.wetware.com/drieux/src/unix/perl/UglyCode.txt


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to