libxmljs vulnerable to type confusion when parsing specially crafted XML
Date: 2024-05
Affected: npm/libxmljs
Attack vector: rce
Category: vulnerability-disclosure
Severity: Critical
CVE: CVE-2024-34391
CVE-2024-34392
CWE: CWE-843
CVSS: 8.1 (CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H)

libxmljs is vulnerable to a type confusion vulnerability when parsing a specially crafted XML while invoking the `namespaces()` function (which invokes `_wrap__xmlNode_nsDef_get()`) on a grand-child of a node that refers to an entity. This vulnerability can lead to denial of service and remote code execution.


Mitigations:

Architectural layers (MAESTRO):