pg 8.4.1 → 8.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/client.js CHANGED
@@ -57,6 +57,15 @@ class Client extends EventEmitter {
57
57
  this.processID = null
58
58
  this.secretKey = null
59
59
  this.ssl = this.connectionParameters.ssl || false
60
+ // As with Password, make SSL->Key (the private key) non-enumerable.
61
+ // It won't show up in stack traces
62
+ // or if the client is console.logged
63
+ if (this.ssl && this.ssl.key) {
64
+ Object.defineProperty(this.ssl, 'key', {
65
+ enumerable: false,
66
+ })
67
+ }
68
+
60
69
  this._connectionTimeoutMillis = c.connectionTimeoutMillis || 0
61
70
  }
62
71
 
@@ -84,6 +84,11 @@ class ConnectionParameters {
84
84
  if (this.ssl === 'no-verify') {
85
85
  this.ssl = { rejectUnauthorized: false }
86
86
  }
87
+ if (this.ssl && this.ssl.key) {
88
+ Object.defineProperty(this.ssl, 'key', {
89
+ enumerable: false,
90
+ })
91
+ }
87
92
 
88
93
  this.client_encoding = val('client_encoding', config)
89
94
  this.replication = val('replication', config)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pg",
3
- "version": "8.4.1",
3
+ "version": "8.4.2",
4
4
  "description": "PostgreSQL client - pure javascript & libpq with the same API",
5
5
  "keywords": [
6
6
  "database",
@@ -22,7 +22,7 @@
22
22
  "buffer-writer": "2.0.0",
23
23
  "packet-reader": "1.0.0",
24
24
  "pg-connection-string": "^2.4.0",
25
- "pg-pool": "^3.2.1",
25
+ "pg-pool": "^3.2.2",
26
26
  "pg-protocol": "^1.3.0",
27
27
  "pg-types": "^2.1.0",
28
28
  "pgpass": "1.x"
@@ -52,5 +52,5 @@
52
52
  "engines": {
53
53
  "node": ">= 8.0.0"
54
54
  },
55
- "gitHead": "36342c9a84b68123f666879a9f34ac319a44727a"
55
+ "gitHead": "b6d69d5bc2eb7df4f4e04bc864b133b795c76a7f"
56
56
  }