Skip to content

Commit d4c3dff

Browse files
authored
Merge pull request #14158 from RasmusWL/fix-ssrf-example
Python: Fix typo in SSRF example
2 parents 334502a + c85ea9a commit d4c3dff

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

python/ql/src/Security/CWE-918/examples/ServerSideRequestForgery_full.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ def full_ssrf():
88
target = request.args["target"]
99

1010
# BAD: user has full control of URL
11-
resp = request.get("https://" + target + ".example.com/data/")
11+
resp = requests.get("https://" + target + ".example.com/data/")
1212

1313
# GOOD: `subdomain` is controlled by the server.
1414
subdomain = "europe" if target == "EU" else "world"
15-
resp = request.get("https://" + subdomain + ".example.com/data/")
15+
resp = requests.get("https://" + subdomain + ".example.com/data/")

0 commit comments

Comments
 (0)