pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Rob van der Linde <robvdl@paradise.net.nz>
To: pgsql-admin@postgresql.org
Subject: pg_hba.conf stuff
Date: Thu, 01 Mar 2007 13:43:41 +1300
Message-ID: <1172709821.21015.16.camel@athlon64> (raw)

Hi all,

I have a server (Ubuntu 6.10 to be exact) running PostgresQL 8.1.4.

On that server I have a user account, called "ynui", and I also have a
postgres user called "ynui", they have the same password. Now the
server's IP is 192.168.0.1

My main postgres conf has in it:

listen_addresses = 'localhost,192.168.0.1'

my pg_hba.conf is:

# "local" is for Unix domain socket connections only
local   all         all                               md5
# IPv4 local connections:
host    all         all         127.0.0.1/32          md5
# IPv6 local connections:
host    all         all         ::1/128               md5
# Internal network
host    all         all         192.168.0.0/24        md5

Now I have a client PC 192.168.0.10, it's also running Linux and the
unix account name on this machine is rob. I have the postgres client
installed on this machine and am connecting like this:

psql -h 192.168.0.1 -U ynui

Now my problem is, because the server has on it a user account "ynui"
and postgres also has a user called "ynui", with the same password, it
goes straight in, without asking for the password at all!!!

This is even though I specifically configured the "Internal network"
section in my pg_hba.conf file for "md5", and this "ynui" unix user is
actually on the server, not on the client pc. Then why does it still go
straight in from the client PC without asking for the password for the
"ynui" user?

Any ideas? is there any way to prevent this automatic login, or is the
only way to have the unix "ynui" user and postgres "ynui" user no the
server to have a different password? I would prefer them not to have
different passwords however if possible.

Any ideas? any help would be appreciated.




view thread (4+ messages)  latest in thread

Message-ID: <1172709821.21015.16.camel@athlon64>
Permalink:  ../1172709821.21015.16.camel@athlon64/
Also on:    postgresql.org/message-id/1172709821.21015.16.camel@athlon64

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: robvdl@paradise.net.nz
  Subject: Re: pg_hba.conf stuff
  In-Reply-To: <1172709821.21015.16.camel@athlon64>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox