mirror of
https://github.com/github/codeql.git
synced 2026-07-21 11:18:20 +02:00
- `KnownCVEs` contain the currently triaged Python CVEs - `unittest.py` contains some tests constructed by @erik-krogh - `redos.py` contains a port of `tst.js` from javascript The expected file has been ported as well with some fixups by @tausbn
10 lines
231 B
Python
10 lines
231 B
Python
import re
|
|
|
|
# Treatment of escapes
|
|
re.compile(r"X([^\.]|\.)*$") # No ReDoS.
|
|
re.compile(r"X(Æ|\Æ)+$") # Has ReDoS.
|
|
|
|
# Treatment of line breaks
|
|
re.compile(r'(?:.|\n)*b') # No ReDoS.
|
|
re.compile(r'(?:.|\n)*b', re.DOTALL) # Has ReDoS.
|