InstructLab's linux_train.py permanently hardcodes trust_remote_code=True when loading models from HuggingFace, meaning any model a user downloads and runs with ilab train, download, or generate commands can execute arbitrary Python code on their machine without any warning or consent prompt. This is a CVSS 8.8 supply chain attack vector targeting AI development and fine-tuning workflows — any team using InstructLab to train or experiment with models is at risk if they pull from an untrusted or compromised HuggingFace repository. With an EPSS score placing this in the top 68th percentile and a CISA SSVC designation of TRACK, exploitation is plausible even though no public exploit exists yet, and critically, no patch is available for affected versions (≤ 0.26.1). Until a fix ships, prohibit ilab commands against models from unverified HuggingFace sources, manually audit model files before loading, and monitor for unexpected process execution during training runs.
What is the risk?
HIGH. While exploitation requires social engineering — a user must run ilab with an attacker-supplied model — the hardcoded trust_remote_code=True removes every safety net: users receive no warning, no prompt, and no ability to opt out. AI/ML teams running InstructLab in local or CI/CD training environments are silently and completely exposed to RCE. The attack is low-complexity once the malicious model is published, and HuggingFace Hub's scale makes victim discovery trivial. No patch exists as of disclosure, elevating residual risk for all currently deployed InstructLab instances.
How does the attack unfold?
What systems are affected?
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| InstructLab | pip | <= 0.26.1 | No patch |
Do you use InstructLab? You're affected.
How severe is it?
What is the attack surface?
What should I do?
6 steps-
Immediate: Restrict ilab train/download/generate to models from verified, internally-curated HuggingFace namespaces only. Prohibit ad-hoc model pulls from the public Hub.
-
Audit existing InstructLab workflows — review which models have been loaded and check for unexpected files, processes, or network connections.
-
Workaround: Manually inspect model repository files (especially config.json and any .py files) before loading. Reject any model containing custom Python code unless fully reviewed by a human.
-
Detection: Monitor for unexpected child processes spawned by Python during ilab execution, particularly outbound network connections or filesystem writes outside expected training directories.
-
Patch: Track the upstream fix at https://github.com/advisories/GHSA-rxpq-xgqx-fr7p and apply immediately when available.
-
Sandbox: Run InstructLab in isolated containers with no access to sensitive credentials, secrets, or production network resources.
What does CISA's SSVC say?
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
How is it classified?
Which compliance frameworks are affected?
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2026-6859?
InstructLab's linux_train.py permanently hardcodes trust_remote_code=True when loading models from HuggingFace, meaning any model a user downloads and runs with ilab train, download, or generate commands can execute arbitrary Python code on their machine without any warning or consent prompt. This is a CVSS 8.8 supply chain attack vector targeting AI development and fine-tuning workflows — any team using InstructLab to train or experiment with models is at risk if they pull from an untrusted or compromised HuggingFace repository. With an EPSS score placing this in the top 68th percentile and a CISA SSVC designation of TRACK, exploitation is plausible even though no public exploit exists yet, and critically, no patch is available for affected versions (≤ 0.26.1). Until a fix ships, prohibit ilab commands against models from unverified HuggingFace sources, manually audit model files before loading, and monitor for unexpected process execution during training runs.
Is CVE-2026-6859 actively exploited?
No confirmed active exploitation of CVE-2026-6859 has been reported, but organizations should still patch proactively.
How to fix CVE-2026-6859?
1. Immediate: Restrict ilab train/download/generate to models from verified, internally-curated HuggingFace namespaces only. Prohibit ad-hoc model pulls from the public Hub. 2. Audit existing InstructLab workflows — review which models have been loaded and check for unexpected files, processes, or network connections. 3. Workaround: Manually inspect model repository files (especially config.json and any .py files) before loading. Reject any model containing custom Python code unless fully reviewed by a human. 4. Detection: Monitor for unexpected child processes spawned by Python during ilab execution, particularly outbound network connections or filesystem writes outside expected training directories. 5. Patch: Track the upstream fix at https://github.com/advisories/GHSA-rxpq-xgqx-fr7p and apply immediately when available. 6. Sandbox: Run InstructLab in isolated containers with no access to sensitive credentials, secrets, or production network resources.
What systems are affected by CVE-2026-6859?
This vulnerability affects the following AI/ML architecture patterns: Training pipelines, Model fine-tuning, LLM development workflows, CI/CD ML pipelines.
What is the CVSS score for CVE-2026-6859?
CVE-2026-6859 has a CVSS v3.1 base score of 8.8 (HIGH). The EPSS exploitation probability is 0.14%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0010.003 Model AML.T0011 User Execution AML.T0011.000 Unsafe AI Artifacts AML.T0018.002 Embed Malware AML.T0058 Publish Poisoned Models Compliance Controls Affected
What are the technical details?
Original Advisory
A flaw was found in InstructLab. The `linux_train.py` script hardcodes `trust_remote_code=True` when loading models from HuggingFace. This allows a remote attacker to achieve arbitrary Python code execution by convincing a user to run `ilab train/download/generate` with a specially crafted malicious model from the HuggingFace Hub. This vulnerability can lead to complete system compromise.
Exploitation Scenario
An adversary creates a HuggingFace repository containing a model with a malicious custom modeling_*.py file that executes a reverse shell or credential harvester when imported. The model is given a convincing name — a fine-tuned Granite or Llama variant — and promoted via ML forums, LinkedIn posts, or direct outreach to InstructLab users. When the victim runs `ilab model download --repository attacker/malicious-model` followed by `ilab model train`, InstructLab's linux_train.py loads the model with trust_remote_code=True, automatically importing and executing the attacker's Python code with no user confirmation. The adversary achieves immediate arbitrary code execution with the victim's user privileges — no further exploitation steps required.
Weaknesses (CWE)
CWE-829 Inclusion of Functionality from Untrusted Control Sphere
Primary
CWE-829 Inclusion of Functionality from Untrusted Control Sphere
Primary
CWE-829 — Inclusion of Functionality from Untrusted Control Sphere: The product imports, requires, or includes executable functionality (such as a library) from a source that is outside of the intended control sphere.
- [Architecture and Design] Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid [REF-1482].
- [Architecture and Design] When the set of acceptable objects, such as filenames or URLs, is limited or known, create a mapping from a set of fixed input values (such as numeric IDs) to the actual filenames or URLs, and reject all other inputs. For example, ID 1 could map to "inbox.txt" and ID 2 could map to "profile.txt". Features such as the ESAPI AccessReferenceMap [REF-45] provide this capability.
Source: MITRE CWE corpus.
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H References
Timeline
Related Vulnerabilities
CVE-2025-59528 10.0 Flowise: Unauthenticated RCE via MCP config injection
Same attack type: Supply Chain CVE-2024-2912 10.0 BentoML: RCE via insecure deserialization (CVSS 10)
Same attack type: Supply Chain CVE-2023-3765 10.0 MLflow: path traversal allows arbitrary file read
Same attack type: Supply Chain CVE-2025-5120 10.0 smolagents: sandbox escape enables unauthenticated RCE
Same attack type: Supply Chain CVE-2026-21858 10.0 n8n: Input Validation flaw enables exploitation
Same attack type: Code Execution