diff --git a/src/Controllers/ImageLookup.js b/src/Controllers/ImageLookup.js index 16afdc9e..6a22c3de 100644 --- a/src/Controllers/ImageLookup.js +++ b/src/Controllers/ImageLookup.js @@ -6,15 +6,15 @@ class ImageLookup { /* File Traversal exploit */ /* Can read any file in the server by passing the filename (image) in the query params */ /* ex: http GET http://localhost:8089/api/v1/image-lookup image=="package.json" */ - const fileContent = fs.readFileSync(req.query.image).toString(); + //const fileContent = fs.readFileSync(req.query.image).toString(); logger.debug(fileContent); - res.send(fileContent); + //res.send(fileContent); } - function sanitizeString(str){ + /* function sanitizeString(str){ str = str.replace(/[^a-z0-9áéíóúñü \.,_-]/gim,""); return str.trim(); - } + }*/ } module.exports = ImageLookup;