Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
setProperty/put
1 parent 0b7f0fb commit c867a1aCopy full SHA for c867a1a
1 file changed
java/ql/test/library-tests/dataflow/collections/Test.java
@@ -95,4 +95,16 @@ public void run5() {
95
sink(p.getProperty("key")); // Flow
96
sink(p.getProperty("key", "defaultValue")); // Flow
97
}
98
+
99
+ public void run6() {
100
+ Properties p = new Properties();
101
+ sink(p.put("key", tainted)); // No flow
102
+ sink(p.put("key", "notTainted")); // Flow
103
+ }
104
105
+ public void run7() {
106
107
+ sink(p.setProperty("key", tainted)); // No flow
108
+ sink(p.setProperty("key", "notTainted")); // Flow
109
110
0 commit comments