Skip to content

Commit df89739

Browse files
committed
Added test cases for open package.
1 parent a885e61 commit df89739

File tree

1 file changed

+11
-0
lines changed
  • javascript/ql/test/query-tests/Security/CWE-022/TaintedPath

1 file changed

+11
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import open, {openApp, apps} from 'open';
2+
3+
const express = require('express');
4+
const app = express();
5+
6+
app.get('/open', (req, res) => {
7+
const file = req.query.file; // $ MISSING: Source
8+
9+
open(file); // $ MISSING: Alert
10+
openApp(file); // $ MISSING: Alert
11+
});

0 commit comments

Comments
 (0)