CVE-2025-29699

Description

A use after free flaw has been discovered in NetSurf. The Node.textContent setter is handled by libdom's _dom_node_set_text_content function, which removes the specified node's children and replaces them with a single text node. It calls dom_node_remove_child in a loop to detach each child node from the tree. After each call, it decrements the child node's reference count via dom_node_unref, which causes the node to be freed if the count drops to 0. If a registered handler sets the parent node's text content again, a nested call to _dom_node_set_text_content will occur, and the node's children may be freed due to the reference count decrement. When the event dispatcher of the original call chain resumes execution, it may access a freed child, resulting in a use-after-free.

Statement

Red Hat Product Security has determined that this vulnerability does not affect any currently supported Red Hat product. This assessment may evolve based on further analysis and discovery. For more information about this vulnerability and the products it affects, please see the linked references.

Mitigation

Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.

Understanding the Weakness (CWE)

Confidentiality

Technical Impact: Read Memory

If the expired pointer is used in a read operation, an attacker might be able to control data read in by the application.

Availability

Technical Impact: DoS: Crash, Exit, or Restart

If the expired pointer references a memory location that is not accessible to the product, or points to a location that is "malformed" (such as NULL) or larger than expected by a read or write operation, then a crash may occur.

Integrity,Confidentiality,Availability

Technical Impact: Execute Unauthorized Code or Commands

If the expired pointer is used in a function call, or points to unexpected data in a write operation, then code execution may be possible.

Frequently Asked Questions

Want to get errata notifications? Sign up here.