Live threats

All CVEs / Nokogiri

CVE-2022-29181Nokogiri

High 8.2 No auth needed

Priority
64
CVSS 3.1
8.2
EPSS
2.6%
probability of exploitation in 30 days · percentile 86
Auth required
No
Published
May 20, 2022
Updated
Jun 17, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-241, CWE-843
SSVC (CISA)
Exploitation: proof of concept · Automatable: yes · Technical impact: partial
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H

What happens

Nokogiri is an open source XML and HTML library for Ruby. Nokogiri prior to version 1.13.6 does not type-check all inputs into the XML and HTML4 SAX parsers, allowing specially crafted untrusted inputs to cause illegal memory access errors (segfault) or reads from unrelated memory. Version 1.13.6 contains a patch for this issue. As a workaround, ensure the untrusted input is a `String` by calling `#to_s` or equivalent.

Original NVD text.

What to do

  1. Apply the vendor's security update for Nokogiri.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
RubyGems nokogiri < 1.13.6 1.13.6 gem "nokogiri", ">= 1.13.6"

Per OSV / GitHub Advisories (GHSA-xh29-r2w5-wx8m). Check the version in your lockfile before upgrading.

Affected products (CPE)

VendorProductVersions
nokogirinokogiri< 1.13.6
applemacos≥ 13.0 < 13.1

Official advisories

Vendor, CERT and distribution advisories that name this CVE. Original titles.

Official sources

References

Links published by the sources. Open them with care.