title: pg 7.18.0 in node js not working, throwing: Implicit disabling of certificate verification is deprecated and will be removed in pg 8
body: <p>I have a nodejs app with express that connects  with <a href="https://www.npmjs.com/package/pg" rel="nofollow noreferrer">pg</a> to a database in RDS on AWS. The connection to the database is done with the following database url:</p>
  
  <pre><code>postgres://user:pasword@host.amazonaws.com:port/database?ssl=true
  </code></pre>
  
  <p>After the new release of pg version 7.18.0, our server failed to connect to the database throwing the following error:</p>
  
  <pre><code>error: unsupported frontend protocol 1234.5679: server supports 2.0 to 3.0
  at Connection.parseE (/var/app/current/node_modules/pg/lib/connection.js:624:13)
  at Connection.parseMessage (/var/app/current/node_modules/pg/lib/connection.js:423:19)
  at TLSSocket. (/var/app/current/node_modules/pg/lib/connection.js:139:22)
  at TLSSocket.emit (events.js:198:13)
  at TLSSocket.EventEmitter.emit (domain.js:448:20)
  at addChunk (_stream_readable.js:288:12)
  at readableAddChunk (_stream_readable.js:269:11)
  at TLSSocket.Readable.push (_stream_readable.js:224:10)
  at TLSWrap.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
  
  DeprecationWarning: Implicit disabling of certificate verification is 
  deprecated and will be removed in pg 8. Specify rejectUnauthorized: true to 
  require a valid CA or rejectUnauthorized: false to explicitly opt out of MITM 
  protection.
  </code></pre>
  
  <p>If I remove the "ssl=true" part from the database url it works, but that would mean there connection is not secure, right?</p>
  
  <p>If I go back to use the 7.17.x version my problem is fixed, however I would like to understand if i am connecting to the database correctly? Should I add more parameters to the database url? I am missing something else or is it an issue with pg?</p>
  
  <p>I opened up an <a href="https://github.com/brianc/node-postgres/issues/2089" rel="nofollow noreferrer">issue on github, link to the issue</a></p>