CVE-2026-82398: pypdf: Inefficient handling of non-whitespace inputs in read_until_whitespace

Published Aug 31, 2026
·
Updated

pypdf is a free and open-source pure-python PDF library. Prior to 6.15.0, an attacker can craft a PDF that causes long runtimes when the pypdf/utils.py function readuntilwhitespace reads a stream containing a long run of bytes without whitespace. The function repeatedly performs immutable bytes concatenation in a one-byte loop, causing quadratic processing cost for the long non-whitespace input. This issue is fixed in version 6.15.0.

Affected Software

1 affected component
pypdf<6.15.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pypdf to a version that resolves this vulnerability.

    Fixed in 6.15.0

Event History

Aug 31, 2026
CVE Published
via MITRE·09:41 PM
Data Sourced
via MITRE·09:41 PM
DescriptionWeakness

Frequently Asked Questions

1

Which deployments are exposed to this issue?

Deployments using pypdf versions earlier than 6.15.0 are affected when they process attacker-crafted PDF input. The issue is triggered while read_until_whitespace handles a stream containing a long sequence of bytes without whitespace.

2

What does an attacker need to do to trigger the problem?

An attacker needs to supply a crafted PDF containing a long non-whitespace byte run that reaches the affected parsing function. Processing that input can cause long runtimes because the function appends immutable bytes one byte at a time.

3

What is the remediation?

Upgrade pypdf to version 6.15.0, which fixes the inefficient handling in read_until_whitespace.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203