Skip to content

Commit 664c5e6

Browse files
committed
add [INCONSISTENCY] comment in CodeInjection test
1 parent 442ee8d commit 664c5e6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

javascript/ql/test/query-tests/Security/CWE-094/CodeInjection/NoSQLCodeInjection.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ app.post("/documents/find", (req, res) => {
1414
MongoClient.connect("mongodb://localhost:27017/test", (err, db) => {
1515
let doc = db.collection("doc");
1616

17-
doc.find(query); // NOT OK, but that is flagged by js/sql-injection
17+
doc.find(query); // NOT OK, but that is flagged by js/sql-injection [INCONSISTENCY]
1818
doc.find({ $where: req.body.query }); // NOT OK
1919
doc.find({ $where: "name = " + req.body.name }); // NOT OK
2020
});

0 commit comments

Comments
 (0)