CVE-2026-102998 in Pypdfinfo

Summary

by MITRE • 10/01/2026

pypdf is a free and open-source pure-python PDF library. Prior to 6.19.0, a crafted PDF with form field values can cause pypdf/generic/_appearance_stream.py appearance-stream generation to repeat invariant selection-data work inside a loop when an application updates fields with flattening enabled, resulting in excessive runtimes and application unavailability. This issue is fixed in version 6.19.0.

If you want to get best quality of vulnerability data, you may have to visit VulDB.

Analysis

by VulDB Data Team • 10/01/2026

The vulnerability identified within the pypdf library prior to version 6.19.0 represents a significant availability risk stemming from inefficient algorithmic handling of PDF form field processing. As an open-source Python library designed for parsing and manipulating Portable Document Format files, pypdf is frequently utilized in automated document generation pipelines, data extraction systems, and content management applications where large volumes of documents are processed programmatically. The specific flaw resides within the appearance stream generation logic located in the generic/_appearance_stream.py module. When an application interacts with PDF forms by updating field values while having flattening enabled, the library is required to regenerate visual representations for those fields to reflect their new states permanently embedded in the document structure.

The core technical deficiency involves a failure to optimize invariant selection data processing during this regeneration phase. Specifically, when form field values are updated and flattened, the code enters a loop that repeatedly performs work related to selecting appearance stream data that remains constant across iterations or is already computed. Instead of caching these results or restructuring the logic to avoid redundant calculations, the implementation re-evaluates invariant selection-data within every iteration of the processing loop. This architectural oversight transforms what should be a linear or logarithmic time complexity operation into one with significantly higher computational overhead, effectively creating an algorithmic inefficiency that scales poorly as document complexity increases.

From an operational perspective, this flaw manifests as excessive runtime consumption and eventual application unavailability, classifying it as a Denial of Service condition triggered by specific input characteristics rather than malicious resource exhaustion in the traditional sense. An attacker or even a benign user providing a crafted PDF with numerous form fields can cause the processing thread to hang indefinitely or consume disproportionate CPU resources. This impacts not only the immediate process handling the document but potentially broader system stability if shared resources are exhausted. The issue is particularly dangerous in server-side applications where such documents might be processed concurrently, leading to resource contention that degrades service quality for all users.

This vulnerability aligns with CWE-400, which describes Uncontrolled Resource Consumption, as the application fails to properly limit or manage the computational resources consumed during document processing. Furthermore, it relates to CWE-835, Loop with Unreachable Exit Condition, insofar as the loop structure contributes to excessive execution time due to redundant operations that should have been optimized out. In terms of MITRE ATT&CK mapping, this behavior can be associated with T1496 Resource Hijacking, where an attacker uses a crafted input to cause a system or network resource exhaustion condition, thereby disrupting availability without necessarily compromising confidentiality or integrity.

The resolution for this issue was implemented in version 6.19.0 of the pypdf library by refactoring the appearance stream generation logic to eliminate redundant processing of invariant data. Developers relying on affected versions must upgrade immediately to mitigate the risk of service disruption. In addition to upgrading, organizations should implement input validation and resource limits within their applications that consume PDFs. This includes setting timeouts for document parsing operations, limiting the number of form fields processed in a single request, and monitoring CPU usage during heavy document manipulation tasks. By combining software updates with defensive programming practices such as timeout enforcement and rate limiting, organizations can effectively neutralize this availability threat while maintaining robust document processing capabilities.

Responsible

GitHub M

Reservation

09/29/2026

Disclosure

10/01/2026

Moderation

accepted

EPSS

0.00301

KEV

no

Activities

very low

Sources

Do you want to use VulDB in your project?

Use the official API to access entries easily!