RubySec

Providing security resources for the Ruby community

GHSA-wwpr-jff3-395c (crass): A large number of adjacent CSS comments can trigger a SystemStackError

A large number of adjacent CSS comments can trigger a SystemStackError

Published: June 25, 2026

SECURITY IDENTIFIERS

GEM

crass

PATCHED VERSIONS

>= 1.0.7

DESCRIPTION

Impact

When the :preserve_comments option is not enabled (which is the default behavior), Crass discards CSS comments by recursively consuming the next token. An attacker who provides a stylesheet containing a very large number of adjacent comments can cause excessive recursion and trigger a SystemStackError.

RELATED