Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
Tools/GitHubGitHub/biranperetz/docling-core-cve-2026-24009
Vulnerability AnalysisCode AnalysisExploitationPapers & ResearchLearning & Education
GitHubbiranperetz/docling-core-cve-2026-24009

docling-core-CVE-2026-24009

Technical write-up and PoC for CVE-2026-24009, demonstrating unsafe YAML loading in docling-core and practical mitigation paths.

View Repository
6 months agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

CVE-2026-24009 — docling-core Unsafe YAML Deserialization (PoC + Notes)

This repo contains a proof-of-concept (PoC) and a simple scanner demonstrating CVE-2026-24009, where docling-core can enable code execution when loading attacker-controlled YAML under specific dependency conditions.

TL;DR

Impact: potential RCE during YAML parsing Vulnerable chain (all required):

  • docling-core >= 2.21.0 and < 2.48.4
  • PyYAML < 5.4 (upstream behavior associated with CVE-2020-14343)
  • application calls DoclingDocument.load_from_yaml(...) on untrusted YAML

Fix: upgrade docling-core to >= 2.48.4 (switches to yaml.SafeLoader) upgrade to


Alternative fix:
PyYAML
>= 5.4

Background / Root Cause

DoclingDocument.load_from_yaml() deserializes a YAML-serialized DoclingDocument. In vulnerable versions, it loads YAML using an unsafe loader (yaml.FullLoader) when PyYAML is vulnerable, allowing malicious YAML constructors to execute code during parsing (see CVE-2020-14343 for more information).


Tested environment (PoC)

  • OS: Ubuntu 24.04
  • Python: 3.12.3
  • docling-core: 2.48.3 (vulnerable)
  • PyYAML: 5.3.1 (vulnerable)

Reproduction (PoC)

1) Create a virtual environment

root@kitploit:~
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install "docling-core==2.48.3" "PyYAML==5.3.1"

2) (Optional) Confirm the vulnerable loader

Run:

root@kitploit:~
python check_loader.py

In vulnerable versions, load_from_yaml() uses:

root@kitploit:~
data = yaml.load(f, Loader=yaml.FullLoader)

3) Run the PoC

root@kitploit:~
python repro_docling_load.py

Expected behavior:

  • repro_docling_load.py raises a ValidationError (expected)
  • a local marker file is created: /tmp/docling_cve_poc_marker

This demonstrates execution occurred during YAML parsing, before DoclingDocument.model_validate(...) fails.


Mitigation / Patch verification

Mitigation 1 — Upgrade docling-core (recommended)

root@kitploit:~
python -m pip install --upgrade "docling-core==2.48.4"
python check_loader.py
python repro_docling_load.py

Expected:

  • check_loader.py shows yaml.SafeLoader
  • PoC fails with a YAML constructor error and no marker file is created

Mitigation 2 — Upgrade PyYAML

Upgrading PyYAML to >= 5.4 mitigates the upstream behavior associated with CVE-2020-14343.

Mitigation 3 — Enforce safe loading

If upgrading is not possible, avoid loading untrusted YAML with unsafe loaders. Enforce yaml.SafeLoader when deserializing untrusted YAML.


Notes on downstream docling exposure (dependency mapping)

While this CVE is in docling-core, the most common consumer is docling. A broad dependency range in docling does not prove vulnerability by itself; what matters is the resolved environment (lockfiles / installed packages) and whether YAML import paths are used.

This repo includes collect_versions.py, which maps:

  • declared docling-core constraints from pyproject.toml
  • pinned docling-core versions from uv.lock (or poetry.lock in older tags)

From the extracted data, the potentially vulnerable docling versions (constraint allows vulnerable + lock pins vulnerable) are:

  • >= v2.27.0 and <= v2.57.0

This is a dependency-resolution indicator, not a proof that default docling workflows reach load_from_yaml() on untrusted input.


Repo contents (high-level)

  • repro_docling_load.py — minimal PoC runner
  • check_loader.py — prints the YAML loader used by load_from_yaml()
  • scanner/ — a simple dependency-based scanner (optional direct sink check)
  • collect_versions.py — helper to map docling tags to pinned docling-core versions
Download Tool