Skip to content

Commit 07587b7

Browse files
authored
Merge pull request #2604 from julianladisch/sslmode-verify-full
Show sslmode=verify-full, not sslmode=verify-ca, in example config
2 parents 140be86 + 8e7eda6 commit 07587b7

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

pgconn/config.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,10 +237,10 @@ func NetworkAddress(host string, port uint16) (network, address string) {
237237
// to only read from the environment. If a password is not supplied it will attempt to read the .pgpass file.
238238
//
239239
// # Example Keyword/Value
240-
// user=jack password=secret host=pg.example.com port=5432 dbname=mydb sslmode=verify-ca
240+
// user=jack password=secret host=pg.example.com port=5432 dbname=mydb sslmode=verify-full
241241
//
242242
// # Example URL
243-
// postgres://jack:secret@pg.example.com:5432/mydb?sslmode=verify-ca
243+
// postgres://jack:secret@pg.example.com:5432/mydb?sslmode=verify-full
244244
//
245245
// The returned *Config may be modified. However, it is strongly recommended that any configuration that can be done
246246
// through the connection string be done there. In particular the fields Host, Port, TLSConfig, and Fallbacks can be

pgxpool/pool.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -352,10 +352,10 @@ func NewWithConfig(ctx context.Context, config *Config) (*Pool, error) {
352352
// See Config for definitions of these arguments.
353353
//
354354
// # Example Keyword/Value
355-
// user=jack password=secret host=pg.example.com port=5432 dbname=mydb sslmode=verify-ca pool_max_conns=10 pool_max_conn_lifetime=1h30m
355+
// user=jack password=secret host=pg.example.com port=5432 dbname=mydb sslmode=verify-full pool_max_conns=10 pool_max_conn_lifetime=1h30m
356356
//
357357
// # Example URL
358-
// postgres://jack:secret@pg.example.com:5432/mydb?sslmode=verify-ca&pool_max_conns=10&pool_max_conn_lifetime=1h30m
358+
// postgres://jack:secret@pg.example.com:5432/mydb?sslmode=verify-full&pool_max_conns=10&pool_max_conn_lifetime=1h30m
359359
func ParseConfig(connString string) (*Config, error) {
360360
connConfig, err := pgx.ParseConfig(connString)
361361
if err != nil {

0 commit comments

Comments
 (0)