Skip to content

Commit

Permalink
remove wildcard paths
Browse files Browse the repository at this point in the history
  • Loading branch information
hobinjk-ptc committed Sep 11, 2024
1 parent 378b1a6 commit 1d12344
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions server.js
Original file line number Diff line number Diff line change
Expand Up @@ -366,8 +366,8 @@ var cheerio = require('cheerio');

// use the cors cross origin REST model
webServer.use(cors());
// allow requests from all origins with '*'. TODO make it dependent on the local network. this is important for security
webServer.options('*', cors());
// allow requests from all origins with cors. TODO make it dependent on the local network. this is important for security
webServer.options(cors());

// Image resizing library, not available on mobile
let Jimp = null;
Expand Down Expand Up @@ -1632,7 +1632,7 @@ function objectWebServer() {
// check all server requests for being inside the netmask parameters.
// the netmask is set to local networks only.

webServer.use('*', function (req, res, next) {
webServer.use(function (req, res, next) {

var remoteIP = parseIpSpace(req.ip);
var localIP = parseIpSpace(services.ip);
Expand Down

0 comments on commit 1d12344

Please sign in to comment.