Debian "postgresql-common" config check issue with pg10

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pkg-postgresql-public(at)lists(dot)alioth(dot)debian(dot)org, PostgreSQL Developers <pgsql-hackers(at)postgresql(dot)org>
Subject: Debian "postgresql-common" config check issue with pg10
Date: 2017-05-08 16:54:06
Message-ID: alpine.DEB.2.20.1705081730030.3983@lancre
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Hello Peter,

Although this is really a small debian packaging issue, I cc to pgdev
because it illustrates unintended consequences of trivial changes.

Thanks (again!) to the great and up-to-date apt.postgresql.org repository,
I've tried to test the new scram-sha-256 feature. For that I looked in
"postgres.conf" and found:

#password_encryption = md5 # md5, scram-sha-256 or plain

Thus I naïvely added:

password_encryption = scram-sha-256

After:

sh> pg_ctlcluster 10 main start

The result is:

Error: Invalid line 88 in /etc/postgresql/10/main/postgresql.conf:
»password_encryption = scram-sha-256«

However, it works if I put 'scram-sha-256' (with simple quotes).

The underlying issue is that the '-' character breaks the config checker,
ISTM that the simple value regex in function "read_conf_file" in module
"PgCommon.pm" should be extended to allow more chars in unquoted strings,
to be consistent with lexer definitions in
"src/backend/utils/misc/guc-file.l".

I think that the issue appeared when 'scram' was changed to
'scram-sha-256' recently, as it is the first option enum with a dash,
all other options use '_'.

In passing, I would like to point out that the French quotation chevrons
(guillemets) used on the wrong sides and without spacing is probably eye
watering pain to any French reader, maybe like using ß in place of B in a
text. Also utf8 chars might not work properly under some terminal
encodings. Maybe using simple ascii ">>" and "<<" for the messages would
also be more portable?

--
Fabien.

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Christoph Berg 2017-05-08 17:50:50 Re: [Pkg-postgresql-public] Debian "postgresql-common" config check issue with pg10
Previous Message Alvaro Herrera 2017-05-08 16:53:10 Re: pgbench tap tests & minor fixes