CVE-2023-36464

Infinite Loop when a comment isn't followed by a character in pypdf

MEDIUM
5.5
CVSS Score
Published: June 27, 2023 at 09:24 PM UTC
Updated: June 17, 2026 at 06:06 AM UTC
3 products affected across 3 vendorsPypdfPYPDF2Pypdf

Using pypdf by py-pdf?

Get instant alerts when new vulnerabilities affect pypdf - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.4%
SSVC
PoC

Description

pypdf is an open source, pure-python PDF library. In affected versions an attacker may craft a PDF which leads to an infinite loop if `__parse_content_stream` is executed. That is, for example, the case if the user extracted text from such a PDF. This issue was introduced in pull request #969 and resolved in pull request #1828. Users are advised to upgrade. Users unable to upgrade may modify the line `while peek not in (b"\r", b"\n")` in `pypdf/generic/_data_structures.py` to `while peek not in (b"\r", b"\n", b"")`.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v < 3.9.0
Affected range stops below 3.9.0, so it looks safe — our inference, not a vendor statement
Affected range stops below 3.90, so it looks safe — our inference, not a vendor statement

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

SSVC — Action Prioritization

SSVCPoCNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

Attack Vector
LOCAL
Complexity
LOW
Privileges
NONE
User Interaction
REQUIRED
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-835

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card