openEuler Security Advisory
OESA-2021-1154
python-pygments security update
Details
Security Fix(es):
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.(CVE-2021-27291)
An infinite loop in SMLLexer in Pygments versions 1.5 to 2.7.3 may lead to denial of service when performing syntax highlighting of a Standard ML (SML) source file, as demonstrated by input that only contains the "exception" keyword.(CVE-2021-20270)
Affected packages
| Ecosystem | Package | Affected versions |
|---|---|---|
| openEuler:20.03-LTS-SP1 | python-pygments | All versions before 2.5.2-3.oe1 (fixed in 2.5.2-3.oe1) |