Crass: Deeply nested CSS blocks and functions can trigger a SystemStackError or excessive memory usage
Impact
Crass recursively parses CSS simple blocks and functions without a depth guard. An attacker-controlled value containing many deeply nested blocks can recurse until Ruby raises SystemStackError: stack level too deep, or can cause excessive memory usage.
Source excerpt · OSVAffected packages
Start with the recorded fix for your release branch. Check your installed version and test compatibility before upgrading. Fixing this advisory does not rule out other vulnerabilities in the release.
| Affected range | Recorded fix |
|---|---|
| Earlier releases before 1.0.7Ecosystem versions | 1.0.7 |
Version evidence: OSV · GHSA-6jxj-px6v-747w
View original version evidence (12 explicit versions)
Affected products
Vendor version evidence. Product records are separate from automatic dependency matching.
rgrove · GitHub_M
crass
1 range
rgrove · GitHub_M
crass
Compare with this publisher’s ranges. This does not inspect your installation.
affected
< 1.0.7
Other versions: unknown
Original source description
Impact
Crass recursively parses CSS simple blocks and functions without a depth guard. An attacker-controlled value containing many deeply nested blocks can recurse until Ruby raises SystemStackError: stack level too deep, or can cause excessive memory usage.
Patches
This is fixed in Crass 1.0.7, which adds a configurable depth limit with a conservative default.
Workarounds
Add SystemStackError handling around Crass calls in your application. Buy more RAM.
Inside the record
Evidence available
Describes the evidence in this view, not whether the product is safe.
Original records
CVE-2026-61846View the latest unmodified CVE JSON from the official source. It may be newer than this imported page.
cve.new JSON →Underlying weaknesses
The source’s classification of what caused the vulnerability.
Contributing organizations · 1
Assigning organization
What changed
Follow changesLarge field values are marked as truncated previews. Original source snapshots remain retained.