Revision 5797,
544 bytes
checked in by wmerlotto, 13 years ago
(diff) |
Ticket #2557 - Primeira versao do novo instalador do Expresso
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | #!/usr/bin/perl |
---|
2 | |
---|
3 | # Perl code to create and print MD5 hash of password |
---|
4 | # shamelessly stolen from the openLDAP Faq-O-Matic |
---|
5 | # written 19-Jul-01 by Ed Truitt |
---|
6 | # Modificado em 15/03/2010 por William Fernando Merlotto <william@prognus.com.br> |
---|
7 | |
---|
8 | $pass = $ARGV[0]; |
---|
9 | chomp($pass); |
---|
10 | |
---|
11 | use Digest::MD5; |
---|
12 | use MIME::Base64; |
---|
13 | $ctx = Digest::MD5->new; |
---|
14 | $ctx->add($pass); |
---|
15 | $hashedMD5Passwd = '{MD5}' . encode_base64($ctx->digest,''); |
---|
16 | $hexpass = $ctx->hexdigest; |
---|
17 | $b64pass = $ctx->b64digest; |
---|
18 | #print $hexpass . "\n"; |
---|
19 | #print $b64pass . "\n"; |
---|
20 | print $hashedMD5Passwd . "\n"; |
---|
Note: See
TracBrowser
for help on using the repository browser.