Vulnerability  ·  2026-11-24

Spring AI PDF readers (PagePdfDocumentReader/ParagraphPdfDocumentReader) OOM denial of service

VulnerabilityMedium impactGlobalCVE-2026-59340
Spring AI 1.x/2.x PDF readers reconstruct layout from glyph positions and cap each computed gap's allocation but not the cumulative allocation across a page. A crafted PDF forces excessive memory allocation during processing, causing OutOfMemoryError and, under ExitOnOutOfMemoryError JVMs, immediate process termination. CVSS 6.5 (CVSS 3.1).
These readers are the RAG ingestion path for untrusted PDFs (document uploads, email attachments, web crawls). A single crafted PDF can crash or degrade the JVM that runs the embedding/RAG pipeline, enabling a remote denial-of-service against an AI application that ingests attacker-supplied documents.
Remote — supply a specially crafted PDF to an ingestion endpoint; memory exhaustion during text-extraction causes OOM/process termination.
Spring AI 2.0.0–2.0.3; 1.1.0–1.1.10; 1.0.0–1.0.11; enterprise 2.0.0–2.0.2.1
Upgrade to the fixed Spring AI version per spring.io advisory; validate/limit PDF size and depth at ingestion.
NVD detailSpring.io advisory
See this in the live feed Explore related AI security and governance findings — updated every morning.
Open the feed →