Set in one of the following ways when performing remote access using communication data encryption:
Specify "require", "verify-ca", or "verify-full" in the PGSSLMODE environment variable.
In addition, the parameters for the PGSSLROOTCERT and PGSSLCRL environment variables need to be set to prevent spoofing of the database server.
See
Refer to "Environment Variables" in "Client Interfaces" in the PostgreSQL Documentation for information on environment variables.
Specify "require", "verify-ca", or "verify-full" in the "sslmode" parameter of the connection URI.
In addition, the parameters for the sslcert, sslkey, sslrootcert, and sslcrl need to be set to prevent spoofing of the database server.
See
Refer to "Secure TCP/IP Connections with SSL" in "Server Administration" in the PostgreSQL Documentation for information on encrypting communication data.