File tree Expand file tree Collapse file tree 1 file changed +12
-12
lines changed
csharp/ql/src/utils/model-generator/internal Expand file tree Collapse file tree 1 file changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -107,24 +107,24 @@ string qualifierString() { result = "Argument[Qualifier]" }
107
107
bindingset [ kind]
108
108
predicate isRelevantSinkKind ( string kind ) { any ( ) }
109
109
110
+ private predicate isRelevantMemberAccess ( DataFlow:: Node node ) {
111
+ exists ( CS:: MemberAccess access | access = node .asExpr ( ) |
112
+ access .hasThisQualifier ( ) and
113
+ access .getTarget ( ) .isEffectivelyPublic ( ) and
114
+ (
115
+ access instanceof CS:: FieldAccess
116
+ or
117
+ access .getTarget ( ) .( CS:: Property ) .getSetter ( ) .isPublic ( )
118
+ )
119
+ )
120
+ }
121
+
110
122
/**
111
123
* Language specific parts of the `PropagateToSinkConfiguration`.
112
124
*/
113
125
class PropagateToSinkConfigurationSpecific extends CS:: TaintTracking:: Configuration {
114
126
PropagateToSinkConfigurationSpecific ( ) { this = "parameters or fields flowing into sinks" }
115
127
116
- private predicate isRelevantMemberAccess ( DataFlow:: Node node ) {
117
- exists ( CS:: MemberAccess access | access = node .asExpr ( ) |
118
- access .hasThisQualifier ( ) and
119
- access .getTarget ( ) .isEffectivelyPublic ( ) and
120
- (
121
- access instanceof CS:: FieldAccess
122
- or
123
- access .getTarget ( ) .( CS:: Property ) .getSetter ( ) .isPublic ( )
124
- )
125
- )
126
- }
127
-
128
128
override predicate isSource ( DataFlow:: Node source ) {
129
129
( isRelevantMemberAccess ( source ) or source instanceof DataFlow:: ParameterNode ) and
130
130
isRelevantForModels ( source .getEnclosingCallable ( ) )
You can’t perform that action at this time.
0 commit comments