Reputation: 1121
How Do I create a user authenticated by "public/private key" in Postgresql and not with a password
Upvotes: 3
Views: 3432
Reputation: 247865
You should read the documentation that describes that in detail:
set up SSL on the server with the ssl
, ssl_cert_file
and ssl_key_file
parameters
configure a CA certificate on the server with the ssl_ca_file
parameter
add a pg_hba.conf
entry starting with hostssl
with the authentication method cert
on the client, use the sslcert
and sslkey
connection parameters to specify the certificate and private key to use
Upvotes: 4