pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Allow records to span multiple lines in pg_hba.conf and pg_ident
Date: Thu, 03 Sep 2020 16:16:54 +0000
Message-ID: <E1kDruw-0000TH-Co@gemulon.postgresql.org> (raw)

Allow records to span multiple lines in pg_hba.conf and pg_ident.conf.

A backslash at the end of a line now causes the next line to be appended
to the current one (effectively, the backslash and newline are discarded).
This allows long HBA entries to be created without legibility problems.

While we're here, get rid of the former hard-wired length limit on
pg_hba.conf lines, by using an expansible StringInfo buffer instead
of a fixed-size local variable.

Since the same code is used to read the ident map file, these changes
apply there as well.

Fabien Coelho, reviewed by Justin Pryzby and David Zhang

Discussion: https://postgr.es/m/alpine.DEB.2.21.2003251906140.15243@pseudo

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/8f8154a503c71a18ad72c64f4aefb9d847c45b86

Modified Files
--------------
doc/src/sgml/client-auth.sgml             |   6 +-
src/backend/libpq/hba.c                   | 106 ++++++++++++++++++++----------
src/test/authentication/t/001_password.pl |   3 +-
3 files changed, 76 insertions(+), 39 deletions(-)



Message-ID: <E1kDruw-0000TH-Co@gemulon.postgresql.org>
Permalink:  ../E1kDruw-0000TH-Co@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1kDruw-0000TH-Co@gemulon.postgresql.org

 · 

reply

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-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Allow records to span multiple lines in pg_hba.conf and pg_ident
  In-Reply-To: <E1kDruw-0000TH-Co@gemulon.postgresql.org>
  References: <E1kDruw-0000TH-Co@gemulon.postgresql.org>

* 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