CVE-2025-71406: Nokogiri before 1.18.4 Use-After-Free via libxslt

Published Aug 25, 2026
·
Updated

Nokogiri before 1.18.4 bundles a vulnerable version of libxslt (prior to 1.1.43) that contains two use-after-free vulnerabilities: CVE-2025-24855 (use-after-free of the XPath context node due to xsltEvalXPathStringNs leaking xpathCtxt->node) and CVE-2024-55549 (use-after-free related to excluded result prefixes/namespaces). Processing crafted XSLT can trigger memory corruption. Nokogiri 1.18.4 upgrades the bundled libxslt to 1.1.43 to resolve these issues.

Affected Software

2 affected components
rubygems/nokogiri<1.18.4
bundled/libxslt<1.1.43

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade Nokogiri to a version that resolves this vulnerability.

    Fixed in 1.18.4Patch CVE-2025-24855
  2. Upgrade

    Upgrade Nokogiri to a version that resolves this vulnerability.

    Fixed in 1.18.4Patch CVE-2024-55549

Event History

Aug 25, 2026
CVE Published
via MITRE·03:15 PM
Data Sourced
via MITRE·03:15 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·04:16 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

Which deployments are exposed?

Deployments using Nokogiri before 1.18.4 are exposed because those releases bundle libxslt versions prior to 1.1.43. The issue is relevant where the application processes crafted XSLT.

2

What must an attacker provide to trigger the flaw?

An attacker needs crafted XSLT that reaches Nokogiri's bundled libxslt processing. The vulnerable libxslt code can then trigger use-after-free conditions involving XPath context nodes or excluded result prefixes/namespaces, leading to memory corruption.

3

What version resolves the bundled dependency issue?

Upgrade Nokogiri to 1.18.4 or later. Version 1.18.4 updates the bundled libxslt to 1.1.43, which resolves the identified use-after-free vulnerabilities.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203