Skip to content

Commit 94750fc

Browse files
committed
Python: Add test-cases for py/hardcoded-credentials
1 parent b92782d commit 94750fc

File tree

1 file changed

+11
-0
lines changed
  • python/ql/test/query-tests/Security/CWE-798

1 file changed

+11
-0
lines changed

python/ql/test/query-tests/Security/CWE-798/test.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,14 @@ def sell(client, units):
1717
conn.cmd("sell", 1000)
1818
conn.close()
1919

20+
21+
# Ignored
22+
test(password='short')
23+
test(password='Capitalized')
24+
test(password=' whitespace') # too much whitespace
25+
test(password='insecure__') # too many underscores
26+
test(password='aaaaaaaaaa') # too repetitive
27+
test(password='format_string_{}')
28+
29+
# TODO: we think this is a format string :\
30+
test(password='''U]E8FPETCS_]{,y>bgyzh^$yC5>SP{E*2=`;3]G~k&+;khy3}4]jdpu;D(aP$SCFA{;hh4n46pUJ%+$nEP_gqNq#X!2$%*C-6y6%''')

0 commit comments

Comments
 (0)