CVE-2026-126062: JRuby: NONET is bypassed for external DTDs and entities when the systemId uses a short-form IPv4 host
Published 2026-11-10 · Updated 2026-11-10 · Also known as GHSA-v995-44v6-5fqm
Summary
JRuby users of the Nokogiri gem are vulnerable to a Server-Side Request Forgery (SSRF) flaw when parsing untrusted XML with specific networking options enabled. Organizations using Nokogiri on JRuby should upgrade to version 1.19.5 or later to resolve this bypass of the NONET security constraint.
Who is affected
This vulnerability specifically affects JRuby environments where the NONET parse option is intended to restrict network access during XML parsing. Successful exploitation requires the application to explicitly enable DTDLOAD, DTDVALID, or NOENT options when processing untrusted XML. When these conditions are met, an attacker can bypass restrictions using short-form IPv4 addresses or absolute paths to force unauthorized network requests.
Exploitability
The vulnerability carries a low severity rating with a CVSS 3.1 base score of 3.7, indicating a requirement for specific configuration conditions and high complexity. With an EPSS score of 0.004, the likelihood of exploitation is low, and the issue is not currently listed in the CISA Known Exploited Vulnerabilities catalog.
Remediation
- Upgrade the nokogiri gem to version 1.19.5 or later.
- Disable DTDLOAD, DTDVALID, and NOENT parse options when handling untrusted XML input if an immediate upgrade is not feasible.
How to check your project
- Inspect Gemfile.lock to verify if the nokogiri version is below 1.19.5.
- Review application code for the presence of DTDLOAD, DTDVALID, or NOENT flags in Nokogiri XML parsing configurations.
Automated analysis of the published advisory data, generated 2026-11-19. Not human-reviewed; verify against the official advisory. How this works.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | Upgrade |
|---|---|---|---|---|
| RubyGems | nokogiri |
>= 0, < 1.19.5 | 1.19.5 | bundle update nokogiri |
CVSS 3.1 vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
| Attack vector | Network |
|---|---|
| Attack complexity | High |
| Privileges required | None |
| User interaction | None |
| Scope | Unchanged |
| Confidentiality | Low |
| Integrity | None |
| Availability | None |
FAQ
Does this vulnerability affect standard Ruby (MRI)?
No, the vulnerability is specific to JRuby environments.
Are default Nokogiri configurations affected?
No, default parse options are not affected by this vulnerability.
What is the primary risk of this flaw?
The primary risk is Server-Side Request Forgery (SSRF), where an attacker can influence the application to make unintended network requests.
Original advisory description
References
- WEB https://github.com/sparklemotion/nokogiri/security/advisories/GHSA-v995-44v6-5fqm
- WEB https://github.com/sparklemotion/nokogiri/pull/3752
- WEB https://github.com/sparklemotion/nokogiri/commit/97f41b65f4ee0cac859b87f0b26d2648c4806cb8
- WEB https://github.com/sparklemotion/nokogiri/commit/e448ca2827a9198644610fb730259e12baacdeac
- WEB https://github.com/rubysec/ruby-advisory-db/blob/master/gems/nokogiri/GHSA-v995-44v6-5fqm.yml
- PACKAGE https://github.com/sparklemotion/nokogiri
- WEB https://github.com/sparklemotion/nokogiri/releases/tag/v1.19.5
Source records: GHSA-v995-44v6-5fqm (OSV.dev) · EPSS by FIRST, 2026-11-21.