From c44cbb12abeeb06e298b8a86aa207963d53de96e Mon Sep 17 00:00:00 2001 From: Jack Christensen Date: Fri, 21 Aug 2015 13:50:06 -0500 Subject: [PATCH] Add sslmode note for ParseDSN --- conn.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/conn.go b/conn.go index 7d5e7f66..57450da7 100644 --- a/conn.go +++ b/conn.go @@ -309,6 +309,10 @@ var dsn_regexp = regexp.MustCompile(`([a-z]+)=((?:"[^"]+")|(?:[^ ]+))`) // ParseDSN parses a database DSN (data source name) into a ConnConfig // // e.g. ParseDSN("user=username password=password host=1.2.3.4 port=5432 dbname=mydb sslmode=disable") +// +// ParseDSN tries to match libpq behavior with regard to sslmode. See comments +// for ParseEnvLibpq for more information on the security implications of +// sslmode options. func ParseDSN(s string) (ConnConfig, error) { var cp ConnConfig