deftest1():requests.get("https://api.tld")requests.get("https://api.tld/user/{0}".format(user_id))requests.get(f"https://api.tld/user/{user_id}")requests.get(f"http://localhost.tld/user/{user_id}")# localhost and 127.0.0.1 are safe
Seamless integrations. Try Datadog Code Security
Datadog Code Security
Try this rule and analyze your code with Datadog Code Security
How to use this rule
1
2
rulesets:- python-security # Rules to enforce Python security.
Create a static-analysis.datadog.yml with the content above at the root of your repository
Use our free IDE Plugins or add Code Security scans to your CI pipelines