Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Perl NIS authentication

by idsfa (Vicar)
on Jun 29, 2007 at 13:39 UTC ( #624092=note: print w/ replies, xml ) Need Help??


in reply to Perl NIS authentication

Just thought that I would point out that this is a bad idea. The passwords you feed it on the command line will be visible as plain text in your shell's history file as well as in the process listing (ps). It would be much safer to feed sensitive information via STDIN.

Also, your "solution" code can fail quite easily. Consider what happens for the users alice and malice.

You may want to look at Authen::Simple::NIS.

use Authen::Simple::NIS; my $nis = Authen::Simple::NIS->new; if ( $nis->authenticate( $username, $password ) ) { # successfull authentication }

The intelligent reader will judge for himself. Without examining the facts fully and fairly, there is no way of knowing whether vox populi is really vox dei, or merely vox asinorum. — Cyrus H. Gordon


Comment on Re: Perl NIS authentication
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://624092]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (14)
As of 2014-10-31 20:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (223 votes), past polls