Skip to content

Commit 0c62916

Browse files
committed
Python: Highlight problem with Flask request.files modeling
1 parent 811a2c0 commit 0c62916

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

python/ql/test/library-tests/frameworks/flask/taint_test.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,7 @@ def test_taint(name = "World!", number="0", foo="foo"): # $requestHandler route
189189
a = request.args
190190
b = a
191191
gl = b.getlist
192+
files = request.files
192193
ensure_tainted(
193194
request.args, # $ tainted
194195
a, # $ tainted
@@ -202,6 +203,8 @@ def test_taint(name = "World!", number="0", foo="foo"): # $requestHandler route
202203
a.getlist('key'), # $ tainted
203204
b.getlist('key'), # $ tainted
204205
gl('key'), # $ tainted
206+
207+
files.get('key').filename, # $ MISSING: tainted
205208
)
206209

207210
# aliasing tests

0 commit comments

Comments
 (0)