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 1jZ3R8-0000yR-TJ for pgsql-docs@arkaria.postgresql.org; Thu, 14 May 2020 02:17:27 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jZ3R7-0005LT-7i for pgsql-docs@arkaria.postgresql.org; Thu, 14 May 2020 02:17:25 +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 1jZ3R6-0005LM-D1 for pgsql-docs@lists.postgresql.org; Thu, 14 May 2020 02:17:25 +0000 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jZ3R2-0000TI-RQ for pgsql-docs@postgresql.org; Thu, 14 May 2020 02:17:24 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id 001D939A; Wed, 13 May 2020 22:17:17 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Wed, 13 May 2020 22:17:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm1; bh=vCpr6BdxoU6YFHbhPuf0pRKsZ3l Jjt6TBTvOQhh/XQo=; b=BGUglZVvczpEPQ4A0Mcv8NCXoXej4UAUtRqlWEItO99 m5VNxFH46rf6bnfFPg83y28zpXmZCFIQQ35YcdqNaBRPDqBbLb6DTq6h6W4FcqwV VuaIgUhg9LJkXoV+Uj4Aw4yS7c8vgc685DasF8/jZlfJ82RAjpASrVwZQbyKt0sl 1nX5PAt/HM0CiFTRQWJZwuZGh2prfkRovqNntPbXzyJVN6QaMWpe0nMhrgNhK5kK H+GOuooN5CpIQqWvWT5+aD4MvOM6gOHiqU2CRBuDxNI8gCk534u5gGahDH702bWt 5bg069V3Vd4XwDfpfnC7A3dMHE6ayyUGeXYwcd2uBlA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=vCpr6B dxoU6YFHbhPuf0pRKsZ3lJjt6TBTvOQhh/XQo=; b=Do7OabDym8ky2nc/iNT6Cq hOO0I5dt2kyH8GL6XzYpDqgvCciO+s89huuMneG3269k5LtQrx9IQBn68EaYZpib ESVJioU5/rYFn3PWRag9hkdtX7/hGaRmKEetY6cng9DY1xsysjS4R0rWDLtQwn3x 7CRg/2pq7vBFdi3llIvgAldhXNoxNTfr9Wrbs6qIgPFaNtEBPjWlrRuygzDNr7cI ScRwI1EM53rfw7X+sqWYFHwMwhr380qX4pA3tK4vKqjE7Rl3HjPRCZXMskRfT+Tt R2vQLtjbLCEWxn4RnMsPSkxSuQD1Pt3d1QS9/lW1a2F+gAjAoDPM2I8TvPJrRvsw == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrleehgdehiecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenfg hrlhcuvffnffculdejtddmnecujfgurhepfffhvffukfhfgggtuggjsehgtderredttddv necuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruceomhhitghhrggvlhesphgrqh huihgvrhdrgiihiieqnecuggftrfgrthhtvghrnhepvdegudeuhfdtueeltedtveejheeh ieevueeigeelteegleejleeiueeiheegvefhnecukfhppeduuddurddutddvrddukedtrd dukeehnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhep mhhitghhrggvlhesphgrqhhuihgvrhdrgiihii X-ME-Proxy: Received: from paquier.xyz (ee0822lan1.rev.em-net.ne.jp [111.102.180.185]) by mail.messagingengine.com (Postfix) with ESMTPA id 409463280063; Wed, 13 May 2020 22:17:16 -0400 (EDT) Date: Thu, 14 May 2020 11:17:13 +0900 From: Michael Paquier To: Daniel Gustafsson Cc: pgsql-docs@postgresql.org Subject: Re: TLS docs fixes for Message-ID: <20200514021713.GB166343@paquier.xyz> References: <401F9024-20EA-4239-83C4-6B7AD35F94BD@yesql.se> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="uh9ZiVrAOUUm9fzH" Content-Disposition: inline In-Reply-To: <401F9024-20EA-4239-83C4-6B7AD35F94BD@yesql.se> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --uh9ZiVrAOUUm9fzH Content-Type: multipart/mixed; boundary="WhfpMioaduB5tiZL" Content-Disposition: inline --WhfpMioaduB5tiZL Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, May 13, 2020 at 11:07:44PM +0200, Daniel Gustafsson wrote: > While working with TLS I noticed that the password callback definition had an > extra newline in the programlisting in the docs. Since the > has been indented with the textblock, the newline comes from whitespace being > significant. The attached 0001 fixes by instead anchoring on > column zero like how most of the docs do it. Grepping around I found one more > instance of the same pattern which is also included. Indeed, I can see the difference. In what I spotted after applying 0001, you are patching the one in libpq.sgml as of 0002 but in a different, correct, way, and I have spotted three more inconsistencies within doc/src/sgml/datatype.sgml in the zone for timestamps. > The "Enter PEM pass phrase" prompt was referred to in one place with > and one with , the 0002 settles on using for both > since IMO that makes the docs more readable. While there, it also fixes the > spelling of "pass phrase" from the two variations we had (of which none was the > correct one from src/backend/libpq/be-secure-openssl.c as well as the OpenSSL > file crypto/pem/pem_lib.c). Yeah, good catch. Let's fix that. With everything I found on top of your stuff, I finish with the attached. Does it look fine to you? -- Michael --WhfpMioaduB5tiZL Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="doc-fixes-daniel-v2.patch" Content-Transfer-Encoding: quoted-printable diff --git a/doc/src/sgml/datatype.sgml b/doc/src/sgml/datatype.sgml index a8d0780387..86eb38cc8f 100644 --- a/doc/src/sgml/datatype.sgml +++ b/doc/src/sgml/datatype.sgml @@ -2095,11 +2095,15 @@ January 8 04:05:06 1999 PST + or - symbol and time zone offset aft= er the time. Hence, according to the standard, =20 - TIMESTAMP '2004-10-19 10:23:54' + +TIMESTAMP '2004-10-19 10:23:54' + =20 is a timestamp without time zone, while =20 - TIMESTAMP '2004-10-19 10:23:54+02' + +TIMESTAMP '2004-10-19 10:23:54+02' + =20 is a timestamp with time zone. PostgreSQL never examines the content of a @@ -2108,7 +2112,9 @@ January 8 04:05:06 1999 PST ensure that a literal is treated as timestamp with time zone, give it the correct explicit type: =20 - TIMESTAMP WITH TIME ZONE '2004-10-19 10:23:54+02' + +TIMESTAMP WITH TIME ZONE '2004-10-19 10:23:54+02' + =20 In a literal that has been determined to be timestamp without = time zone, PostgreSQL will silently ign= ore diff --git a/doc/src/sgml/libpq.sgml b/doc/src/sgml/libpq.sgml index 5892367c61..75c7c5837b 100644 --- a/doc/src/sgml/libpq.sgml +++ b/doc/src/sgml/libpq.sgml @@ -790,9 +790,9 @@ void PQsetSSLKeyPassHook(PQsslKeyPassHook_type hook); =20 The application passes a pointer to a callback function with signat= ure: - - int callback_fn(char *buf, int size, PGconn *conn); - + +int callback_fn(char *buf, int size, PGconn *conn); + which libpq will then call instead of<= /emphasis> its default PQdefaultSSLKeyPassHook handler. T= he callback should determine the password for the key and copy it to result-buf= fer @@ -1668,7 +1668,7 @@ postgresql://%2Fvar%2Flib%2Fpostgresql/dbname Specifying this parameter with any non-empty value suppresses the - Enter PEM passphrase: + Enter PEM pass phrase: prompt that OpenSSL will emit by default when an encrypted client certificate key is provided to libpq. @@ -7667,10 +7667,7 @@ ldap://ldap.acme.com/cn=3Ddbserver,cn=3Dhosts?pgconn= ectinfo?base?(objectclass=3D*) may be provided in the co= nnection option. If an encrypted key is supplied and the sslpassword option is absent or blank, a password will be prompted for interactivel= y by - OpenSSL with a - - Enter PEM Passphrase: - + OpenSSL with a Enter PEM pass phrase: prompt if a TTY is available. Applications can override the client cert= ificate prompt and the handling of the sslpassword parameter= by supplying their own key password callback; see . diff --git a/doc/src/sgml/postgres-fdw.sgml b/doc/src/sgml/postgres-fdw.sgml index 94992be427..eab2cc9378 100644 --- a/doc/src/sgml/postgres-fdw.sgml +++ b/doc/src/sgml/postgres-fdw.sgml @@ -151,10 +151,10 @@ A superuser may override this check on a per-user-mapping basis by set= ting the user mapping option password_required 'false', = e.g. - - ALTER USER MAPPING FOR some_non_superuser SERVER loopback_nopw - OPTIONS (ADD password_required 'false'); - + +ALTER USER MAPPING FOR some_non_superuser SERVER loopback_nopw +OPTIONS (ADD password_required 'false'); + To prevent unprivileged users from exploiting the authentication rights of the unix user the postgres server is running as to escalate to supe= ruser rights, only the superuser may set this option on a user mapping. --WhfpMioaduB5tiZL-- --uh9ZiVrAOUUm9fzH Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAl68qikACgkQnvQgOdby QH3AZhAAl7mb2eONOqREMASaoN5xyD+fxk7wgnwmdjGOS7hiCCKwh9I2kD7k2xqA 62qpvs3l/d3gfj9bqxfkd53nUVLyrG3dn9wvhPW+IfB6pHDqx31Biopf04wBz5Ke V40sTlII1fqCVZ/H5zWCMI+QqlIgqeRnnQwhisu1lHOo7EsIs8WMF0dfBcGe03Hn +EP3hpN7FV7011nPPyCcDfhPkffHaPLEbvKSwEZg+6ljDCcgZzPjp98k00Bl907Q 28aFGEB335L92dbO96Su6HyvDMCPQNPAsbmMcf4SIvUJzEMCxvAATpMhHTHu0Tyz T5pYX5RU+CEV4m83E5OLPkNlto8pRqaA+pV208oDcrhlAhBHG6+XBwnRrWKjcs1E TPaPwJBklb11BRVDSw/pinEj37x52sr1HoyIP2p8GdUcc3rjTa8tFYx86hhdPIsI NifWrMBohR1ERwkGKJlqx8yCjjnGjcSyjWI2m8yC3BWR6TifQiR0GyN8S/Ghxn66 XQSHjXDOZzcg7uJxbqM7fYV/gdxp7+CyasXSejSY32GGb1DG4qwEiMsPJ+SNfur/ UFeUBy3wjO6I5Y/QdbSgC6fmVdixUCuePFhPtzBuVUa5cn/XGFtQYcJwemjlPZab 1/gfcS/liM0KRAfYJpqiF53K+2imJ5AlG5Hf813Tv5p4DaYDrpA= =ezUO -----END PGP SIGNATURE----- --uh9ZiVrAOUUm9fzH--