CVE Catalog

GHSA-phwj-rprq-35pp

Low
Published: Translated: NVD NIST

Summary

Nokogiri's CRuby native extension could leave a Ruby wrapper pointing to freed memory when replacing the value of an XML attribute. If Ruby code had already accessed an attribute child node, `Nokogiri::XML::Attr#value=` could free the underlying native child node while the wrapper remains.

Risk Assessment

The risk involves a potential use-after-free vulnerability, which could lead to unpredictable application behavior, crashes, or potential remote code execution by an attacker.

Recommendation

It is recommended to immediately update Nokogiri to the latest patched version. Avoid using `Nokogiri::XML::Attr#value=` on attributes whose child nodes have been previously accessed until the update is applied.

Original NVD description (English source)

### Summary Nokogiri's CRuby native extension could leave a Ruby wrapper pointing to freed memory when replacing the value of an XML attribute. If Ruby code had already accessed an attribute child node, `Nokogiri::XML::Attr#value=` could free the underlying native child node while the wrapper remai

Vulnerability data from NVD (NIST) · CISA KEV · EPSS