Re: Improving pg_hba.conf

Lists: Postg배트맨 토토SQL
From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Improving pg_hba.conf
Date: 2001-06-12 16:28:44
Message-ID: 200106121628.f5CGSid17592@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: Postg토토 베이SQL

We have the following item on TODO:

* Overhaul pg_hba.conf host-based authentication

Can people tell me what they want changed. I know we need the pg_shadow
password field encrypted in the table and I will work on that now.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026


From: Chris Bowlby <excalibur(at)hub(dot)org>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-06-12 19:07:05
Message-ID: Pine.BSF.4.33.0106121504330.69946-100000@hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: Postg배트맨 토토SQL

On Tue, 12 Jun 2001, Bruce Momjian wrote:

It might be work while to add restrictions in the config file for user
level locking, I realize that it can be done now...but having it in the
pg_hba.conf file could make it easier...

> We have the following item on TODO:
>
> * Overhaul pg_hba.conf host-based authentication
>
> Can people tell me what they want changed. I know we need the pg_shadow
> password field encrypted in the table and I will work on that now.
>
> --
> Bruce Momjian | http://candle.pha.pa.us
> pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
> + If your life is a hard drive, | 830 Blythe Avenue
> + Christ can be your backup. | Drexel Hill, Pennsylvania 19026
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

Chris Bowlby,
-----------------------------------------------------
Web Developer @ Hub.org.
excalibur(at)hub(dot)org
www.hub.org
1-902-542-3657
-----------------------------------------------------


From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Chris Bowlby <excalibur(at)hub(dot)org>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-06-12 19:08:01
Message-ID: 200106121908.f5CJ81Q05077@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers


I don't think that belongs in pg_hba.conf.

> On Tue, 12 Jun 2001, Bruce Momjian wrote:
>
> It might be work while to add restrictions in the config file for user
> level locking, I realize that it can be done now...but having it in the
> pg_hba.conf file could make it easier...
>
>
>
> > We have the following item on TODO:
> >
> > * Overhaul pg_hba.conf host-based authentication
> >
> > Can people tell me what they want changed. I know we need the pg_shadow
> > password field encrypted in the table and I will work on that now.
> >
> > --
> > Bruce Momjian | http://candle.pha.pa.us
> > pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
> > + If your life is a hard drive, | 830 Blythe Avenue
> > + Christ can be your backup. | Drexel Hill, Pennsylvania 19026
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 4: Don't 'kill -9' the postmaster
> >
>
> Chris Bowlby,
> -----------------------------------------------------
> Web Developer @ Hub.org.
> excalibur(at)hub(dot)org
> www.hub.org
> 1-902-542-3657
> -----------------------------------------------------
>
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026


From: mlw <markw(at)mohawksoft(dot)com>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-06-13 10:02:18
Message-ID: 3B273A2A.5030EF27@mohawksoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Bruce Momjian wrote:
>
> We have the following item on TODO:
>
> * Overhaul pg_hba.conf host-based authentication
>
> Can people tell me what they want changed. I know we need the pg_shadow
> password field encrypted in the table and I will work on that now.

Why doesn't postgres put the contents pg_hba.conf in a table? That way it comes
for free when you reinitialize and restore a database?


