Skip to content

Commit

Permalink
Add use case for proxy to HTTPS using a PKCS12 client certificate
Browse files Browse the repository at this point in the history
  • Loading branch information
Radu Serbanescu authored and jcrugzz committed Apr 19, 2018
1 parent 48f372b commit 93e48b1
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions README.md
Expand Up @@ -265,6 +265,24 @@ httpProxy.createServer({
}).listen(443);
```

##### HTTP -> HTTPS (using a PKCS12 client certificate)

```js
//
// Create an HTTP proxy server with an HTTPS target
//
httpProxy.createProxyServer({
target: {
protocol: 'https:',
host: 'my-domain-name',
port: 443,
pfx: fs.readFileSync('path/to/certificate.p12'),
passphrase: 'password',
},
changeOrigin: true,
}).listen(8000);
```

**[Back to top](#table-of-contents)**

#### Proxying WebSockets
Expand Down

0 comments on commit 93e48b1

Please sign in to comment.