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 1kxRmp-00042W-Mp for pgsql-general@arkaria.postgresql.org; Thu, 07 Jan 2021 09:40:55 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kxRmn-0006mj-C6 for pgsql-general@arkaria.postgresql.org; Thu, 07 Jan 2021 09:40:53 +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 1kxRmn-0006mU-24 for pgsql-general@lists.postgresql.org; Thu, 07 Jan 2021 09:40:53 +0000 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kxRmi-0005IL-Hj for pgsql-general@postgresql.org; Thu, 07 Jan 2021 09:40:52 +0000 Received: by mail-wm1-x32b.google.com with SMTP id y23so4954042wmi.1 for ; Thu, 07 Jan 2021 01:40:48 -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=VdGpOLH2pUBdzlKvbjG5p3OOp2RPnyxpfzks53szDz4=; b=WcC00zLTw36D3qyjszb/wwG8cx/R/3dU6xjxsmUhjPmkBM4C3LtZGCOQUD0BgxTpjK aWgW2cZAn6a2mQpDNb7APr7K2KFeWWe4/3wRh3157tSpfLemnjIi2buyS5j82vPcyU6N fu1jX/ajKbcGsxmYAyxLTcu3j9HRmtrDFD3dTgLQpkd9L9Tv6zrXAS88Nd4VIEYgWZgo p40bypQefDBmYX+OF24R5Zp9pz4rpHprVHvj8ajU9rFCIeuGPL2hdAnC6EZF9vB6yA6J UVTRRLYJm9q0YZBgAd/Rvjayxf297nn7UesnXxHz7vGcyRwzAtjQ17s8VHbo9P+t5/Cd ZA7w== 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=VdGpOLH2pUBdzlKvbjG5p3OOp2RPnyxpfzks53szDz4=; b=IkIkId60ar5DtJXIlVVC2hkoDd+4gEjLDRNzyvTvOYuJEaFICmZcQ9cyTTrxTmnr7J tpXPu8CtB4c2yuHiCnl9GtoYcUypUIgW9PXcXuOm1HzkMyEo+/27JkP4ci1Gs23DAwsl ttDiTOEJAYR3A7ghRTFiHX+pAcu1/p+qQ0InGyI+THmN21deRwOeyaa9F0uJQMf41LHw 4Ef14gzSvGAsKVv9wtLNpD5hnB5VIcLWP+EZ4+zSrU7pGv5kKxyXy2Cy8Q6AIq609147 yw3pydqZqK2LliNSEULHUyv1e/zn5HswEMKHtHeI4bxQhglOCzQIkObK/MGdAaYxgXyL I39Q== X-Gm-Message-State: AOAM532yaR4zHbaKuWLAnwdnnlO0lHpBhVTEB2j8t9l0sHDAsVqGPcZU xb4Kh0pWq3G2l6jbRef/8Lc= X-Google-Smtp-Source: ABdhPJyAuWLkVB+3+lsezfL8Q0euxc19FT5Ak0acbe9YPbthpcqJWVBz7yTHvk1cMMawJjbpjn2YMQ== X-Received: by 2002:a7b:c8da:: with SMTP id f26mr7397375wml.155.1610012447694; Thu, 07 Jan 2021 01:40:47 -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 x13sm7574070wrp.80.2021.01.07.01.40.47 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 07 Jan 2021 01:40:47 -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 10:40:46 +0100 Cc: "pgsql-general@postgresql.org >> PG-General Mailing List" Content-Transfer-Encoding: quoted-printable Message-Id: 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 06. Jan, 2021, at 16:57, Magnus Hagander = wrote: >=20 > Yes. But you have a really hacky environment :P actually not. We have an old LDAP which we want to retire this year. And = we also have Windows AD, which offers LDAP. So the idea is to switch the = LDAP environments in PostgreSQL. The old LDAP uses aaa-u1, aaa-u2, etc. = which are also accounts in the database. But our Windows AD has bbb-u1, = bbb-u2, etc. So just switching LDAPs doesn't work. I'd also have to = rename all users. Though it's just a one-liner, it would mean that users = have to use their new names from one second to the next. But we want a = transition phase if that's possible. > You could have a third LDAP instance that federates the other two. >=20 > Another option could be to proxy it through something like FreeRADIUS. > I'm fairly certain it can also move on to a secondary server if the > first one reports login failure. I can't. I'm no sysadmin and have no rights on systems to install = anything except the PostgreSQL software. Also, the network guys wouldn't = be too happy. And then, there is a problem introducing new software, = which is possible, but can take months for us to get the necessary = permissions. > I assume you're not using any of the standard packagings then, as I > believe they all come with support for GSSAPI. Yet another reason why > it's a good idea to use that :) no, we always compile from source and only what we need. I can build = packages with GSSAPI compiled into it but it does require me do have a = small service interruption if I install packages with the same = PostgreSQL version number, a situation, which I'd like to avoid, if = possible. > And no, gssapi does not use certificates. that's good news as I'm not really happy about all that certificate = stuff. ;-) > pg_ident only works for authentication methods where the username > comes from the other system, such as with Kerberos. It does not work > for LDAP, where the username is specified in PostgreSQL. I don' understand that. The doc says it should work for all external = authentication services. Maybe I misread something?... Cheers, Paul=