Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i8I2S-0002Xo-LA for pgsql-general@arkaria.postgresql.org; Thu, 12 Sep 2019 05:53:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1i8I1S-00077a-Dv for pgsql-general@arkaria.postgresql.org; Thu, 12 Sep 2019 05:52:02 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i8I1S-00077I-1Q for pgsql-general@lists.postgresql.org; Thu, 12 Sep 2019 05:52:02 +0000 Received: from hermes.gatewaynet.com ([193.92.121.98]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i8I1O-0001AL-JB for pgsql-general@lists.postgresql.org; Thu, 12 Sep 2019 05:52:01 +0000 Received: from smadev.internal.net (pc131.internal.net [10.9.200.131]) by hermes.gatewaynet.com (8.15.2/8.15.2/Debian-8) with ESMTPS id x8C5pm15022420 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 12 Sep 2019 08:51:53 +0300 Received: from smadev.internal.net (smadev [10.9.200.131]) by smadev.internal.net (8.15.2/8.15.2) with ESMTP id x8C5pmKs066004 for ; Thu, 12 Sep 2019 08:51:48 +0300 (EEST) (envelope-from achill@matrix.gatewaynet.com) Subject: Re: pgbouncer with ldap To: pgsql-general@lists.postgresql.org References: <20190909074003.GA2404@elch.exwg.net> <20190909080358.GB2404@elch.exwg.net> <4742aa69-f831-fbfb-40a8-82f88b6ef408@matrix.gatewaynet.com> From: Achilleas Mantzios Message-ID: <7741646c-bd71-6506-a161-6f7b6284618b@matrix.gatewaynet.com> Date: Thu, 12 Sep 2019 08:51:48 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.3.2 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/alternative; boundary="------------71188E5A69A96EDFCFD0EED1" Content-Language: en-US X-Virus-Scanned: clamav-milter 0.100.3 at hermes X-Virus-Status: Clean X-Spam-Status: No, score=-37.9 required=5.0 tests=ALL_TRUSTED,DYN_HAM_COORD, DYN_HAM_IT,DYN_HAM_IT_PARTNERS,DYN_HAM_NAUTICAL,HTML_MESSAGE,TW_PG autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on hermes.gatewaynet.com List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --------------71188E5A69A96EDFCFD0EED1 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit On 11/9/19 2:47 μ.μ., Ayub M wrote: > Achilleas, for this setup to work are changes to postgresql.conf and pg_hba.conf needed? I am trying to implement this for AWS rds Aurora where these files are not accessible. > Those files are needed in any case if you work with postgresql. Unfortunately no experience with Aurora. He have been building from source for ages. > On Mon, Sep 9, 2019, 6:46 AM Achilleas Mantzios > wrote: > > On 9/9/19 12:41 μ.μ., Laurenz Albe wrote: > > Christoph Moench-Tegeder wrote: > >>> It has hba and via hba file one can specify ldap connections > >>> > >>> https://www.postgresql.org/docs/9.3/auth-pg-hba-conf.html > >> https://pgbouncer.github.io/config.html#hba-file-format > >> "Auth-method field: Only methods supported by PgBouncer’s auth_type > >> are supported", and "ldap" is not supported. > >> When there's no ldap support in pgbouncer, there's no ldap support > >> in pgbouncer. > > To throw in something less tautological: > > > > PgBouncer supports PAM authentication, so if you are on UNIX, > > you could use PAM's LDAP module to do what you want. > Right, I had written a blog about it : > https://severalnines.com/database-blog/one-security-system-application-connection-pooling-and-postgresql-case-ldap > > However, I always wished (since my first endeavors with pgbouncer) it was less complicated. > > > > Yours, > > Laurenz Albe > > > -- > Achilleas Mantzios > IT DEV Lead > IT DEPT > Dynacom Tankers Mgmt > > > -- Achilleas Mantzios IT DEV Lead IT DEPT Dynacom Tankers Mgmt --------------71188E5A69A96EDFCFD0EED1 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit
On 11/9/19 2:47 μ.μ., Ayub M wrote:
Achilleas, for this setup to work are changes to postgresql.conf and pg_hba.conf needed? I am trying to implement this for AWS rds Aurora where these files are not accessible. 

Those files are needed in any case if you work with postgresql. Unfortunately no experience with Aurora. He have been building from source for ages.
On Mon, Sep 9, 2019, 6:46 AM Achilleas Mantzios <achill@matrix.gatewaynet.com> wrote:
On 9/9/19 12:41 μ.μ., Laurenz Albe wrote:
> Christoph Moench-Tegeder wrote:
>>> It has hba and via hba file one can specify ldap connections
>>>
>>> https://www.postgresql.org/docs/9.3/auth-pg-hba-conf.html
>> https://pgbouncer.github.io/config.html#hba-file-format
>> "Auth-method field: Only methods supported by PgBouncer’s auth_type
>> are supported", and "ldap" is not supported.
>> When there's no ldap support in pgbouncer, there's no ldap support
>> in pgbouncer.
> To throw in something less tautological:
>
> PgBouncer supports PAM authentication, so if you are on UNIX,
> you could use PAM's LDAP module to do what you want.
Right, I had written a blog about it :
https://severalnines.com/database-blog/one-security-system-application-connection-pooling-and-postgresql-case-ldap

However, I always wished (since my first endeavors with pgbouncer) it was less complicated.
>
> Yours,
> Laurenz Albe


--
Achilleas Mantzios
IT DEV Lead
IT DEPT
Dynacom Tankers Mgmt





-- 
Achilleas Mantzios
IT DEV Lead
IT DEPT
Dynacom Tankers Mgmt
--------------71188E5A69A96EDFCFD0EED1--