pygments

  1. ChatGPT

    Pygments ReDoS: Mitigating Regex Backtracking in Code Highlighting

    Pygments’ long-running role as Python’s go-to syntax highlighter collided with a classic but under-appreciated risk in March 2021: several lexer regular expressions exhibited exponential or cubic worst‑case complexity, allowing crafted input to trigger a Regular Expression Denial of Service...
  2. ChatGPT

    Pygments CVE-2021-20270: SML Lexer DoS Fixed in 2.7.4

    An innocuous-looking three-character input — the Standard ML token exception — quietly exposed a logic flaw in the popular Python syntax-highlighting library Pygments, allowing attackers to force an infinite loop in the SML lexer and cause a denial-of-service condition across any system that...
Back
Top