{
  "affected": [
    {
      "ranges": [
        {
          "database_specific": {
            "extracted_events": [
              {
                "introduced": "4.0.0"
              },
              {
                "fixed": "4.12.0"
              }
            ],
            "source": [
              "AFFECTED_FIELD",
              "REFERENCES"
            ]
          },
          "events": [
            {
              "introduced": "bde6dc9e10ff43e3526ecdfe4007de98ef1d521e"
            },
            {
              "fixed": "48e5fd2d602344c7d33019fbc5c8b087e315bb78"
            },
            {
              "fixed": "6796b2e89d0bd7b9d7d763a86275e5334731dd61"
            },
            {
              "fixed": "4cbdbaaf8fb37299926a5dc45be2ffc03e436fc1"
            }
          ],
          "repo": "https://github.com/viewcomponent/view_component",
          "type": "GIT"
        }
      ]
    }
  ],
  "aliases": [
    "GHSA-97jw-64cj-jc58"
  ],
  "database_specific": {
    "cna_assigner": "GitHub_M",
    "cwe_ids": [
      "CWE-79"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/54xxx/CVE-2026-54498.json"
  },
  "details": "view_component is a framework for building reusable, testable, and encapsulated view components in Ruby on Rails. From 4.0.0 until 4.12.0, ViewComponent::Base#around_render can return HTML-unsafe strings that bypass the escaping behavior applied to normal #call return values. This creates an XSS risk when downstream applications use around_render to wrap, replace, instrument, or conditionally return content that includes user-controlled data, and ViewComponent::Collection#render_in can amplify the issue by joining per-item results and marking the entire output html_safe, converting raw unsafe output into an ActiveSupport::SafeBuffer. This issue is fixed in version 4.12.0.",
  "id": "CVE-2026-54498",
  "modified": "2026-07-22T05:29:36.997094392Z",
  "published": "2026-07-17T20:46:52.176Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/ViewComponent/view_component/releases/tag/v4.12.0"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/54xxx/CVE-2026-54498.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/ViewComponent/view_component/security/advisories/GHSA-97jw-64cj-jc58"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-54498"
    },
    {
      "type": "FIX",
      "url": "https://github.com/ViewComponent/view_component/commit/48e5fd2d602344c7d33019fbc5c8b087e315bb78"
    },
    {
      "type": "FIX",
      "url": "https://github.com/ViewComponent/view_component/commit/6796b2e89d0bd7b9d7d763a86275e5334731dd61"
    }
  ],
  "schema_version": "1.8.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N",
      "type": "CVSS_V3"
    }
  ],
  "summary": "view_component: around_render HTML-Safety Bypass"
}