From: Jacob Champion <pchampion@vmware.com>
To: rjuju123@gmail.com <rjuju123@gmail.com>
To: peter.eisentraut@enterprisedb.com <peter.eisentraut@enterprisedb.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Cc: michael@paquier.xyz <michael@paquier.xyz>
Cc: sfrost@snowman.net <sfrost@snowman.net>
Subject: Re: [PATCH] Expose port->authn_id to extensions and triggers
Date: Thu, 3 Mar 2022 19:12:11 +0000
Message-ID: <d1f48bea1595a5e5d35b0136811c53922de3aff6.camel@vmware.com> (raw)
In-Reply-To: <98e600a9-77c3-970a-93df-fbd19b54c7cd@enterprisedb.com>
References: <793d990837ae5c06a558d58d62de9378ab525d83.camel@vmware.com>
<YhduhD/SvIX5NnxY@paquier.xyz>
<2e28b12b450f247d5c0994207030c862263e0297.camel@vmware.com>
<20220224171538.jbf2cxzmhiwuinp4@jrouhaud>
<a4d9baa0717ca924331cb1dd062788bd73bd14a4.camel@vmware.com>
<d15d02c92a3e4bdb7cc7b96b0abfe97f213e4445.camel@vmware.com>
<cdbcf8653e56340f73438e647ea5a26f021627ed.camel@vmware.com>
<a1eb50ab-c5c5-f73b-4887-58be739d12a1@enterprisedb.com>
<64586c91c87c067dd912a24438570a8b8ccb93e0.camel@vmware.com>
<98e600a9-77c3-970a-93df-fbd19b54c7cd@enterprisedb.com>
On Wed, 2022-03-02 at 09:18 +0100, Peter Eisentraut wrote:
> On 01.03.22 23:05, Jacob Champion wrote:
> > On Tue, 2022-03-01 at 19:56 +0100, Peter Eisentraut wrote:
> > > This patch contains no documentation. I'm having a hard time
> > > understanding what the name "session_authn_id" is supposed to convey.
> > > The comment for the Port.authn_id field says this is the "system
> > > username", which sounds like a clearer terminology.
> >
> > "System username" may help from an internal development perspective,
> > especially as it relates to pg_ident.conf, but I don't think that's
> > likely to be a useful descriptor to an end user. (I don't think of a
> > client certificate's Subject Distinguished Name as a "system
> > username".) Does my attempt in v5 help?
>
> Yeah, maybe there are better names. But I have no idea what the letter
> combination "authn_id" is supposed to stand for. Is it an
> "authentication identifier"? What does it identify?
Authenticated identity, but yeah, that's the gist. ("AuthN" being a
standard-ish way to differentiate authentication from "AuthZ"
authorization.)
It's meant to uniquely identify the end user in the case of usermaps,
where multiple separate entities might log in using the same role. It
is distinct from the authorized role name, though they might be exactly
the same in many common setups. And it's not set at all if no
authentication was done.
> Maybe I'm missing something here, but I don't find it clear.
I just used the internal name, but if we want to make it more clear
then now would be a good time. Do you have any suggestions? Does
expanding the name (pg_session_authenticated_id, or even
pg_session_authenticated_identity) help?
--Jacob
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-hackers@postgresql.org
Cc: pchampion@vmware.com, rjuju123@gmail.com, peter.eisentraut@enterprisedb.com, michael@paquier.xyz, sfrost@snowman.net
Subject: Re: [PATCH] Expose port->authn_id to extensions and triggers
In-Reply-To: <d1f48bea1595a5e5d35b0136811c53922de3aff6.camel@vmware.com>
References: <793d990837ae5c06a558d58d62de9378ab525d83.camel@vmware.com> <YhduhD/SvIX5NnxY@paquier.xyz> <2e28b12b450f247d5c0994207030c862263e0297.camel@vmware.com> <20220224171538.jbf2cxzmhiwuinp4@jrouhaud> <a4d9baa0717ca924331cb1dd062788bd73bd14a4.camel@vmware.com> <d15d02c92a3e4bdb7cc7b96b0abfe97f213e4445.camel@vmware.com> <cdbcf8653e56340f73438e647ea5a26f021627ed.camel@vmware.com> <a1eb50ab-c5c5-f73b-4887-58be739d12a1@enterprisedb.com> <64586c91c87c067dd912a24438570a8b8ccb93e0.camel@vmware.com> <98e600a9-77c3-970a-93df-fbd19b54c7cd@enterprisedb.com> <d1f48bea1595a5e5d35b0136811c53922de3aff6.camel@vmware.com>
* 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