Vulnerability · Published Nov 9, 2022 · Assigned by JFROG

CVE-2022-42964Exponential ReDoS in pymatgen leads to denial of service

Medium 5.9

In plain English

A medium-severity regular-expression denial of service in pymatgen from pymatgen. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 1.0% (higher than 62% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)5.9Medium
Exploit odds (30 days)1.0%top 38.4% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack toolingNoneno public tooling known

Official description

An exponential ReDoS (Regular Expression Denial of Service) can be triggered in the pymatgen PyPI package, when an attacker is able to supply arbitrary input to the GaussianInput.from_string method

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12pymatgen2022.11.7+dfsg1-11+deb12u2DEBIAN-CVE-2022-42964
Debian:13pymatgen2023.06.23+dfsg1-1DEBIAN-CVE-2022-42964
PyPIpymatgenno fix listedGHSA-5jqp-885w-xj32
PyPIpymatgen2025.10.7PYSEC-2026-909
Ubuntu:22.04:LTSpymatgenno fix listedUBUNTU-CVE-2022-42964

Affected products (as reported)

VendorProductVersions
pymatgen pymatgen 0 – before *

Weakness: CWE-1333 · Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H

References