Skip to content

Commit 9ba43f2

Browse files
committed
fix(security): bind Semgrep ignore to guarded sink line
1 parent cb50c8a commit 9ba43f2

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

‎scripts/ci/codeql_ghas_configuration_identity.py‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,7 @@ def _request_json(url: str, *, token: str, timeout_seconds: int) -> Any:
179179
try:
180180
# The authority guard above is the executable proof. Semgrep/Bandit do
181181
# not model that predicate and otherwise flag every dynamic Request.
182-
# nosemgrep: python.lang.security.audit.dynamic-urllib-use-detected.dynamic-urllib-use-detected
183-
with urllib.request.urlopen( # noqa: S310 # nosec B310
182+
with urllib.request.urlopen( # noqa: S310 # nosec B310 # nosemgrep: python.lang.security.audit.dynamic-urllib-use-detected.dynamic-urllib-use-detected
184183
request,
185184
timeout=timeout_seconds,
186185
) as response:

0 commit comments

Comments
 (0)