---
id: CVE-2026-76875
title: >-
  PyPy before versions 3.11.16 and 3.12.14 contains a use-after-free
  vulnerability in the pyexpat module's ExternalEntityParserCreate function that
  allows attackers to corrupt memory by supplying a crafted XML document to
  applications that…
summary: >-
  PyPy before versions 3.11.16 and 3.12.14 contains a use-after-free
  vulnerability in the pyexpat module's ExternalEntityParserCreate function that
  allows attackers to corrupt memory by supplying a crafted XML document to
  applications that…
severity: medium
cvss: 5.3
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N'
cwe:
  - CWE-416
vendor: PyPy
product: PyPy
affected:
  - PyPy < 3.11.16
  - PyPy >= 3.12.0 < 3.12.14
published: '2026-09-29'
updated: '2026-10-02'
sourceUpdated: '2026-10-02T13:17:55.747'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2026-76875'
references:
  - url: 'https://doc.pypy.org/release-v8.0.0.html'
    label: disclosure@vulncheck.com
  - url: 'https://github.com/pypy/pypy/releases/tag/release-pypy3.11-v8.0.0'
    label: disclosure@vulncheck.com
  - url: 'https://github.com/pypy/pypy/releases/tag/release-pypy3.12-v8.0.0'
    label: disclosure@vulncheck.com
  - url: >-
      https://www.vulncheck.com/advisories/pypy-pyexpat-externalentityparsercreate-use-after-free
    label: disclosure@vulncheck.com
  - url: >-
      https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-76875.json
  - url: 'https://access.redhat.com/security/cve/CVE-2026-76875'
  - url: 'https://www.cve.org/CVERecord?id=CVE-2026-76875'
tags:
  - nvd
  - cve.org
  - csaf
  - vex
  - red-hat
ssvc:
  exploitation: none
  automatable: 'yes'
  technicalImpact: partial
  timestamp: '2026-10-02T12:07:14.237053Z'
epss: 0.0024
epssPercentile: 0.15048
ingestedAt: '2026-09-29T13:34:31.681Z'
---

## Overview

PyPy before versions 3.11.16 and 3.12.14 contains a use-after-free vulnerability in the pyexpat module's ExternalEntityParserCreate function that allows attackers to corrupt memory by supplying a crafted XML document to applications that create external-entity sub-parsers without retaining a reference to the parent parser. The child parser retains a raw C back-pointer to the parent parser struct while PyPy's tracing garbage collector can free the parent's C struct, causing bundled libexpat to dereference the freed pointer on every parsed token, producing memory corruption.

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.

## Vendor advisories

- **Red Hat VEX** · updated 2026-09-29 · [vex](https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-76875.json)
