View previous topic :: View next topic |
Author |
Message |
trouby Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/gallery/BaldursGate/baldursgate_faldorn.gif)
Joined: 04 Oct 2003 Posts: 168
|
Posted: Tue Dec 23, 2003 12:35 pm Post subject: Md5 password generator |
|
|
Hey,
Is there any tool to create a hashed MD5 string ? Ldap config file can use {MD5} with MD5 string as its password and I have nothing to create that HASHED password with,
Thanks. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
aridhol Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
Joined: 20 Jan 2003 Posts: 509 Location: Stockholm, Sweden
|
Posted: Tue Dec 23, 2003 12:49 pm Post subject: |
|
|
A quick googling on your topic title gave me this:
http://www.trilug.org/~jeremy/md5.php _________________ 72 of Pitcairn Islands 49 inhabitants use Seti@Home
"If you buy a DVD you have a copy. If you want a backup copy you buy another one."
"Anyone who is capable of getting themselves made President should on no account be allowed to do the job." |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
thodi Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
![](images/avatars/20800928953faba3e39e6f6.png)
Joined: 20 Oct 2003 Posts: 92 Location: Emden, Germany (Old Europe)
|
Posted: Tue Dec 23, 2003 12:54 pm Post subject: Re: Md5 password generator |
|
|
trouby wrote: | Is there any tool to create a hashed MD5 string ?
|
md5sum, should be in coreutils.
Code: |
echo password | md5sum -
|
_________________ Hier fliegen gleich die Löcher aus dem Käse
Jabber: thodi@jabber.org |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
trouby Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/gallery/BaldursGate/baldursgate_faldorn.gif)
Joined: 04 Oct 2003 Posts: 168
|
Posted: Tue Dec 23, 2003 1:44 pm Post subject: |
|
|
fine, thanks. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
trouby Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/gallery/BaldursGate/baldursgate_faldorn.gif)
Joined: 04 Oct 2003 Posts: 168
|
Posted: Tue Dec 23, 2003 4:44 pm Post subject: |
|
|
md5sum works fine but it doesn't fit the {MD5}(hashed MD5 string) that slapd.conf expects, anyone? |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
thodi Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
![](images/avatars/20800928953faba3e39e6f6.png)
Joined: 20 Oct 2003 Posts: 92 Location: Emden, Germany (Old Europe)
|
Posted: Tue Dec 23, 2003 5:58 pm Post subject: |
|
|
Code: |
echo password | md5sum - | perl -ne '/(\w+)/ && print "{MD5}$1"'
|
_________________ Hier fliegen gleich die Löcher aus dem Käse
Jabber: thodi@jabber.org |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
zhenlin Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
Joined: 09 Nov 2002 Posts: 1361
|
Posted: Wed Dec 24, 2003 3:31 am Post subject: |
|
|
Use the correct tool for the job!
Code: | $ slappasswd -h '{MD5}'
New password:
Re-enter new password:
{MD5}bx7QAqtVlYWQFOvwlRUi2Q==
|
SHA1 hashing is stronger though, I think by 32 bits. (160 bits of hash space!) |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
trouby Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/gallery/BaldursGate/baldursgate_faldorn.gif)
Joined: 04 Oct 2003 Posts: 168
|
Posted: Wed Dec 24, 2003 10:03 am Post subject: |
|
|
That's exactly what I needed!
Well, MD5 is enough for me since the ldap is anyway not accessible for anyone but for several internal applications.
Thanks. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
garfield n00b
![n00b n00b](/images/ranks/rank_rect_0.gif)
Joined: 03 Oct 2003 Posts: 14 Location: Aalborg, Denmark
|
Posted: Wed Dec 31, 2003 4:17 pm Post subject: |
|
|
thodi wrote: | Code: |
echo password | md5sum - | perl -ne '/(\w+)/ && print "{MD5}$1"'
|
|
This will NOT give the md5sum for password since echo sends a newline along with password to md5sum. You'll have to use the -n option with echo to get the correct password. Without the Perl stuff the code will be
Code: |
echo -n password | md5sum
|
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|