doc: Fix incorrect openssl option
authorDaniel Gustafsson
Thu, 1 Feb 2024 08:36:34 +0000 (09:36 +0100)
committerDaniel Gustafsson
Thu, 1 Feb 2024 08:36:34 +0000 (09:36 +0100)
The openssl command for displaying the DN of a client certificate was
using --subject and not the single-dash option -subject. While recent
versions of openssl handles double dash options,  earlier does not so
fix by using just -subject  (which is per the openssl documentation).

Backpatch to v14 where this was introduced.

Reported-by: [email protected]
Discussion: https://postgr.es/m/170672168899.666.10442618407194498217@wrigleys.postgresql.org
Backpatch-through: v14

doc/src/sgml/client-auth.sgml

index 7fcddaa97df9b62bde6fb4aae7462a1a804b0163..740ae77b6d063c12247a4db0790eaf9deb236cbc 100644 (file)
@@ -666,7 +666,7 @@ include_dir         directory
        format. To see the DN of a client certificate
        in this format, do
 
-openssl x509 -in myclient.crt -noout --subject -nameopt RFC2253 | sed "s/^subject=//"
+openssl x509 -in myclient.crt -noout -subject -nameopt RFC2253 | sed "s/^subject=//"
 
         Care needs to be taken when using this option, especially when using
         regular expression matching against the DN.