Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 269B52E00F9 for ; Fri, 22 Feb 2008 18:40:41 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 49815-04 for ; Fri, 22 Feb 2008 18:40:33 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from smtpoutm.mac.com (smtpoutm.mac.com [17.148.16.71]) by postgresql.org (Postfix) with ESMTP id 763472E00F6 for ; Fri, 22 Feb 2008 18:40:38 -0400 (AST) Received: from mac.com (asmtp004-s [10.150.69.67]) by smtpoutm.mac.com (Xserve/smtpout008/MantshX 4.0) with ESMTP id m1MMebQk029637 for ; Fri, 22 Feb 2008 14:40:37 -0800 (PST) Received: from [192.168.2.24] (p579e993f.dip.t-dialin.net [87.158.153.63]) (authenticated bits=0) by mac.com (Xserve/asmtp004/MantshX 4.0) with ESMTP id m1MMeX0O029464 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Fri, 22 Feb 2008 14:40:35 -0800 (PST) Message-Id: From: Asche To: pgsql-admin@postgresql.org Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Subject: Strange Authentication Problem Mime-Version: 1.0 (Apple Message framework v919.2) Date: Fri, 22 Feb 2008 23:40:32 +0100 X-Mailer: Apple Mail (2.919.2) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200802/290 X-Sequence-Number: 28364 Hi, i have a strange authentication problem with postgresql v8.3 on mac os x server (10.5). my pg_hba.conf contains only the following 4 entries: local all all md5 host all all 127.0.0.1/32 md5 host all all ::1/128 md5 host all all 0.0.0.0/0 md5 if i connect from local machine with 'psql -U testuser testdb' or 'psql -h localhost -U testuser testdb' psql prompt me for a password and i get in - looks good so far. next step was to try connect from another machine on another network. with 'psql -h -U testuser testdb' i get a prompt for a password and if i give the correct password i can login and do something more or less useful ;-) but now my problem. if i connect with the full qualified domain-name to the remote machine, e.g. 'psql -h testdb.example.com -U testuser testdb' i get no password prompt, instead psql logs me in without the need of a password and i have full access to the db! hm. it seems to be a problem with md5. if i change the last line in pg_hba.conf to the following: host all all 0.0.0.0/0 reject and reload the servers configuration, then it will reject my connection if i use ip-address or the domain-name of the remote machine. if i change it back and reload the configuration, then i can login without password again when i use the domain-name of the server and can login only with password when using the ip-address. if i try the -W switch of psql and connect with domain-name i get the password-prompt, but i can simply press and i get in. is it my fault? can somebody confirm this behaviour on other postgresql installations? any hints or suggestions what i can try to fix this strange problem? jan