Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 607b184

Browse files
committed
JS: Fix a bug in test case
1 parent 51fb3da commit 607b184

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • javascript/ql/test/query-tests/Security/CWE-400/ReDoS

javascript/ql/test/query-tests/Security/CWE-400/ReDoS/tst.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ var bad24 = /(?:=(?:([!#\$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+)|"((?:\\[\x00-\x7f]|[^\x
102102
var bad25 = /"((?:\\[\x00-\x7f]|[^\x00-\x08\x0a-\x1f\x7f"])*)"/; // $ Alert
103103

104104

105-
var bad26 = /"((?:\\[\x00-\x7f]|[^\x00-\x08\x0a-\x1f\x7f"\\])*)"/;
105+
var fix25 = /"((?:\\[\x00-\x7f]|[^\x00-\x08\x0a-\x1f\x7f"\\])*)"/; // OK - fixed version of bad25
106106

107107
var bad27 = /(([a-z]|[d-h])*)"/; // $ Alert
108108

0 commit comments

Comments
 (0)