Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Vendor: PostgreSQL Global Development Group · https://www.postgresql.org/ · pkg:generic/postgresql · Last reviewed 2026-12-05 · History

Summary

  • The server setting ssl_groups (ssl_ecdh_curve before 18) defaults to X25519:prime256v1 in 18 and 19, with no hybrid group, so key agreement is classical without configuration (checked 2026-12-05).12
  • The documentation does not list a hybrid group such as X25519MLKEM768 as an ssl_groups value; whether a given OpenSSL accepts it there is not documented (checked 2026-12-05).1
  • Classical groups can be disabled by replacing the ssl_groups list.1
  • The libpq client has no option for key agreement groups (checked 2026-12-05).3
  • PostgreSQL 19 (2026-11-19) release notes mention no TLS or SSL settings; no post-quantum statement from the project was found (checked 2026-12-05).4

To restrict key agreement, replace the list in postgresql.conf (ssl_groups = 'X25519MLKEM768'), noting every connecting client must support the listed groups and this value is untested.1

No client-side group selection is possible: the libpq documentation for 18 and 19 shows no group option (checked 2026-12-05).3

Cryptographic operations

  • Server (TLS server): ssl_groups is “the named group to use for TLS key exchange. It needs to be supported by all clients that connect. Multiple groups can be specified by using a colon-separated list.” Default X25519:prime256v1 (X25519 and NIST P-256); set only in postgresql.conf or on the command line.1
  • ssl_min_protocol_version defaults to TLSv1.2; ssl_tls13_ciphers and ssl_ciphers are symmetric choices, not covered here.1
  • Client library (libpq): parameters include sslmode, sslcert, sslkey, sslrootcert, ssl_min_protocol_version, ssl_max_protocol_version; groups offered are those of the linked OpenSSL.3
  • Certificates: X.509 certificates configured by file; documented signature algorithms not checked (2026-12-05).

Versions

Change Version Date Package URL Source
ssl_ecdh_curve takes one curve, default prime256v1 17 and earlier   pkg:generic/postgresql@17 5
ssl_ecdh_curve renamed ssl_groups, accepts a colon-separated list; default includes X25519; ssl_tls13_ciphers added 18 2025-09-25 pkg:generic/postgresql@18 12
ssl_groups documents that X25519 must be removed when OpenSSL is in FIPS mode 19 2026-11-19 pkg:generic/postgresql@19 6

18 release notes: “Rename server variable ssl_ecdh_curve to ssl_groups and allow multiple colon-separated ECDH curves to be specified”.2

Configuration

Enabling PQC

No release has a default hybrid group. With OpenSSL 3.5 or later the group could be listed, but this is undocumented and untested (2026-12-05); it matters only if the client also offers it:1

ssl_groups = 'X25519MLKEM768:X25519:prime256v1'

Disabling classical algorithms

ssl_groups = 'X25519MLKEM768'

A client offering none of the listed groups cannot connect.1

Open work

No issue or proposal for a libpq group option was found; mailing list archives not searched (2026-12-05).

Distributions

Official Docker images, checked 2026-12-05. The Dockerfiles state no OpenSSL version; see Debian and Alpine for each base.

Image PostgreSQL Base Source
postgres:19 (Debian variant) 19.0, from the PGDG apt repository debian:trixie-slim 7
postgres:19-alpine 19.0, built from source with --with-openssl (installs Alpine openssl-dev) alpine:3.25 8

References

  1. PostgreSQL 18 documentation, 19.3 Connections and Authentication (ssl_groups, ssl_min_protocol_version). https://www.postgresql.org/docs/18/runtime-config-connection.html (accessed 2026-12-05) ↩ ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9

  2. PostgreSQL 18 release notes, 2025-09-25. https://www.postgresql.org/docs/18/release-18.html (accessed 2026-12-05) ↩ ↩2 ↩3

  3. PostgreSQL 18 documentation, 32.1 Database Connection Control Functions. https://www.postgresql.org/docs/18/libpq-connect.html (accessed 2026-12-05) ↩ ↩2 ↩3

  4. PostgreSQL 19 release notes, 2026-11-19. https://www.postgresql.org/docs/19/release-19.html (accessed 2026-12-05) ↩

  5. PostgreSQL 17 documentation, 19.3 Connections and Authentication (ssl_ecdh_curve). https://www.postgresql.org/docs/17/runtime-config-connection.html (accessed 2026-12-05) ↩

  6. PostgreSQL 19 documentation, 19.3 Connections and Authentication. https://www.postgresql.org/docs/current/runtime-config-connection.html (accessed 2026-12-05). The note reads: “X25519 is not allowed when OpenSSL is configured for FIPS mode and must be removed from the server configuration when FIPS mode is enabled.” ↩

  7. docker-library/postgres, 19/trixie/Dockerfile at commit d01214e. https://github.com/docker-library/postgres/blob/d01214e73b32f5c9795c54fc70ee169fbb9ea03d/19/trixie/Dockerfile (accessed 2026-12-05) ↩

  8. docker-library/postgres, 19/alpine3.25/Dockerfile at commit d01214e. https://github.com/docker-library/postgres/blob/d01214e73b32f5c9795c54fc70ee169fbb9ea03d/19/alpine3.25/Dockerfile (accessed 2026-12-05) ↩


Edit: PostgreSQL

If you give an email address it is recorded publicly as the author of the commit, and GitHub will link the commit to your account if that address belongs to one.

Edits are reviewed before they appear. By submitting you release your contribution under CC BY-SA 4.0. Read the editorial guidelines first.

This site uses Just the Docs, a documentation theme for Jekyll.