Monday 12 June 2017

[Help] How to proxy an https website through a local node server? (like Charles Proxy does it)

For those not familiar with Charles - basically, it enables you to troubleshoot by intercepting https requests from deployed websites.I wish to achieve something similar in node, for automating some of the troubleshooting.It was a breeze to set it for http, but when trying to proxy https, Chrome throws either EMPTY_RESPONSE or PROXY_CONNECTION_FAILED errors.//importing + boilerplate app.get('*', (req, res) => { // works on http, nothing happens on https console.log('req', req); res.send('hello world'); }); httpServer.listen(8080); httpsServer.listen(8443);

Submitted June 12, 2017 at 07:56PM by GoosyTS

No comments:

Post a Comment