From e873bc03ee34de60b4068df92f038d3e76aefe83 Mon Sep 17 00:00:00 2001 From: Dorian Niemiec Date: Mon, 14 Aug 2023 19:39:59 +0200 Subject: [PATCH] Prevent configuration leakage in Windows --- index.js | 2 +- mod.info | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 19776c4..a1d2614 100644 --- a/index.js +++ b/index.js @@ -260,7 +260,7 @@ Mod.prototype.callback = function (req, res, serverconsole, responseEnd, href, e callServerError(500, "OrangeCircle/" + version, ex); } } - } else if (href == "/orangecircle-config.json" && path.normalize(__dirname + "/../../..") == process.cwd()) { + } else if ((href == "/orangecircle-config.json" || (os.platform() == "win32" && href.toLowerCase() == "/orangecircle-config.json")) && path.normalize(__dirname + "/../../..") == process.cwd()) { if (!callServerError) { res.writeHead(200, "OK", { "Content-Type": "application/json", diff --git a/mod.info b/mod.info index b842d77..d34c4e0 100755 --- a/mod.info +++ b/mod.info @@ -1,4 +1,4 @@ { "name": "DorianTech OrangeCircle SCGI client for SVR.JS", - "version": "1.0.1" + "version": "1.0.2" }