Fix comment in fe-auth-scram.c
authorMichael Paquier <michael@paquier.xyz>
Tue, 29 Nov 2022 23:37:59 +0000 (08:37 +0900)
committerMichael Paquier <michael@paquier.xyz>
Tue, 29 Nov 2022 23:37:59 +0000 (08:37 +0900)
The frontend-side routine in charge of building a SCRAM verifier
mentioned that the restrictions applying to SASLprep on the password
with the encoding are described at the top of fe-auth-scram.c, but this
information is in auth-scram.c.

This is wrong since 8f8b9be, so backpatch all the way down as this is an
important documentation bit.

Spotted while reviewing a different patch.

Backpatch-through: 11

src/interfaces/libpq/fe-auth-scram.c

index e71626580a7166d84b2af45621cabf76a984b697..c500bea9e74d8084056b6ac10a689201f0e0e882 100644 (file)
@@ -892,7 +892,8 @@ pg_fe_scram_build_secret(const char *password, const char **errstr)
    /*
     * Normalize the password with SASLprep.  If that doesn't work, because
     * the password isn't valid UTF-8 or contains prohibited characters, just
-    * proceed with the original password.  (See comments at top of file.)
+    * proceed with the original password.  (See comments at the top of
+    * auth-scram.c.)
     */
    rc = pg_saslprep(password, &prep_password);
    if (rc == SASLPREP_OOM)