Skip to content

Commit 0689e60

Browse files
committed
make a type more specific
1 parent ed708c1 commit 0689e60

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

ql/lib/codeql/ruby/security/ReflectedXSSCustomizations.qll

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,11 +137,10 @@ module ReflectedXSS {
137137
// instance variables in the controller
138138
exists(
139139
ActionControllerActionMethod action, VariableReadAccess viewVarRead, AssignExpr ae,
140-
VariableWriteAccess controllerVarWrite
140+
InstanceVariableWriteAccess controllerVarWrite
141141
|
142142
viewVarRead = node2.asExpr().(CfgNodes::ExprNodes::VariableReadAccessCfgNode).getExpr() and
143143
action.getDefaultTemplateFile() = viewVarRead.getLocation().getFile() and
144-
controllerVarWrite.getVariable() instanceof InstanceVariable and
145144
// match read to write on variable name
146145
viewVarRead.getVariable().getName() = controllerVarWrite.getVariable().getName() and
147146
// TODO: include only final assignment along a path

0 commit comments

Comments
 (0)