Skip to content

feat(security): --offline on the three supply-chain CLIs (Part of #8624) - #8640

Merged
squid-shepherd[bot] merged 1 commit into
mainfrom
churn/8624-20261119T0027Z
Nov 19, 2026
Merged

squid-shepherd[bot] merged 1 commit into
mainfrom
churn/8624-20261119T0027Z

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #8624 (slice 4: the supply-chain CLIs).

Adds the shared add_flag / enforce (gitgalaxy/tools/readiness/offline.py) to vault_sentinel, import_policy_gate and binary_anomaly_detector, so each takes --offline (or GITGALAXY_OFFLINE=1) and installs the socket guard right after argument parsing. None of the three makes a network call; the guard turns that from a promise into an enforced property. A README row lists them as guaranteed.

Tests: tests/core_engine/test_offline_supply_chain_8624.py (6 cases) runs each CLI with the flag and with the env var and checks a deliberate socket.create_connection raises OfflineViolation; without either, nothing is guarded.

Gates: audit_check.py all clear; ruff format --check clean. No parsing logic touched, so golden / ratchets not run.

Class / Sibling gaps

Class: standalone tool CLIs under gitgalaxy/tools/ with an argparse main() that do not yet install the offline guard. Handled so far: galaxyscope, completeness_report, audit_recorder (earlier slices), the three cobol_to_cobol reporters (#8635), and these three supply-chain CLIs.

Sibling gaps (same mechanism, not here for the 5-file cap; one shared add_flag + enforce pair and a test each):

  • terabyte_log_scanning/pii_leak_hunter.py, terabyte_log_scanning/terabyte_log_scanner.py
  • network_auditing/full_api_network_map.py
  • sensors/ CLIs: libsurface.py, activity.py, change.py, reach.py
  • cobol_to_cobol forges and slicers: cobol_compiler_forge.py, cobol_etl_unpacker.py, cobol_jcl_forge.py, cobol_schema_forge.py, cobol_dag_architect.py, cobol_microservice_slicer.py
  • cobol_to_java: batch_test_harness.py, proof_reach.py, cobol_to_java_*_forge.py, cobol_to_java_guardrail.py
  • readiness/assess.py already guards through its own path (Readiness scanner: deployable offline package — runs on the customer's side, no source leaves #4726); cobol_to_java/port_runner.py is the opt-in LLM runner, which needs refusal by name rather than the flag.

Remaining slices

  1. log scanners + full_api_network_map.py (3 files + test + README).
  2. sensors/ CLIs (4 files; split in two).
  3. cobol_to_cobol forges and slicers (6 files; split in two).
  4. cobol_to_java CLIs, and the port_runner.py refusal by name.

Co-Authored-By: Claude Sonnet 5.5 [email protected]

🤖 Generated with Claude Code

@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Nov 19, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 19, 2026 00:32
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot enabled auto-merge (squash) November 19, 2026 00:32
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-shepherd
squid-shepherd Bot merged commit 6ae9053 into main Nov 19, 2026
94 checks passed
@squid-shepherd
squid-shepherd Bot deleted the churn/8624-20261119T0027Z branch November 19, 2026 00:51
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