Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Digest::MD5 question

by Thelonius (Priest)
on Jun 08, 2006 at 23:41 UTC ( [id://554386]=note: print w/replies, xml ) Need Help??


in reply to Digest::MD5 question

use Digest::MD5 'md5_hex'; my ($user, $domain, $password) = @ARGV; my $digest = md5_hex("$user:$domain:$password"); print "Digest = $digest\n";
You need to include the username, domain, and password, in that order, separated by colons.

If the digest were just of the password, someone could create digests of all dictionary words and use them to find out the passwords of all users at the same time. By including the user name, you have to do the dictionary attack separately for each user.

Including the domain helps to protect users who have passwords on several systems, or generic user names like "root", "apache", etc.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (4)
As of 2024-04-19 13:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found