Skip to content

Remove the XGBoost malware classifier and --fail-on-malware (owner 2026-11-19); docs say removed, research pending #8430

Closed

Description

@squid-protocol

Part of #8427. Source: the security claims audit in #8426 (docs/security_claims_inventory.md, "Most serious problems" #1).

Needs an owner decision before work starts: ship a trained model with a measured evaluation, or remove the classifier and everything that gates on it.

Problem

The XGBoost Trojan/Stealer/Dropper/Botnet classifier never runs in any shipped configuration.

  • gitgalaxy/security/security_auditor.py:72 defaults to gitgalaxy_malware_xgb_multiclass.json; that file is not in the repo (and not in the package).
  • Both golden masters record "Inference Ran": false.
  • Every test uses a mock or a synthetic stand-in model (tests/security_auditing/test_ml_real_model_2986.py says itself it "says nothing about detection quality").
  • templates/requirements/full.txt (the Action's full install) lacks scikit-learn, so it could not run even with a model.
  • --fail-on-malware can never fire without the model (galaxyscope.py:1975 already prints this at runtime).
  • The pipeline templates ship a job named "ML Malware Gate" that gates on --fail-on-malware, so the job is a no-op: templates/github/gitgalaxy-pipeline.yml:47, templates/azure/azure-pipelines.yml:79,103, templates/bitbucket/bitbucket-pipelines.yml:57, plus azure-pipelines.yml:38 and bitbucket-pipelines.yml:19,72 at the repo root and templates/gitlab/scan.yml:8.
  • Docs describing a working classifier: 02-20, 04-00 (text and diagram), README ([full] extra), docs/zero_dependency_mode.md, github-action-readme.md (full_precision), wiki index (see docs: security claims inventory (112 claims vs code and tests) #8426 section A/B).

Related open issue: #96 (build a positive-control malware library and XGBoost regression pipeline, scope:frontier). It is the "train and ship" path; this issue is the decision plus cleanup either way.

Class: every place the classifier is wired in or described as live

Member Status Evidence
Auditor (SecurityAuditor, model load) missing model security_auditor.py:72; goldens "Inference Ran": false
Gate (--fail-on-malware, is_ml_threat) cannot fire galaxyscope.py:1975, :4345; test_ml_boundary_2986.py::test_no_model_scan_reads_unexercised_not_safe
Pipeline template job "ML Malware Gate" (github, azure, bitbucket; gitlab comment) no-op paths above
Repo-root azure-pipelines.yml / bitbucket-pipelines.yml / .github/workflows/gitgalaxy.yml:104,149 pass --fail-on-malware (no-op) same
Action input full_precision no model input action.yml:26,46,60
templates/requirements/full.txt lacks scikit-learn file
Shadow patch override (sits behind the model check) see the shadow-patch issue in this epic security_auditor.py:146,191

Acceptance (one of two, owner picks)

A. Ship: train a model on a labelled set, commit the training and evaluation script and the artifact (or a download-and-verify step), report recall, precision and false-positive rate on a date-locked held-out set against a baseline (GuardDog), add scikit-learn to full.txt, add a real-model test that asserts predictions, and only then keep the gate and the docs.

B. Remove: delete the classifier path, --fail-on-malware, the "ML Malware Gate" template jobs, the full_precision input, and the doc claims; keep the NULL (not "Safe") column behaviour until the schema change is decided.

Either way, no doc says "classifies Trojans" while the model is absent.

Activity

  1. added
    bug
    ml-ops
    appsec
    priority: high
    on Nov 13, 2026
  2. squid-protocol commented on Nov 19, 2026

    @squid-protocol
    OwnerAuthor

    Owner decision (2026-11-19): remove the classifier

    Remove the XGBoost malware classifier and --fail-on-malware for now. No model ships and it never runs, so it is removed rather than kept as a dormant claim. Docs say "Removed: research pending" instead of describing it. A future model comes back only with a labelled, measured evaluation (see #96).

    Scope

    • Code: drop the XGBoost load/inference path from gitgalaxy/security/security_auditor.py and the --fail-on-malware flag. Keep what works without the model: the transitive upstream/downstream dependency counts (tested) and the manual --shadow-patch-detected alert (--shadow-patch-detected compares no hash or version, mislabels files as Trojans, and is unreachable #8431). Drop the ML output fields from the recorders and the audit/SARIF output (e.g. Inference Ran, threat-class columns), regenerate the goldens with the CI-pinned toolchain, and remove xgboost and scikit-learn from the full extra (keep pandas/numpy only if something else imports them; check). Update the GitHub Action inputs and workflows that mention it (standing workflow grant; not shepherd-*.yml). Remove or rewrite the ML tests (test_ml_*); keep a test that the flag is gone and the dependency counts still come out.
    • Docs: wiki 02-20 becomes a short "Removed (2026-11-19): research pending" page linking this issue and # [ML-OPS] Build Positive Control Malware Library & XGBoost Regression Pipeline #96; README, docs/zero_dependency_mode.md, the Action README, gitgalaxy/security/README.md, the security claims inventory rows, and the CLI reference drop the classifier or mark it removed. Regenerate generated wiki pages rather than hand-editing them.

    Slices

    1. Code, CLI, output keys + regenerated goldens, extras, Action/workflows, tests: one atomic PR with File-cap exception: atomic removal of the XGBoost classifier (#8430).
    2. Docs (hand-written pages; then regenerate generated pages).

    Done when

    git grep -i "xgboost\|fail-on-malware\|gitgalaxy_malware_xgb" on main finds only the "removed, research pending" notes and the CHANGELOG line, and every gate passes.

  3. changed the title [-]XGBoost malware classifier never runs: ship a measured model or remove it and --fail-on-malware (owner decision)[/-] [+]Remove the XGBoost malware classifier and --fail-on-malware (owner 2026-11-19); docs say removed, research pending[/+] on Nov 19, 2026
  4. 13 remaining items

  5. squid-protocol commented on Nov 23, 2026

    @squid-protocol
    OwnerAuthor

    Churn run 8430-20261123T1228Z (host melek) ended without a PR. No new work: PR #9107 draft, 8/9 gates green; affected gate red on main too (mypy.txt regen needs uv). Left for next tick.

  6. squid-protocol commented on Nov 23, 2026

    @squid-protocol
    OwnerAuthor

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

  7. squid-protocol commented on Nov 23, 2026

    @squid-protocol
    OwnerAuthor

    Option B (remove) is complete: classifier, --fail-on-malware, template jobs and doc claims removed in #8704 and follow-up doc PRs; #9137 cleared the last 56 LLM-report claims. Closing.

  8. squid-protocol commented on Nov 23, 2026

    @squid-protocol
    OwnerAuthor

    Churn run 8430-20261123T1801Z (host nyx) ended without a PR. PR #9137 approved at e4e95c7; file-cap exception justified

  9. squid-protocol commented on Nov 23, 2026

    @squid-protocol
    OwnerAuthor

    Churn run 8430-20261123T1745Z (host nyx) ended without a PR. PR #9136 already merged; sibling gaps listed in PR body (LLM-reports sweep, full.txt, FAIL_ON_MALWARE keys)

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:nyxml-opspriority: high

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions