File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
python/ql/src/Security/CWE-918 Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 5
5
<recommendation >
6
6
7
7
<p >To guard against SSRF attacks you should avoid putting user-provided input directly
8
- into a request URL. Instead, either maintain a list of authorized URLs on the server and choose
9
- from that list based on the input provided, or perform proper validation of the input.
8
+ into a request URL. On the application level, maintain a list of authorized URLs on the server and choose
9
+ from that list based on the input provided. If that is not possible, one should verify the IP address for all user-controlled
10
+ requests to ensure they are not private. This requires saving the verified IP address of each domain,
11
+ then utilizing a custom HTTP adapter to ensure that future requests to that domain use the verified IP address.
12
+ On the network level, you can segment the vulnerable application into its own LAN or block access to specific devices.
10
13
</p >
11
14
12
15
</recommendation >
You can’t perform that action at this time.
0 commit comments