PYSEC-2021-141

At a glance

Published
Updated
CVE
CVE-2021-27291
Aliases
GHSA-pq64-v7f5-gqh8

Description

In pygments 1.1+, fixed in 2.7.4, the lexers used to parse programming languages rely heavily on regular expressions. Some of the regular expressions have exponential or cubic worst-case complexity and are vulnerable to ReDoS. By crafting malicious input, an attacker can cause a denial of service.

Affected packages

PackageVersions
PyPI · pygmentsintroduced 0, fixed 2e7e8c4a7b318f4032493773732754e418279a14 ; introduced 1.1, fixed 2.7.4

References

Sources

SourceLicence
OSV.devCC-BY 4.0 — PyPA Advisory Database