spdy-http2 / node-spdy

SPDY server on Node.js
2.81k stars 196 forks source link

Use .pfx file #340

Closed preraksola closed 6 years ago

preraksola commented 6 years ago

Is there a way that I can use a ".pfx" file instead of ".cer" and ".key"? I could not find anything related to this in the documentation.

Thank you.

danrzeppa commented 6 years ago

As noted towards the bottom of the readme

All options supported by tls work with node-spdy.

Which means that instead of using the cert and key options, you can use the pfx and passphrase options.

var options: {
  pfx: fs.readFileSync(__dirname + '/keys/spdy.pfx'),
  passphrase: 'spdypass'
}
preraksola commented 6 years ago

Okay, got it. Thanks 👍