File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed
java/ql/lib/semmle/code/java Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change 33 */
44
55import Member
6+ import semmle.code.java.security.ExternalProcess
67private import semmle.code.java.dataflow.FlowSteps
78
89// --- Standard types ---
@@ -197,6 +198,39 @@ class TypeFile extends Class {
197198}
198199
199200// --- Standard methods ---
201+ /**
202+ * DEPRECATED: Any constructor of class `java.lang.ProcessBuilder`.
203+ */
204+ deprecated class ProcessBuilderConstructor extends Constructor , ExecCallable {
205+ ProcessBuilderConstructor ( ) { this .getDeclaringType ( ) instanceof TypeProcessBuilder }
206+
207+ override int getAnExecutedArgument ( ) { result = 0 }
208+ }
209+
210+ /**
211+ * DEPRECATED: Any of the methods named `command` on class `java.lang.ProcessBuilder`.
212+ */
213+ deprecated class MethodProcessBuilderCommand extends Method , ExecCallable {
214+ MethodProcessBuilderCommand ( ) {
215+ this .hasName ( "command" ) and
216+ this .getDeclaringType ( ) instanceof TypeProcessBuilder
217+ }
218+
219+ override int getAnExecutedArgument ( ) { result = 0 }
220+ }
221+
222+ /**
223+ * DEPRECATED: Any method named `exec` on class `java.lang.Runtime`.
224+ */
225+ deprecated class MethodRuntimeExec extends Method , ExecCallable {
226+ MethodRuntimeExec ( ) {
227+ this .hasName ( "exec" ) and
228+ this .getDeclaringType ( ) instanceof TypeRuntime
229+ }
230+
231+ override int getAnExecutedArgument ( ) { result = 0 }
232+ }
233+
200234/**
201235 * Any method named `getenv` on class `java.lang.System`.
202236 */
You can’t perform that action at this time.
0 commit comments