{
  "id": "cve-2026-57235",
  "title": "Nokogiri NodeSet index truncation out-of-bounds read",
  "product": "Nokogiri",
  "ai_system": "depthfirst AI security agents (specific model not identified for this Ruby research)",
  "organization": "depthfirst / respective project maintainers",
  "summary": "Nokogiri truncates a large negative index to 32 bits during its bounds check, then uses the original full-width value, allowing an out-of-bounds read on CRuby. On JRuby this returns an incorrect node without memory-unsafety.",
  "ai_role": "depthfirst’s primary July 27, 2026 Ruby ecosystem report identifies CVE-2026-57235 as an issue uncovered in the research, and says its AI security agents analyzed the projects and validated each finding with a triggering input, reproduction script and evidence such as ASan output before manual review. The issue-specific section describes this exact vulnerability. The affected project maintainer advisory validates the vulnerability and fix. No specific model or per-case human/agent split is stated.",
  "disclosure_date": "2026-06-25",
  "ai_attribution_date": "2026-07-27",
  "classification": "disclosure",
  "classification_note": "The maintainer advisory and CNA record provide public dates for CVE-2026-57235; the depthfirst account is dated 2026-07-27. The sources do not report exploitation in the wild or establish zero-day status.",
  "cves": [
    "CVE-2026-57235"
  ],
  "source_url": "https://github.com/sparklemotion/nokogiri/security/advisories/GHSA-5prr-v3j2-97mh",
  "ai_source_url": "https://depthfirst.com/research/behind-the-gitlab-rce-a-depthfirst-journey-into-the-ruby-ecosystem",
  "advisory_url": "https://github.com/sparklemotion/nokogiri/security/advisories/GHSA-5prr-v3j2-97mh",
  "remediation": "fix documented",
  "remediation_note": "Nokogiri is an open source XML and HTML library for the Ruby programming language. Prior to 1.19.4, Nokogiri::XML::NodeSet#[] (and its alias #slice) checked the requested index against the node set's bounds using a 32-bit-truncated copy of the index. A large negative index could pass the check and then be used at full width, reading outside the node set's storage. On CRuby this is an out-of-bounds read that typically crashes the process; on JRuby it is not memory-unsafe but returns an incorrect node. This vulnerability is fixed in 1.19.4. This documents upstream package version guidance and does not establish downstream distribution patch state.",
  "checked_date": "2026-11-17",
  "impacts": [
    {
      "cves": [
        "CVE-2026-57235"
      ],
      "consequences": [
        "denial of service"
      ],
      "conditions": "An application must pass an attacker-controlled integer to Nokogiri::XML::NodeSet#[] or #slice; memory-safety impact is limited to CRuby.",
      "exploitation": "Maintainers describe a controlled crash and possible memory disclosure on CRuby; the article describes upstream discovery/validation. No exploitation in the wild is established.",
      "source_url": "https://github.com/sparklemotion/nokogiri/security/advisories/GHSA-5prr-v3j2-97mh",
      "checked_date": "2026-11-17"
    }
  ],
  "cvss": [
    {
      "cve": "CVE-2026-57235",
      "version": "4.0",
      "score": 6.3,
      "vector": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N",
      "source_url": "https://raw.githubusercontent.com/CVEProject/cvelistV5/main/cves/2026/57xxx/CVE-2026-57235.json",
      "source_name": "CNA CVE Program record",
      "checked_date": "2026-11-17"
    }
  ]
}
