The FontManager.getnixfontpath function in formatters/img.py in Pygments 1.2.2 through 2.0.2 allows remote attackers to execute arbitrary commands via shell metacharacters in a font name.
// cvss v3.0 vector
CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H
Attack vector
Network
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Changed
Confidentiality
High
Integrity
High
Availability
High
Checked 2026-09-23 at 02:25 UTC. The most recent advisory here was published 2026-03-22. Updated continuously from NVD, GHSA, OSV and CNA feeds.
Is pygments safe? pypi package security report | CyberXYZ