From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: mlw <markw(at)mohawksoft(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Re: Improving pg_hba.conf
Date: 2001-06-13 13:50:38
Message-ID: 200106131350.f5DDocm01604@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

> Bruce Momjian wrote:
> >
> > We have the following item on TODO:
> >
> > * Overhaul pg_hba.conf host-based authentication
> >
> > Can people tell me what they want changed. I know we need the pg_shadow
> > password field encrypted in the table and I will work on that now.
>
> Why doesn't postgres put the contents pg_hba.conf in a table? That way it comes
> for free when you reinitialize and restore a database?

The file has to be read by the postmaster and the postmaster has no
access to data tables for speed and security reasons.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026


From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Chris Bowlby <excalibur(at)hub(dot)org>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Re: Improving pg_hba.conf
Date: 2001-06-13 15:39:38
Message-ID: Pine.LNX.4.30.0106131738100.756-100000@peter.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Chris Bowlby writes:

> It might be work while to add restrictions in the config file for user
> level locking, I realize that it can be done now...but having it in the
> pg_hba.conf file could make it easier...

This would be mostly pointless since you can create locks with judicious
use of insert/update/delete. I don't suppose you want to let those
commands run without the appropriate locks.

--
Peter Eisentraut peter_e(at)gmx(dot)net http://funkturm.homeip.net/~peter


From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: mlw <markw(at)mohawksoft(dot)com>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Re: Improving pg_hba.conf
Date: 2001-06-13 15:40:11
Message-ID: Pine.LNX.4.30.0106131739450.756-100000@peter.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

mlw writes:

> Why doesn't postgres put the contents pg_hba.conf in a table? That way it comes
> for free when you reinitialize and restore a database?

Because if you hosed that table you would have hosed your entire
installation.

--
Peter Eisentraut peter_e(at)gmx(dot)net http://funkturm.homeip.net/~peter


From: mlw <markw(at)mohawksoft(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Re: Improving pg_hba.conf
Date: 2001-06-13 17:07:04
Message-ID: 3B279DB8.E8CB5657@mohawksoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Peter Eisentraut wrote:

> mlw writes:
>
> > Why doesn't postgres put the contents pg_hba.conf in a table? That way it comes
> > for free when you reinitialize and restore a database?
>
> Because if you hosed that table you would have hosed your entire
> installation.
>

You could use a bki script to fix the problem in stand alone mode if need be. I
don't think breaking this table is really an issue. My only concerns would be the
chicken vs egg problem connecting to the system, and security. Assuming these issues
could be resolved, I think having this info in a table would be beneficial for
maintenance.


From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-07-09 21:31:35
Message-ID: 200107092131.f69LVZv22427@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

> We have the following item on TODO:
>
> * Overhaul pg_hba.conf host-based authentication
>
> Can people tell me what they want changed. I know we need the pg_shadow
> password field encrypted in the table and I will work on that now.

I haven't heard of any more issues with pg_hba.conf so I will mark the
item as done. I did cleanup the comments in the file. I have also
added a TODO item:

* Read pg_hba.conf only on postmaster startup or SIGHUP

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026


From: David Ford <david(at)blue-labs(dot)org>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-07-23 02:59:13
Message-ID: 3B5B9301.4040201@blue-labs.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

>
>
>I haven't heard of any more issues with pg_hba.conf so I will mark the
>item as done. I did cleanup the comments in the file. I have also
>added a TODO item:
>
> * Read pg_hba.conf only on postmaster startup or SIGHUP
>

If you do this, can you add an access table for secondary lookups? I
tend to update host access frequently and personally I think it'd be
dandy to have a table that can be updated for access as well as the
primary pg_hba.conf file.

David


From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: David Ford <david(at)blue-labs(dot)org>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-07-23 03:01:05
Message-ID: 200107230301.f6N316R08940@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

> >
> >
> >I haven't heard of any more issues with pg_hba.conf so I will mark the
> >item as done. I did cleanup the comments in the file. I have also
> >added a TODO item:
> >
> > * Read pg_hba.conf only on postmaster startup or SIGHUP
> >
>
> If you do this, can you add an access table for secondary lookups? I
> tend to update host access frequently and personally I think it'd be
> dandy to have a table that can be updated for access as well as the
> primary pg_hba.conf file.

Sorry, I don't understand what secondary lookups are.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026


From: David Ford <david(at)blue-labs(dot)org>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-07-23 05:38:11
Message-ID: 3B5BB843.50406@blue-labs.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

What I mean is, do host lookups first in the text file, then if a
pg_hostaccess table (example) exists, check it for host entries. This
alleviates HUP or restart etc. to reload a config file.

David

Bruce Momjian wrote:

>>>
>>>I haven't heard of any more issues with pg_hba.conf so I will mark the
>>>item as done. I did cleanup the comments in the file. I have also
>>>added a TODO item:
>>>
>>> * Read pg_hba.conf only on postmaster startup or SIGHUP
>>>
>>If you do this, can you add an access table for secondary lookups? I
>>tend to update host access frequently and personally I think it'd be
>>dandy to have a table that can be updated for access as well as the
>>primary pg_hba.conf file.
>>
>
>Sorry, I don't understand what secondary lookups are.
>


From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: David Ford <david(at)blue-labs(dot)org>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Improving pg_hba.conf
Date: 2001-07-23 09:56:17
Message-ID: 200107230956.f6N9uIp22870@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

> What I mean is, do host lookups first in the text file, then if a
> pg_hostaccess table (example) exists, check it for host entries. This
> alleviates HUP or restart etc. to reload a config file.

Can't do that. Postmaster has no database access. Must be fast.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026