Re: Information of pg_stat_ssl visible to all users - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Information of pg_stat_ssl visible to all users
Date
Msg-id 20150707161142.GE10242@alap3.anarazel.de
Whole thread Raw
In response to Re: Information of pg_stat_ssl visible to all users  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: Information of pg_stat_ssl visible to all users  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 2015-07-07 12:03:36 -0400, Peter Eisentraut wrote:
> I think the DN is analogous to the remote user name, which we don't
> expose for any of the other authentication methods.

Huh?

Datum
pg_stat_get_activity(PG_FUNCTION_ARGS)
{    /* Values available to all callers */    values[0] = ObjectIdGetDatum(beentry->st_databaseid);    values[1] =
Int32GetDatum(beentry->st_procpid);   values[2] = ObjectIdGetDatum(beentry->st_userid);
 
...

Isn't that like, essentially, all of them? Sure, if you have a ident
mapping set up, then not, but I have a hard time seing that as a
relevant use case.

> I think the default approach for security and authentication related
> information should be conservative, even if there is not a specific
> reason.  Or to put it another way: What is the motivation for showing
> this information at all?

That we already show equivalent information and that hiding it from
another place will just be crufty and make monitoring setups more
complex.

Greetings,

Andres Freund



pgsql-hackers by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: Information of pg_stat_ssl visible to all users
Next
From: Merlin Moncure
Date:
Subject: Re: PL/pgSQL, RAISE and error context