Skip to content

security: language-scope high_risk_execution alternatives (Part of #5463) - #5508

Merged
squid-protocol merged 2 commits into
mainfrom
churn/5463-20261018T1702Z
Oct 18, 2026
Merged

squid-protocol merged 2 commits into
mainfrom
churn/5463-20261018T1702Z

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #5463

SecurityLens.THREAT_SIGNATURES["high_risk_execution"] is one language-blind alternation. It now has a scope table (HIGH_RISK_EXECUTION_SCOPE): the first rule matching the start of a hit decides which languages it applies to, and scan_content(..., language=) drops the rest (also in the minified fast-screen). galaxyscope.py passes lang_id. Unknown language (None) or an unclaimed hit keeps the old behaviour.

Class table (every alternative)

Alternative Languages Fixture
BPXBATCH / IKJEFT01 / IRXJCL mainframe family, shell, yaml, assembly jcl fires, java clean
EXEC CICS START/LINK/XCTL mainframe family, c, cpp, assembly cobol fires
eval() dynamic langs (JS family, php, python, ruby, perl, lua, shell, ...) python fires, c clean
Function / setTimeout / setInterval / document.write / location.replace JS family rust, c clean
create_function / passthru / shell_exec php cpp clean
system( c, cpp, objc, php, perl, ruby, python, matlab, tcl, lua, fortran, shell go clean, c fires
assert("..") / assert($..) php cpp clean
child_process.*, window.. JS family java clean
$f($_POST) php c clean
getattr(import, importlib, builtins[ python c/cpp clean
require(var) JS family, php, ruby, perl C/C++ require( x ), asio::require(e, ...), Lua clean; Node fires
Assembly.Load csharp, powershell java clean
${{ github.event.* }} yaml, markdown yaml fires

Golden masters

Re-blessed (both legs, golden-lock.sh crucible_check.py --update --yes). All ~240 diffs are Dynamic Code Execution counts falling: false positives removed, e.g. Kotlin require( preconditions (okhttp), Dart Function( type, Python assert ( + string, DB2 SYSTEM( in JCL, PHP function ($x) closures (laravel), Lua require/eval.

Gates

pr_gates --fast 6/6, --ratchets 8/8 pass; tests/security_auditing, test_galaxyscope.py, gate-parity pass.

Sibling gaps

None found in the SecurityLens signature table. (Note: Function\s*\( is re.I, so JS function ($x) still matches; unchanged, not language-related.)

Remaining slices

None: acceptance met. Other THREAT_SIGNATURES keys (io, state_mutation, reflection_metaprogramming) are equally unscoped; not touched here.

🤖 Generated with Claude Code

squid-protocol and others added 2 commits October 18, 2026 13:23
#5463)

Each alternative declares the languages it is an execution vector in; scan_content
takes the file language and drops the rest (unknown language keeps old behaviour).
C/C++ require( x ), asio::require(e, ...), Lua require(...) no longer fire.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Oct 18, 2026
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol marked this pull request as ready for review October 18, 2026 17:49
@squid-protocol
squid-protocol enabled auto-merge (squash) October 18, 2026 17:53
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-protocol
squid-protocol merged commit 5a4b7da into main Oct 18, 2026
68 checks passed
@squid-protocol
squid-protocol deleted the churn/5463-20261018T1702Z branch October 18, 2026 18:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant