MD5 crypting

Brian McKee brian.mckee at
Mon Apr 27 17:35:57 UTC 2009

On Mon, Apr 27, 2009 at 1:12 PM, NoOp <glgxg at> wrote:
> On 04/26/2009 12:29 PM, Arda Eden wrote:
>> The other interesting thing is every encryption with grub-md5-crypt for the
>> same password generates different hashes.
> It should give you different hashes each time.

Can you explain why it does that?  (I've confirmed you are indeed correct)
Like the OP I would have thought it would be the same each time.
For instance - this is the same every time.
>  echo '<?php echo crypt("password", "xy") ?>' | php
>  xyAjYtmfRYx/.

Is there a salt in there somewhere?  If so, how does grub know what the salt is?

Hopefully this doesn't qualify as thread jacking - I think the OP has
the same question.


More information about the ubuntu-users mailing list