Skip to content

Commit d8df3ff

Browse files
author
Alvaro Muñoz
committed
Use ControlCheck.dominates in the ImproperAccessControl query
1 parent 9977f25 commit d8df3ff

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

ql/src/Security/CWE-285/ImproperAccessControl.ql

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,6 @@ where
2020
job.getATriggerEvent() = event and
2121
event.getName() = "pull_request_target" and
2222
event.getAnActivityType() = "synchronize" and
23-
job.getAStep() = checkout and
24-
(
25-
checkout.getIf() = check
26-
or
27-
checkout.getEnclosingJob().getIf() = check
28-
)
29-
select checkout, "The checked-out code can be changed after the authorization check o step $@.",
30-
check, check.toString()
23+
check.dominates(checkout)
24+
select checkout, "The checked-out code can be modified after the authorization check $@.", check,
25+
check.toString()

0 commit comments

Comments
 (0)