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 1kxVxv-0003Aa-84 for pgsql-general@arkaria.postgresql.org; Thu, 07 Jan 2021 14:08:39 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kxVxu-0006Pj-7R for pgsql-general@arkaria.postgresql.org; Thu, 07 Jan 2021 14:08:38 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kxVxu-0006Pc-08 for pgsql-general@lists.postgresql.org; Thu, 07 Jan 2021 14:08:38 +0000 Received: from mail-wm1-x32d.google.com ([2a00:1450:4864:20::32d]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kxVxq-0007UH-Gm for pgsql-general@postgresql.org; Thu, 07 Jan 2021 14:08:37 +0000 Received: by mail-wm1-x32d.google.com with SMTP id r4so5628397wmh.5 for ; Thu, 07 Jan 2021 06:08:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=WdZ5IBGjvQaU51ijyQ04ph6kjDiS5ZQ4LYR6wKvKl7c=; b=DoL02cTNSYqW6m/V3JPGxqRH9oeXOBjoq7r9mfBwsi2QtwzLKHPJDbkLTaD9T/XUhQ R6NplQYji5CckzxhCVYxoyNvVZp4pRTs/Rf+n1ef2vDWx/HxGqSn0VcNK7C+z//qbnSQ 8/m1ZJu4dBkySRWsRhMuo5GVVzkeWnVRgbULeDtfAg2m+RrS1DXjN+z7fFTupGB3ckeG JKtFPFyGbPyBwSJI/Ox7ruYOGiSqs1UZeNiZlp+r/gvJyEoHa6uGCyDTnHrMBV9PknnW 5h5+JLbIXGkFurBglRd1TV6AzMcC3nYUZ85zkQZllXN5Obb+KZ2uUlXYghK24CK+W9On wSeg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=WdZ5IBGjvQaU51ijyQ04ph6kjDiS5ZQ4LYR6wKvKl7c=; b=cW++joxedvqDLpFloPelFw4lDFXABr1n8BmK/O3bUU4SVX70t5kIFJVeA4yP8Umic6 /bLD4RL1cAeKrb7g/SkKzEYfohTeySofmMAUU2nDoOvaAqQbvSydmw9LBAXsy9wH+ybf BVKQ0J3IaG5zzG5v2fdfqV0R/DdK4etJd/Rt/xs2P0LZG5cHdGBz/3N680TcyLtWL+h6 AaAnUO/tFSSm4N7p985gaOElxtxWyWWOV95CP8a+c2vaOD8dGJo9sb7BUhRziMgE3Nr3 ramaxpoVAiY5ayv1WX3mVAjB2ugjwb21JdGWnnRicgN40JqW2YYMwVopgNZ49wZb8pGX eGMQ== X-Gm-Message-State: AOAM532eK9PSS8bagPhK6iwIplMVY23TaH+l0GMWEuiYD1oOar/+2iio s3HkUZrqoveMTirkLpmVRSTeRG4gZjY= X-Google-Smtp-Source: ABdhPJwbkYHqqcS9BmT+rdqdgx6qM+KKaf1ihyPrq7RcXjce3pnkAN9fRk1TukfQrajoprE98AJq4A== X-Received: by 2002:a1c:6055:: with SMTP id u82mr8402208wmb.61.1610028513049; Thu, 07 Jan 2021 06:08:33 -0800 (PST) Received: from [192.168.1.8] (241-57-239-77.dyn.cable.fcom.ch. [77.239.57.241]) by smtp.gmail.com with ESMTPSA id q143sm7842319wme.28.2021.01.07.06.08.32 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 07 Jan 2021 06:08:32 -0800 (PST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.40.0.2.32\)) Subject: Re: Using more than one LDAP? From: =?utf-8?Q?Paul_F=C3=B6rster?= In-Reply-To: Date: Thu, 7 Jan 2021 15:08:31 +0100 Cc: "pgsql-general@postgresql.org >> PG-General Mailing List" Content-Transfer-Encoding: quoted-printable Message-Id: <15055352-B99F-4F38-AFCF-7B78341820F5@gmail.com> References: <08D7C808-63E6-4482-A753-9F3E0DF8ABB5@gmail.com> To: Magnus Hagander X-Mailer: Apple Mail (2.3654.40.0.2.32) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Hi Magnus, > On 07. Jan, 2021, at 12:43, Magnus Hagander = wrote: >=20 > The docs say "When using an external authentication system such as > Ident or GSSAPI, the name of the operating system user that initiated > the connection might not be the same as the database user (role) that > is to be used." >=20 > I think that's a bit of a left-over to when it was really just ident. > First of all it should probably say peer rather than ident, and it's > not actually operating systems that are relevant here. >=20 > So I can understand you getting ab it confused by that. but the > property that matter is where the username comes from. In GSSAPI, or > peer, or certificate, etc, the username is provided by the external > system, and the mapping is applied *after* that. >=20 > With LDAP authentication, the username is provided by the client, and > is then passed to the external system. >=20 > Mapping applies *after* the authentication, which inthe case of LDAP > would be too late to make any difference. >=20 > The references to "unix user" and "operating system users" are > probably a leftover from the old days and actually contribute to some > of the confusion I think. that explains it. The use case in our company is: Developers connect with tools like = DbVisualizer or SQL Developer (Oracle using the nasty PostgreSQL Hack = :-( ) providing their username via JDBC to the database. Developers work = on Windows, the databases run on Linux (SLES) and the AD obviously runs = on Windows. Ok, since LDAP doesn't work that way, I either need to build GSSAPI = packages and have the AD admins to provide me with the keytab file or = make the transition a "hard" one, i.e. no transition phase. Though I'd = rather have liked to see a transition phase where either account could = have been used I personally can live with that. It's the developers who = will have to change quickly, not me. ;-) Cheers, Paul=