Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft bentofile.yaml with newline in docker.env key
-
DeliveryVictim imports bento and runs bentoml containerize
-
Exploitbase.j2 renders injected Dockerfile RUN
-
Executiondocker build executes attacker instructions
-
ImpactSteal build secrets and poison image
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK
2 techniques across 1 tactic: Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires a victim to run |
| Impact | This is a build-time supply-chain injection flaw (CWE-78) rather than a remotely-triggerable service vulnerability. The only CVSS data provided is a CVSS 4.0 vector (CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H) scoring 8.5/High; no CVSS 3.1 vector, no EPSS score, and no KEV listing were supplied. The signals are internally consistent: AV:L plus UI:P correctly reflects that exploitation requires a victim to locally run |
| Exploit ScenarioDerived | An attacker publishes or shares a malicious BentoML package whose docker.env mapping key contains an embedded newline followed by arbitrary Dockerfile directives. A victim engineer or CI pipeline imports the bento and runs |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 19, 2026
BentoML through 1.4.39 renders attacker-controlled docker.env mapping keys into its legacy base.j2 Dockerfile template without neutralizing embedded newline characters, allowing injected Dockerfile instructions - typically RUN commands - to be executed during bentoml containerize builds. A victim must be induced to build or containerize an untrusted bentofile.yaml or imported bento archive, so exploitation is local and interaction-dependent (CVSS:3.1/AV:L/AC:L/PR:N/UI:R) rather than remotely triggerable, but successful builds can expose any secrets mounted into the Docker build context and produce poisoned images that downstream users trust and deploy. No public exploit code or confirmed active exploitation was identified at time of analysis; realistic exposure is limited to teams that containerize third-party or otherwise untrusted bento content.
RemediationAI
No vendor-released patch was identified at time of analysis, so teams should treat untrusted bento content as executable. The primary compensating control is to stop containerizing untrusted inputs: refuse to run bentoml containerize or bentoml import against bentofile.yaml or bento archives that were not produced in-house, since importing a third-party bento directly supplies the malicious docker.env mapping. Where untrusted builds are unavoidable, add a pre-build validation step that rejects any docker.env key not matching a strict identifier pattern (e.g. ^[A-Za-z_][A-Za-z0-9_]*$) or containing newline, carriage-return, or whitespace characters; this is a small scripted gate but must be applied consistently before generate.py renders the template, and it will break legitimate configurations that rely on unusual key names. Avoid the legacy base.j2 template path where a newer template is available in your version, and never expose build credentials through environment variables or build args during containerization - use BuildKit secret mounts scoped to a single RUN, which limits the blast radius if injection still succeeds, at the cost of additional build plumbing. Run bentoml containerize builds in an isolated builder with no network egress and no host-mounted credentials, and scan the resulting Dockerfile and image history for unexpected RUN layers before publishing. Monitor the vendor repository (https://github.com/bentoml/BentoML) and the VulnCheck advisory for a patched release and upgrade as soon as one is published.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The flaw is an OS command injection (CWE-78) that manifests in the generated Dockerfile rather than in a running service. BentoML's build pipeline parses docker.env entries from bentofile.yaml in src/bentoml/_internal/bento/build_config.py, then src/bentoml/_internal/container/generate.py renders those key/value pairs into the Dockerfile templates under src/bentoml/_internal/container/frontend/dockerfile/templates/ - with the legacy base.j2 template used by the bentoml containerize entry point in src/bentoml/_internal/container/__init__.py. Because only values were treated as untrusted, a mapping key containing an embedded newline terminates the intended environment-variable line and starts a new, attacker-authored Dockerfile instruction. Docker then faithfully executes the injected RUN step as part of the build, in the build container's privilege and secret context. The result is a build-time supply-chain primitive: an attacker who can deliver a crafted bentofile.yaml or a malicious bento archive can influence the final image contents and any credentials, tokens, or SSH keys exposed to the builder. The CPE cpe:2.3:a:bentoml:bentoml:*:*:*:*:*:*:*:* covers all BentoML releases, with the advisory scoping the issue to versions through 1.4.39 and the legacy template path.
Know when Bentoml gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
AV:L and UI:R because a victim must locally containerize an attacker-supplied bento; PR:N as the attacker needs no account; C/I/A:H from secret theft and image poisoning in the build context.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
BentoML through 1.4.39 contains a Dockerfile instruction injection vulnerability that allows attackers to add arbitrary build instructions by embedding newlines in docker.env mapping keys rendered by the legacy base.j2 template. Attackers can supply a crafted bentofile.yaml or imported bento archive so that bentoml containerize executes injected RUN instructions during docker build, accessing build secrets and poisoning images.
Executive ViewAI
BentoML releases through 1.4.39 can be tricked into writing attacker-supplied instructions into the Dockerfile it generates during bentoml containerize, so a routine packaging step can silently execute foreign commands and bake them into the resulting image. The damage is supply-chain shaped: credentials present in the build context can be captured, and the poisoned image is then trusted and deployed by downstream teams. Leadership should care less about the breadth of exposure - a build must be deliberately run against untrusted bento content - and more about the asymmetry: one careless import of an external model package can propagate a compromised artifact into production where it is difficult to trace back.
No vendor-released patch identified at time of analysis. Interim mitigations: build only internally authored bentofile.yaml and vetted bento archives, treat any imported or third-party bento as untrusted code requiring review, keep secrets out of the Docker build context and supply them through scoped build-time secret mounts, and inspect the generated Dockerfile for injected RUN instructions before any image is pushed to a shared registry.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
OS command injection occurs when an application passes unsanitized user input directly into system shell commands.
BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser
BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica
Arbitrary file write in BentoML allows an attacker-supplied bento or model tar archive to escape the extraction director
BentoML versions prior to 1.4.34 allow path traversal attacks through improperly validated file path fields in bentofile
Server-Side Request Forgery in BentoML versions 1.4.19 through 1.4.39 exposes internal CGNAT infrastructure by failing t
Command injection in bentoml OpenLLM 0.6.30 allows local low-privilege users to execute arbitrary shell commands by supp
EUVD-2026-104309
GHSA-rq23-h86h-7v4x
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB