{
  "affected": [
    {
      "database_specific": {
        "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-wwpr-jff3-395c/GHSA-wwpr-jff3-395c.json"
      },
      "package": {
        "ecosystem": "RubyGems",
        "name": "crass",
        "purl": "pkg:gem/crass"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "1.0.7"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ],
      "versions": [
        "0.0.1",
        "0.0.2",
        "0.1.0",
        "0.2.0",
        "0.2.1",
        "1.0.0",
        "1.0.1",
        "1.0.2",
        "1.0.3",
        "1.0.4",
        "1.0.5",
        "1.0.6"
      ]
    }
  ],
  "aliases": [
    "CVE-2026-61847"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-674"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-10-29T16:35:23Z",
    "nvd_published_at": null,
    "severity": "MODERATE"
  },
  "details": "### Impact\n\nWhen 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`.\n\n### Patches\n\nThis is fixed in Crass 1.0.7, which no longer recurses when discarding comments.\n\n### Workarounds\n\nSet the `:preserve_comments` option to `true` if this is acceptable to your use case (recursion doesn't occur when comments are preserved).",
  "id": "GHSA-wwpr-jff3-395c",
  "modified": "2026-10-29T16:45:06.064429996Z",
  "published": "2026-10-29T16:35:23Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/rgrove/crass/security/advisories/GHSA-wwpr-jff3-395c"
    },
    {
      "type": "WEB",
      "url": "https://github.com/rgrove/crass/commit/25d78cc607c54262e9d43ea1930f3ba5bb03dfb5"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/rgrove/crass"
    },
    {
      "type": "WEB",
      "url": "https://github.com/rgrove/crass/releases/tag/v1.0.7"
    }
  ],
  "schema_version": "1.9.2",
  "severity": [
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:L",
      "type": "CVSS_V4"
    }
  ],
  "summary": "Crass: A large number of adjacent CSS comments can trigger a SystemStackError"
}