Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kvjGf-0002lP-Kg for pgadmin-hackers@arkaria.postgresql.org; Sat, 02 Jan 2021 15:56:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kvjGd-0000I7-NV for pgadmin-hackers@arkaria.postgresql.org; Sat, 02 Jan 2021 15:56:35 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kvjGd-0000I0-8g for pgadmin-hackers@lists.postgresql.org; Sat, 02 Jan 2021 15:56:35 +0000 Received: from mail-ej1-x62d.google.com ([2a00:1450:4864:20::62d]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kvjGa-0001Hc-8R for pgadmin-hackers@postgresql.org; Sat, 02 Jan 2021 15:56:33 +0000 Received: by mail-ej1-x62d.google.com with SMTP id q22so30808082eja.2 for ; Sat, 02 Jan 2021 07:56:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pgadmin.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=MT0boThR6TlDdYMUT2Mn+mhCkNtg1ibb34h+XaXim3A=; b=FUkLO0oDv+MI62aUU4lCty8FpBKKSK155aml8y4UpaCjjBYQIOIVq/qJ7FhCyVH3qe hNr6Zul8MZ1xujWxBpiYZU2nRhUdcQbNL+1u2kkLp4zKPoihAv7DIbKEyQQZumUJ8TG7 hyjhXnzZieVioia+mfi5YcSmlYF1Ez8Z9Hz9Cwe9rloGhVhbCau5Z8bsGp37cKp1dJo3 cmrYp3pduHE5C3uHDpTyjPfWiMk7nE+0o8ziizxE4E4hQ4ItXC4ZcAU7i9WikULwmOQh /aFOasKEt9o9iIIKE8LKhPIMlhbI+Qd9fJt3YQy4XK3k4MJh5TqYzlYOEDkxtakOxA85 T33w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=MT0boThR6TlDdYMUT2Mn+mhCkNtg1ibb34h+XaXim3A=; b=umfWJ+uTirZ1wDo7EOJZyYWw6W359+YTo8BqLiLvOPlOWOky8Dk7lDmyH5Dzmk3QaD B4ddgVYq53pFEN016NeohEe5/u4vHrLbjDwF7TNsw54BIhFprB12lMXpMWWrHK+/DrRE 3HlioCLArpOyuIQ53NgYc7vzJYyFnrnl8CT/SWzdgmf7sAgzzgbFZ5NsJKuLNkpY7ibZ ox3+wXU1xj1MjVb/USIVv73XtFG0lxZONRNMpM/G4aL1LuAx0KtoRGihqVYR9ZPKy+Hz CzDGuvysRB27TxulFlREA3skTjgfs+YvWlbIqZuw3ewtt5pSs8aJFRSDnHqVqCP2/AuT JTvQ== X-Gm-Message-State: AOAM530Z8AZezbKi7ZB/hCJ1+xWX9N0cFN/FWnXozlt1xF+annXOzmYC KDHAsGzGDXPS/6yC3LYqq1/Glwdl2sRceDrdodoN3g== X-Google-Smtp-Source: ABdhPJzrG9mQ5tDUcgUzRU49PbhJ62uiCw6OSjaKThcLXR8liMqFsNYJz64wI36FrCFdRGN0pjebQt7TRIOdWvmg3Og= X-Received: by 2002:a17:906:add7:: with SMTP id lb23mr63818607ejb.352.1609602990406; Sat, 02 Jan 2021 07:56:30 -0800 (PST) MIME-Version: 1.0 References: <20210102154130.GO27507@tamriel.snowman.net> In-Reply-To: <20210102154130.GO27507@tamriel.snowman.net> From: Dave Page Date: Sat, 2 Jan 2021 15:56:19 +0000 Message-ID: Subject: Re: [pgAdmin4][Patch] - RM 5457 - Kerberos Authentication - Phase 1 To: Stephen Frost Cc: Khushboo Vashi , pgadmin-hackers Content-Type: multipart/alternative; boundary="0000000000007925b805b7ece607" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --0000000000007925b805b7ece607 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Stephen On Sat, 2 Jan 2021 at 15:41, Stephen Frost wrote: > Greetings, > > * Khushboo Vashi (khushboo.vashi@enterprisedb.com) wrote: > > Please find the attached patch to support Kerberos Authentication in > > pgAdmin RM 5457. > > > > The patch introduces a new pluggable option for Kerberos authentication= , > > using SPNEGO to forward kerberos tickets through a browser which will > > bypass the login page entirely if the Kerberos Authentication succeeds. > > I've taken a (very short) look at this as it's certainly something that > I'm interested in and glad to see work is being done on it. > > I notice that 'delegated_creds' is being set but it's unclear to me how > they're actually being used (if at all), which is a very important part > of Kerberos. > > What's commonly done with mod_auth_kerb/mod_auth_gss is that the > delegated credentials are stored on the filesystem in a temporary > directory and then an environment variable is set to signal to libpq / > the Kerberos libraries that the delegated credentials can be found in > the temporary file. I don't see any of that happening in this patch- is > that already handled in some way? If not, what's the plan for making > that work? Also important is to make sure that this approach will work > for constrainted delegation implementations. Phase 1 of this project (which this patch aims to implement) is to handle Kerberos logins to pgAdmin when running in server mode (as we=E2=80=99ve al= ready done for LDAP, except KRB authenticated users don=E2=80=99t see a login pag= e of course). Phase 2 will add support for logging into the PostgreSQL servers - I believe that is where we=E2=80=99ll need to handle delegated credentials,= correct? > -- --=20 Dave Page https://pgsnake.blogspot.com EDB Postgres https://www.enterprisedb.com --0000000000007925b805b7ece607 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Stephen=C2=A0

On Sat, 2 Jan 2021 at 15:41, Stephen= Frost <sfrost@snowman.net>= wrote:
Greetings,

* Khushboo Vashi (khushboo.vashi@enterprisedb.com) wrote:
> Please find the attached patch to support Kerberos Authentication in > pgAdmin RM 5457.
>
> The patch introduces a new pluggable option for Kerberos authenticatio= n,
> using SPNEGO to forward kerberos tickets through a browser which will<= br> > bypass the login page entirely if the Kerberos Authentication succeeds= .

I've taken a (very short) look at this as it's certainly something = that
I'm interested in and glad to see work is being done on it.

I notice that 'delegated_creds' is being set but it's unclear t= o me how
they're actually being used (if at all), which is a very important part=
of Kerberos.

What's commonly done with mod_auth_kerb/mod_auth_gss is that the
delegated credentials are stored on the filesystem in a temporary
directory and then an environment variable is set to signal to libpq /
the Kerberos libraries that the delegated credentials can be found in
the temporary file.=C2=A0 I don't see any of that happening in this pat= ch- is
that already handled in some way?=C2=A0 If not, what's the plan for mak= ing
that work?=C2=A0 Also important is to make sure that this approach will wor= k
for constrainted delegation implementations.
=
Phase 1 of this project (which this patch aims = to implement) is to handle Kerberos logins to pgAdmin when running in serve= r mode (as we=E2=80=99ve already done for LDAP, except KRB authenticated us= ers don=E2=80=99t see a login page of course). Phase 2 will add support for= logging into the PostgreSQL servers - I believe that is where we=E2=80=99l= l need to handle delegated credentials, correct?
--
--0000000000007925b805b7ece607--