nokogiri vulnerabilities
Nokogiri (鋸) makes it easy and painless to work with XML and HTML from Ruby. It provides a sensible, easy-to-understand API for reading, writing, modifying, and querying documents. It is fast and standards-compliant by relying on native parsers like libxml2, libgumbo, or xerces.
- Registry
- RubyGems
- Latest
- 1.19.7
- License
- MIT
60 known advisories
The latest version, 1.19.7, is not affected by any of them. Projects on older versions may be.
bundle update --conservative nokogiri # Gemfile: '>= 1.19.7'Is your project on an affected nokogiri?
Look after several Rails or Ruby apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Security advisories for nokogiri
JRuby: NONET is bypassed for external DTDs and entities when the systemId uses a short-form IPv4 host
- Affected
- <1.19.5
- Fixed in
- 1.19.5
Nokogiri: Use-After-Free in Nokogiri when replacing an attribute value
- Affected
- <1.19.5
- Fixed in
- 1.19.5
Nokogiri: Mutation XSS through `noscript` content in Nokogiri's HTML5 serializer
- Affected
- >=1.12.0 <1.19.5
- Fixed in
- 1.19.5
Nokogiri: Possible Use-After-Free when setting an attribute value via `Nokogiri::XML::Attr#value=` or `#content=`
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: Possible Use-After-Free in XInclude Processing
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: Possible Use-After-Free when directly using `NokogirI::XML::XPathContext` beyond document lifetime
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: Possible Use-After-Free when setting `Document#root=` to an invalid node type
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: Possible Out-of-Bounds Read in `Nokogiri::XML::NodeSet#[]`
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: Null Pointer Dereference calling methods on uninitialized wrapper classes
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: XML::Schema on JRuby allows network requests when NONET is set, bypassing CVE-2020-26247
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri: Possible Use-After-Free when `Nokogiri::XML::Document#encoding=` raises an exception
- Affected
- <1.19.4
- Fixed in
- 1.19.4
Nokogiri XSLT transform has a memory leak
- Affected
- <1.19.3
- Fixed in
- 1.19.3
Nokogiri CSS selector tokenizer has regular expression backtracking
- Affected
- <1.19.3
- Fixed in
- 1.19.3
Nokogiri does not check the return value from xmlC14NExecute
- Affected
- >=1.5.1 <1.19.1
- Fixed in
- 1.19.1
Nokogiri patches vendored libxml2 to resolve multiple CVEs
- Affected
- <1.18.9
- Fixed in
- 1.18.9
Nokogiri updates packaged libxml2 to v2.13.8 to resolve CVE-2025-32414 and CVE-2025-32415
- Affected
- <1.18.8
- Fixed in
- 1.18.8
Nokogiri updates packaged libxslt to v1.1.43 to resolve multiple CVEs
- Affected
- <1.18.4
- Fixed in
- 1.18.4
Nokogiri updates packaged libxml2 to 2.13.6 to resolve CVE-2025-24928 and CVE-2024-56171
- Affected
- <1.18.3
- Fixed in
- 1.18.3
Nokogiri updates packaged libxml2 to v2.12.7 to resolve CVE-2024-34459
- Affected
- <1.16.5
- Fixed in
- 1.16.5
Nokogiri update packaged libxml2 to v2.12.5 to resolve CVE-2024-25062
- Affected
- >=1.16.0 <1.16.2 · <1.15.6
- Fixed in
- 1.15.6, 1.16.2
Nokogiri updates packaged libxml2 to v2.10.4 to resolve multiple CVEs
- Affected
- <1.14.3
- Fixed in
- 1.14.3
Unchecked return value from xmlTextReaderExpand
- Affected
- >=1.13.8 <1.13.10
- Fixed in
- 1.13.10
Update bundled libxml2 to v2.10.3 to resolve multiple CVEs
- Affected
- <1.13.9
- Fixed in
- 1.13.9
Nokogiri has vulnerable dependencies on libxml2 and libxslt
- Affected
- <1.13.2
- Fixed in
- 1.13.2
Nokogiri contains libxml Out-of-bounds Write vulnerability
- Affected
- <1.11.4
- Fixed in
- 1.11.4
Nokogiri Implements libxml2 version vulnerable to use-after-free
- Affected
- <1.11.4
- Fixed in
- 1.11.4
Nokogiri Implements libxml2 version vulnerable to null pointer dereferencing
- Affected
- <1.11.4
- Fixed in
- 1.11.4
Nokogiri implementation of libxslt vulnerable to heap corruption
- Affected
- <1.10.5
- Fixed in
- 1.10.5
Nokogiri affected by libxslt Use of Uninitialized Resource/Use After Free vulnerability
- Affected
- <1.10.5
- Fixed in
- 1.10.5
libxslt Type Confusion vulnerability that affects Nokogiri
- Affected
- <1.10.5
- Fixed in
- 1.10.5
Uninitialized read in Nokogiri gem
- Affected
- <1.10.5
- Fixed in
- 1.10.5
Nokogiri Improperly Handles Unexpected Data Type
- Affected
- <1.13.6
- Fixed in
- 1.13.6
Integer Overflow or Wraparound in libxml2 affects Nokogiri
- Affected
- <1.13.5
- Fixed in
- 1.13.5
Nokogiri gem, via libxml, is affected by DoS vulnerabilities
- Affected
- <1.8.2
- Fixed in
- 1.8.2
Nokogiri vulnerable to libxslt protection mechanism bypass
- Affected
- <1.10.3
- Fixed in
- 1.10.3
Nokogiri gem, via libxml, is affected by DoS vulnerabilities
- Affected
- <1.8.1
- Fixed in
- 1.8.1
Nokogiri vulnerable to DoS while parsing XML documents
- Affected
- >=1.5.0 <1.5.11 · >=1.6.0 <1.6.1
- Fixed in
- 1.5.11, 1.6.1
Nokogiri vulnerable to DoS while parsing XML entities
- Affected
- >=1.5.0 <1.5.11 · >=1.6.0 <1.6.1
- Fixed in
- 1.5.11, 1.6.1
Nokogiri is vulnerable to XML External Entity (XXE) attack
- Affected
- <1.5.4
- Fixed in
- 1.5.4
Denial of Service (DoS) in Nokogiri on JRuby
- Affected
- <1.13.4
- Fixed in
- 1.13.4
XML Injection in Xerces Java affects Nokogiri
- Affected
- <1.13.4
- Fixed in
- 1.13.4
Out-of-bounds Write in zlib affects Nokogiri
- Affected
- <1.13.4
- Fixed in
- 1.13.4
Nokogiri Inefficient Regular Expression Complexity
- Affected
- <1.13.4
- Fixed in
- 1.13.4
Nokogiri affected by zlib's Out-of-bounds Write vulnerability
- Affected
- <1.13.4
- Fixed in
- 1.13.4
Vulnerable dependencies in Nokogiri
- Affected
- <1.13.2
- Fixed in
- 1.13.2
Improper Restriction of XML External Entity Reference (XXE) in Nokogiri on JRuby
- Affected
- <1.12.5
- Fixed in
- 1.12.5
Nokogiri updates packaged dependency on libxml2 from 2.9.10 to 2.9.12
- Affected
- <1.11.4
- Fixed in
- 1.11.4
Nokogiri::XML::Schema trusts input by default, exposing risk of XXE vulnerability
- Affected
- <1.11.0
- Fixed in
- 1.11.0
libxml as used in Nokogiri has an infinite loop in a certain end-of-file situation
- Affected
- <1.10.8
- Fixed in
- 1.10.8
Nokogiri Command Injection Vulnerability
- Affected
- <1.10.4
- Fixed in
- 1.10.4
Nokogiri NULL Pointer Dereference
- Affected
- <1.8.5
- Fixed in
- 1.8.5
Heap-based buffer overflow in nokogiri
- Affected
- >=1.6.0 <1.6.7.2
- Fixed in
- 1.6.7.2
Denial of service or RCE from libxml2 and libxslt
- Affected
- >=1.6.0 <1.6.8
- Fixed in
- 1.6.8
Nokogiri does not forbid namespace nodes in XPointer ranges
- Affected
- <1.7.1
- Fixed in
- 1.7.1
Nokogiri subject to DoS via libxml2 vulnerability
- Affected
- >=1.6.0 <1.6.7.1
- Fixed in
- 1.6.7.1
Nokogiri vulnerable to libxml XML Entity Expansion
- Affected
- >=1.6.6.0 <1.6.6.4
- Fixed in
- 1.6.6.4
Nokogiri implementation of libxslt lacks integer overflow checks
- Affected
- <1.7.2
- Fixed in
- 1.7.2
Uncontrolled resource consumption in nokogiri
- Affected
- <1.8.2
- Fixed in
- 1.8.2
Cross-site Scripting in loofah
- Affected
- <1.8.3
- Fixed in
- 1.8.3
Out-of-bounds read in nokogiri
- Affected
- <1.8.1
- Fixed in
- 1.8.1
Is your nokogiri version vulnerable?
Which of your client projects still run an old nokogiri?
NPMscan reads the Gemfile.lock in every GitHub repo you pick and checks each installed version against these advisories, including the packages your packages pull in. Each finding comes with the command that fixes it.
Other RubyGems packages
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily. Package details from the RubyGems registry.