# Pygments (PyPI)

Pygments is a syntax highlighting package written in Python.

- Latest: 2.21.0 (2026-08-17)
- Licence: BSD-2-Clause
- Downloads: 1225657508 last month
- Advisories on the latest version: 0

- CVE-2026-4539 : Pygments has Regular Expression Denial of Service (ReDoS) due to Inefficient Regex for GUID Matching Fixed in 2.20.0.
- CVE-2026-4539 LOW: Pygments has Regular Expression Denial of Service (ReDoS) due to Inefficient Regex for GUID Matching Fixed in 2.20.0.
- CVE-2022-40896 MODERATE: Pygments vulnerable to ReDoS Fixed in 2.15.0.
- CVE-2022-40896 :  Fixed in 2.15.1.
- CVE-2015-8557 CRITICAL: Command Injection in Pygments Fixed in 2.1.
- CVE-2021-20270 HIGH: Infinite Loop in Pygments Fixed in 2.7.4.
- CVE-2021-27291 HIGH: Pygments vulnerable to Regular Expression Denial of Service (ReDoS) Fixed in 2.7.4.
- CVE-2021-20270 :  Fixed in 2.7.4.
- CVE-2021-27291 :  Fixed in 2.7.4.
- CVE-2015-8557 :  Fixed in 2.1.

Sources: PyPI, deps.dev (CC BY 4.0), OSV. Last checked 3 Dec 2026.
