File tree Expand file tree Collapse file tree
lib/semmle/code/csharp/security/dataflow
Security Features/CWE-114 Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ module ConditionalBypass = TaintTracking::Global<ConditionalBypassConfig>;
6565 *
6666 * A source of remote user input.
6767 */
68- class RemoteSource extends Source instanceof RemoteFlowSource { }
68+ deprecated class RemoteSource extends Source instanceof RemoteFlowSource { }
6969
7070/** A source supported by the current threat model. */
7171class ThreatModelSource extends Source instanceof ThreatModelFlowSource { }
Original file line number Diff line number Diff line change 1313 */
1414
1515import csharp
16- import semmle.code.csharp.security.dataflow.flowsources.Remote
16+ import semmle.code.csharp.security.dataflow.flowsources.FlowSources
1717import semmle.code.csharp.commons.Util
1818import AssemblyPathInjection:: PathGraph
1919
@@ -22,7 +22,7 @@ import AssemblyPathInjection::PathGraph
2222 */
2323module AssemblyPathInjectionConfig implements DataFlow:: ConfigSig {
2424 predicate isSource ( DataFlow:: Node source ) {
25- source instanceof RemoteFlowSource or
25+ source instanceof ThreatModelFlowSource or
2626 source .asExpr ( ) = any ( MainMethod main ) .getParameter ( 0 ) .getAnAccess ( )
2727 }
2828
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ import csharp
22import semmle.code.csharp.frameworks.system.Net
33import semmle.code.csharp.frameworks.System
44import semmle.code.csharp.security.dataflow.flowsources.Remote
5+ import semmle.code.csharp.security.dataflow.flowsources.FlowSources
56import semmle.code.csharp.security.Sanitizers
67
78//If this leaves experimental this should probably go in semmle.code.csharp.frameworks.system.Net
@@ -68,8 +69,15 @@ private module TaintedWebClientConfig implements DataFlow::ConfigSig {
6869 */
6970module TaintedWebClient = TaintTracking:: Global< TaintedWebClientConfig > ;
7071
71- /** A source of remote user input. */
72- class RemoteSource extends Source instanceof RemoteFlowSource { }
72+ /**
73+ * DEPRECATED: Use `ThreatModelSource` instead.
74+ *
75+ * A source of remote user input.
76+ */
77+ deprecated class RemoteSource extends Source instanceof RemoteFlowSource { }
78+
79+ /** A source supported by the current threat model. */
80+ class ThreatModelSource extends Source instanceof ThreatModelFlowSource { }
7381
7482/**
7583 * A path argument to a `WebClient` method call that has an address argument.
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ module RequestForgery {
66 import semmle.code.csharp.frameworks.system.Web
77 import semmle.code.csharp.frameworks.Format
88 import semmle.code.csharp.security.dataflow.flowsources.Remote
9+ import semmle.code.csharp.security.dataflow.flowsources.FlowSources
910
1011 /**
1112 * A data flow source for server side request forgery vulnerabilities.
@@ -91,10 +92,9 @@ module RequestForgery {
9192 module RequestForgeryFlow = DataFlow:: Global< RequestForgeryFlowConfig > ;
9293
9394 /**
94- * A remote data flow source taken as a source
95- * for Server Side Request Forgery(SSRF) Vulnerabilities.
95+ * A dataflow source for Server Side Request Forgery(SSRF) Vulnerabilities.
9696 */
97- private class RemoteFlowSourceAsSource extends Source instanceof RemoteFlowSource { }
97+ private class ThreatModelSource extends Source instanceof ThreatModelFlowSource { }
9898
9999 /**
100100 * An url argument to a `HttpRequestMessage` constructor call
You can’t perform that action at this time.
0 commit comments