CVE-2026-41401

libyang - Heap Use-After-Free Write in XML Metadata Parsing

State
Published
Severity
6.9 Medium
Published
May 26, 2026
Updated
Oct 29, 2026
Reserved
Apr 20, 2026

Read the record on cve.org

Description

libyang before 5.4.3 contains a heap use-after-free write vulnerability in lyd_parser_set_data_flags that incorrectly updates metadata list pointers when freeing non-head default metadata entries. Attackers can trigger this vulnerability by submitting crafted YANG XML documents with specific metadata attributes to applications parsing untrusted XML data, causing process crashes or potential code execution.

Scores

CVSSScoreVectorSource
4.06.9 MediumCVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:NVulnCheck
3.16.5 MediumCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:HVulnCheck

Weaknesses

Affected Products

ProductVersions
libyanglibyang
  • before 5.4.3Affected
  • 5.4.3Not affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.