A ReDoS issue was discovered in pygments/lexers/smithy.py in pygments through 2.15.0 via SmithyLexer.
Priority LOW 25CWE-434Published · Updated
Key facts
- Attack vector
- Local
- Privileges required
- None
- User interaction
- Required
- Attack complexity
- Low
- Impact type
- Code execution
- Confidentiality · integrity · availability
- None · None · High
- Fix status
- Partial Red Hat: 3 fixed, 5 without a fix
Attack profile from CVSS 3.1 · NVD. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-434.
Summary
A ReDoS issue was discovered in pygments/lexers/smithy.py in pygments through 2.15.0 via SmithyLexer.
Why it matters now
Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.00519 44th percentileScored 2026-11-07
Public exploit Yes 1 exploit referenceTagged by NVD
Fix Partial Pygments (PyPI): 2.15.0Red Hat: 3 advisoriesRed Hat: 3 fixed, 5 without a fix
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | — | all versions | — | No fix listed | CNA |
| — | Pygments (PyPI) | before 2.15.0 | 2.15.0 | Patch available | GHSA-mrwq-x4v8-fh7p |
- — Vendor— Affected all versions Fixed in — No fix listed CNA
- Pygments (PyPI) Vendor— Affected before 2.15.0 Fixed in 2.15.0 Patch available GHSA-mrwq-x4v8-fh7p
Remediation
- Fix · GHSA-mrwq-x4v8-fh7p Pygments (PyPI) Fixed in 2.15.0 Advisory →
Red Hat 3 advisories
- RHSA-2024:2010 Released 2024-04-23 · Red Hat rating ImportantSatellite 6.15.0 release
- Red Hat Satellite 6.15 for RHEL 8 foreman-3.9.1.6-1.el8sat, foreman-cli-3.9.1.6-1.el8sat, foreman-debug-3.9.1.6-1.el8sat +28
- RHSA-2024:1072 Released 2024-03-04 · Red Hat rating ModerateRed Hat Ansible Automation Platform 2.4 Container Release Security and Bug Fix Update
- Red Hat Ansible Automation Platform 2.4 for RHEL 8 ansible-automation-platform-24/ee-supported-rhel8
- Red Hat Ansible Automation Platform 2.4 for RHEL 9 ansible-automation-platform-24/ee-supported-rhel9
- RHSA-2024:1057 Released 2024-02-29 · Red Hat rating ImportantRed Hat Ansible Automation Platform 2.4 Product Security and Bug Fix Update
- Red Hat Ansible Automation Platform 2.4 for RHEL 8 ansible-automation-platform-installer-2.4-6.el8ap, ansible-rulebook-1.0.5-1.el8ap, automation-eda-controller-1.0.5-1.el8ap +14
- Red Hat Ansible Automation Platform 2.4 for RHEL 9 ansible-automation-platform-installer-2.4-6.el9ap, ansible-rulebook-1.0.5-1.el9ap, automation-eda-controller-1.0.5-1.el9ap +14
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Ansible Automation Platform 2 | Affected | No fix planned: Will not fix |
| Red Hat Enterprise Linux 6 | Affected | No fix planned: Out of support scope |
| Red Hat Enterprise Linux 7 | Affected | No fix planned: Out of support scope |
| Red Hat Enterprise Linux 8 | Affected | No fix yet |
| Red Hat Enterprise Linux 9 | Affected | No fix planned: Will not fix |
| Red Hat Ansible Automation Platform 2.4 for RHEL 8 | Fixed | RHSA-2024:1057, RHSA-2024:1072 |
| Red Hat Ansible Automation Platform 2.4 for RHEL 9 | Fixed | RHSA-2024:1057, RHSA-2024:1072 |
| Red Hat Satellite 6.15 for RHEL 8 | Fixed | RHSA-2024:2010 |
Not affected: 5 products
- Red Hat Ansible Automation Platform 2
- Red Hat Ansible Automation Platform 2.4 for RHEL 8
- Red Hat Ansible Automation Platform 2.4 for RHEL 9
- Red Hat Developer Hub 1
- Red Hat Satellite 6.15 for RHEL 8
Timeline
- 2026-10-02 Threatist record created from CVE-2022-40896
- 2026-10-03 Alias added: GHSA-mrwq-x4v8-fh7p
- 2026-10-27 Affected versions changed · Red Hat
References
Advisory 4
Other 10
- https://pypi.org/project/Pygments/
- https://github.com/pygments/pygments/commit/97eb3d5ec7c1b3ea4fcf9dee30a2309cf92bd194
- https://github.com/pygments/pygments/commit/dd52102c38ebe78cd57748e09f38929fd283ad04
- https://github.com/pygments/pygments/commit/fdf182a7af85b1deeeb637ca970d31935e7c9d52
- https://github.com/pygments/pygments
- https://github.com/pypa/advisory-database/tree/main/vulns/pygments/PYSEC-2023-117.yaml
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/EZGMXALE3HSP4OXC7UUWIKX3OXKZDTY3
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/VUZO4BQCIY2S2KZYHERQMKURB7AHXDBO
- https://pypi.org/project/Pygments
- https://pyup.io/posts/pyup-discovers-redos-vulnerabilities-in-top-python-packages-part-2
More Pygments vulnerabilities
- TI-2015-07040 The FontManager._get_nix_font_path function in formatters/img.py in Pygments 1.2.2… CVSS 3.0CRITICAL 9.0
- TI-2021-08825 In pygments 1.1+, fixed in 2.7.4, the lexers used to parse programming languages rely… CVSS 3.1HIGH 7.5
- TI-2021-03561 Infinite loop in python-pygments CVSS 3.1HIGH 7.5
Sources
- CVE-2022-40896 · CVE Program
- CVE-2022-40896 · NVD
- FIRST EPSS
- GHSA-mrwq-x4v8-fh7p · GitHub Advisory Database · CC BY 4.0
- CVE-2022-40896 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences