From 4f459505c8b450e3aac8d918a398dfac21266fa6 Mon Sep 17 00:00:00 2001 From: Robert Gagnon Date: Thu, 16 Aug 2018 13:31:58 -0400 Subject: [PATCH] Ensured that traffic forwarded to the local HTTPS server instances uses localhost as the IP hostname --- lib/requestHandler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/requestHandler.js b/lib/requestHandler.js index 7f664c870..b24980184 100644 --- a/lib/requestHandler.js +++ b/lib/requestHandler.js @@ -623,7 +623,7 @@ function getConnectReqHandler(userRule, recorder, httpsServerMgr) { // for ws request, redirect them to local ws server return interceptWsRequest ? localHttpServer : originServer; } else { - return httpsServerMgr.getSharedHttpsServer(host).then(serverInfo => ({ host: serverInfo.host, port: serverInfo.port })); + return httpsServerMgr.getSharedHttpsServer(host).then(serverInfo => ({ host: 'localhost', port: serverInfo.port })); } }) .then((serverInfo) => {