From: vlsi (@vlsi) <noreply+vlsi@github.com>
To: pgjdbc/pgjdbc <noreply+pgjdbc-pgjdbc@github.com>
Subject: Re: [pgjdbc/pgjdbc] PR #4251: OAuth implementation
Date: Wed, 23 Sep 2026 06:43:34 +0000
Message-ID: <gh-pgjdbc-pgjdbc-4251-rc4079734666@github.com> (raw)
In-Reply-To: <gh-pgjdbc-pgjdbc-4251@github.com>
References: <gh-pgjdbc-pgjdbc-4251@github.com>
(on docs/content/documentation/use.md:552)
This paragraph leaves out the case every reader hits first. With the default `sslmode=prefer`, OAuth always fails, over TLS too: the check refuses any `sslmode` that doesn't verify the certificate. As written, the text says `prefer` fails only when the server refuses TLS.
I'd move this introduction out of the property list into an `### OAuth authentication` section after it (as with `### Unix sockets`), and open with: "OAuth authentication needs a verified server. Set `sslmode=verify-full` (or `verify-ca`), or use a GSS-encrypted connection. With the default `sslmode=prefer`, and with `require`, the driver refuses to send the token even when the connection uses TLS." The section would also hold the server prerequisites (PostgreSQL 18, an `oauth` rule in `pg_hba.conf`, a validator in `oauth_validator_libraries`), a URL example, a provider skeleton, a pooled setup, and the error texts, since none of the messages appears on the page.