[H-GEN] md5sum generation

Michael Anthon michael at anthon.net
Mon Mar 27 15:42:54 EST 2006


On 3/27/06, rickp at suntech.net.au <rickp at suntech.net.au> wrote:
>
> We would probably prepare the sql file using a spreadsheet with the data
> dumped from another database including the plan language password which
> then needs to be encrypted.  Columns with the sql database commands would
> be inserted and then the whole lot dumped as text to be executed.
>

One possibility nobody has mentioned yet is to do the inserts using the
plain text password and then do the md5 using the databse itself.  You don't
mention which DB you are using but mysql has an md5 function (can't find one
in the postgresql docs though).

If you have plain text passwords in a field called "password" then doing
this...

update yourtable set password = md5(password)

will change them all to md5... you might want to add a where clase to
exclude ones that are already MD5 though!

Cheers,
Michael
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.humbug.org.au/pipermail/general/attachments/20060328/6ad66cbb/attachment.html>


More information about the General mailing list