oauth: Add TLS support for oauth_validator tests
Jacob Champion <jchampion@postgresql.org>
Author:
Jacob Champion <jchampion@postgresql.org>
Date: 2026-03-05T18:04:53Z
Releases:
19 (unreleased)
oauth: Add TLS support for oauth_validator tests The oauth_validator tests don't currently support HTTPS, which makes testing PGOAUTHCAFILE difficult. Add a localhost certificate to src/test/ssl and make use of it in oauth_server.py. In passing, explain the hardcoded use of IPv4 in our issuer identifier, after intermittent failures on NetBSD led to commit 8d9d5843b. (The new certificate is still set up for IPv6, to make it easier to improve that behavior in the future.) Patch by Jonathan Gonzalez V., with some additional tests and tweaks by me. Author: Jonathan Gonzalez V. <jonathan.abdiel@gmail.com> Discussion: https://postgr.es/m/8a296a2c128aba924bff0ae48af2b88bf8f9188d.camel@gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/test/modules/oauth_validator/Makefile | modified | +1 −0 |
| src/test/modules/oauth_validator/meson.build | modified | +1 −0 |
| src/test/modules/oauth_validator/t/001_server.pl | modified | +42 −9 |
| src/test/modules/oauth_validator/t/OAuth/Server.pm | modified | +3 −4 |
| src/test/modules/oauth_validator/t/oauth_server.py | modified | +20 −2 |
| src/test/ssl/conf/server-localhost-alt-names.config | added | +20 −0 |
| src/test/ssl/sslfiles.mk | modified | +1 −0 |
| src/test/ssl/ssl/server-localhost-alt-names.crt | added | +20 −0 |
| src/test/ssl/ssl/server-localhost-alt-names.key | added | +28 −0 |
Discussion
- [oauth] Add TLS support to OAuth tests 6 messages · 2026-02-27 → 2026-03-06