File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
java/ql/src/Security/CWE/CWE-022 Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -41,12 +41,12 @@ such as "/etc/passwd".</p>
41
41
<sample src =" TaintedPath.java" />
42
42
43
43
<p >Simply checking that the path is under a trusted location (such as a known public folder) is not enough,
44
- however, since the path could contain relative components such as "..". To fix this, we check that the it does
44
+ however, since the path could contain relative components such as "..". To fix this, check that it does
45
45
not contain ".." and starts with the public folder.</p >
46
46
47
47
<sample src =" TaintedPathGood.java" />
48
48
49
- <p >Alternatively, if we only want to allow simple filenames without a path component, we can remove all path
49
+ <p >Alternatively, if you only want to allow simple filenames without a path component, you can remove all path
50
50
separators ("/" or "\") and all ".." sequences from the input before using it to construct a file path.</p >
51
51
52
52
<sample src =" TaintedPathGood2.java" />
You can’t perform that action at this time.
0 commit comments