[pgsql-jp: 31097] cryptの認証について

泉田隼人 hayato @ po1.dti2.ne.jp
2003年 9月 21日 (日) 16:42:56 JST


泉田です。


前回に引き続きまたpg_hba.confで質問があります。
testというデータベースにtestというユーザを作り、
pg_hba.confを下記のように修正しました。

[postgres @ rh73 data]$ cat pg_hba.conf
# TYPE  DATABASE    USER        IP-ADDRESS        IP-MASK           METHOD
host    test        all         192.168.1.0       255.255.255.0       crypt
local   test        all                                             crypt
host    all         all         192.168.1.3       255.255.255.255   trust
local   all         all                                             trust
host    all         all         127.0.0.1         255.255.255.255   trust
host    all         all         192.168.0.1       255.255.255.255   trust

※postgres ユーザにパスワードをpostgresとして、
※test     ユーザにパスワードをtest  と設定しました。

そこで
[postgres @ rh73 data]$ psql -U test test
Password:test
と実行をすると
psql: FATAL:  Password authentication failed for user "test"
というようなエラーがでて、ログインすることが出来ませんでした。

そこで別ユーザでログインし、pg_shadowを確認したところ
 usename  | usesysid | usecreatedb | usesuper | usecatupd |               passwd  
              | valuntil | useconfig
----------+----------+-------------+----------+-----------+---------------------
----------------+----------+-----------
 test     |      105 | f           | f        | f         | 
md505a671c66aefea124cc08b76ea6d30bb |          |
 postgres |        1 | t           | t        | t         | 
md5fcb6f3ee5171ad22f06ddfd4c2fbef81 |          |

の様になり、パスワードが設定されていることは確認が出来ました。


私の認識はcryptで認証し、alter userでパスワードを変更したので
認証されると思っていたのですが認証されませんでした。
何かおかしい設定をしているでしょうか?

configureオプションは
./configure --enable-multibyte=EUC_JP \
--with-tcl \
--with-odbc
ですが、特に問題ないと思います。




pgsql-jp メーリングリストの案内