Skip to content

Supply-chain firewall enforcement gaps: manifest flags, package.json hooks, node_modules, test-path skip, secrets-only gate #8432

Closed

Description

@squid-protocol

Part of #8427. Source: the security claims audit in #8426 (docs/security_claims_inventory.md, "Most serious problems" #6). This is the class issue for what the firewall enforces even once the CLI reads the right keys (the CLI key mismatch is its own issue in this epic).

Class: every enforcement gap between the firewall's documented scope and its code

Docs claiming the broader scope: supply_chain_security/README.md:7,16,30,33,40,41, tools/README.md:46,72, enforce-supply-chain-firewall.md, 04-03. Each member below is verified against origin/main + the audit doc.

Member Status Evidence
manifest_parser INSECURE_REGISTRY_* (http registry, ngrok, localtunnel), direct-URI / VCS / file refs: flags are written into the resolution map, nothing reads them as findings missing enforcement written at gitgalaxy/security/manifest_parser.py:181-185,273; grep finds no reader in supply_chain_firewall.py. The comment at :184 says the firewall "can instantly block it". Detection is tested (tests/core_engine/test_manifest_parser.py), enforcement is not
package.json is skipped by the inert-extension shield (.json in the set) before the 10x build-script multiplier is applied, so npm preinstall / postinstall / install scripts are never read missing shield at supply_chain_firewall.py:183-196; multiplier at :210-223 names only setup.py, build.rs, preinstall.js, postinstall.js; the comment at :210 names package.json
node_modules, vendor, venv, .venv are excluded from scans, so the firewall never sees third-party dependency files, contradicting "scans every dependency file inside node_modules/venv" missing (docs wrong, or scope needs a mode) gitgalaxy/standards/gitgalaxy_config.py:191,212-213
Paths containing /test/, /tests/, or a filename containing test_ or _test are skipped by substring, so malware placed in tests/ or named x_test.py / test_x.py bypasses the gate; not disclosed evasion path supply_chain_firewall.py:196-207
The behavioural gate reads only secrets_risk (_FIREWALL_RISK_MAP); no network, I/O-hook, install-hook, typosquat, homoglyph or steganography input partial: docs claim far more supply_chain_firewall.py:30-36; docs/vectors.md marks the vector REWORK
Import verification (blacklist, strict allowlist, alias deref) handled in the engine path; broken in the CLI see the CLI issue in this epic
Centrality multiplier handled, off by default (FIREWALL_NETWORK_WEIGHTING), undisclosed supply_chain_firewall.py:225-240; test_network_weighting_*
setup.py / build.rs / *install.js 10x multiplier handled (secrets risk only) test_build_time_execution_multiplier

Typosquat radar in the engine only logs (not a gate); noted as out of scope here, a separate decision if wanted.

Acceptance

Every member is either enforced (test with a planted case and a near-miss) or the docs list it as not enforced:

  • Manifest flags: the firewall reads them and reports them as threats (strict and audit mode), or the docs say "logged only". Test: a requirements.txt / package.json with an http:// registry, ngrok URL and git/file ref.
  • package.json: lifecycle scripts (preinstall, install, postinstall, prepare) are parsed and treated as build-time execution, with a test planting a curl | sh postinstall and a near-miss with a benign "build": "tsc".
  • Test-path skip: replace the substring match with an anchored directory check, or disclose; a planted src/helper_test.py payload must not be skipped by name alone.
  • node_modules / venv: either an opt-in mode that scans them, or the docs say the firewall gates only the repo's own imports.
  • Behavioural gate input: docs list only what is gated (secrets_risk), or more inputs are added with tests.

Activity

  1. added
    bug
    appsec
    supply-chain
    priority: high
    on Nov 13, 2026
  2. squid-protocol commented on Nov 18, 2026

    @squid-protocol
    OwnerAuthor

    Claimed by promoter-bot host nyx, lease renewed 2026-11-18T13:21Z. It lapses after 6 h without a renewal. To take it back, assign someone or remove the claim:nyx label.

  3. squid-protocol commented on Nov 18, 2026

    @squid-protocol
    OwnerAuthor

    Closing: PR #8602 enforces manifest flags, package.json install hooks and the anchored test-path skip (planted case + near-miss tests); node_modules/venv and the secrets-only behavioural gate are now stated in the README as not enforced, which meets the acceptance (enforced or disclosed). Remaining follow-ups (standalone CLI alias_map, https tarball refs, opt-in node_modules mode, more behavioural inputs) are tracked under #8427.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appsecbugclaim:nyxpriority: highsupply-chain

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions