From: | Gerardo Herzig <gherzig(at)fmed(dot)uba(dot)ar> |
---|---|
To: | postgres list <pgsql-sql(at)postgresql(dot)org> |
Subject: | create user xxx with md5 string? |
Date: | 2009-12-03 18:05:02 |
Message-ID: | 4B17FDCE.6030200@fmed.uba.ar |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Hi all. Im triyng, with no success, to create a user, and set the
password with a md5 string.
I did this:
comechingon:~ # echo -n 123 | md5sum
202cb962ac59075b964b07152d234b70 -
Ok, so then
test=# CREATE USER foobar ENCRYPTED PASSWORD
'md5202cb962ac59075b964b07152d234b70'; --I have to add 'md5' at the
begging of the string
CREATE ROLE
test=# SELECT * from pg_shadow where usename='foobar';
usename | usesysid | usecreatedb | usesuper | usecatupd |
passwd | valuntil | useconfig
---------+----------+-------------+----------+-----------+-------------------------------------+----------+-----------
foobar | 3250592 | f | f | f |
md5202cb962ac59075b964b07152d234b70 | |
(1 row)
test=# \c test foobar
Password for user foobar: [123, off course]
FATAL: password authentication failed for user "foobar"
Previous connection kept
test=# SHOW server_version;
server_version
----------------
8.3.6
Im wondering which my mystake is:
Using md5sum?
I do have 'md5' as validation mechanism in pg_hba.conf
Any hints?
Thanks!
Gerardo
From | Date | Subject | |
---|---|---|---|
Next Message | Gerardo Herzig | 2009-12-03 19:02:58 | Re: create user xxx with md5 string? |
Previous Message | Tom Lane | 2009-12-01 04:04:29 | Re: pg_restore followed by immediate VACUUM ANALYZE |