CVE-2026-25896: CWE-185: Incorrect Regular Expression in NaturalIntelligence fast-xml-parser
fast-xml-parser allows users to validate XML, parse XML to JS object, or build XML from JS object without C/C++ based libraries and no callback. From 4.1.3to before 5.3.5, a dot (.) in a DOCTYPE entity name is treated as a regex wildcard during entity replacement, allowing an attacker to shadow built-in XML entities (<, >, &, ", ') with arbitrary values. This bypasses entity encoding and leads to XSS when parsed output is rendered. This vulnerability is fixed in 5.3.5.
AI Analysis
Technical Summary
The fast-xml-parser library versions >=4.1.3 and <5.3.5 contain a flaw where a dot character in a DOCTYPE entity name is incorrectly treated as a regular expression wildcard during entity replacement. This incorrect handling allows an attacker to shadow built-in XML entities such as <, >, &, ", and ' with arbitrary values. As a result, entity encoding can be bypassed, leading to Cross-Site Scripting (CWE-79) when the parsed XML output is subsequently rendered in a user context. The vulnerability has a CVSS v3.1 score of 9.3 (critical) and is fixed in version 5.3.5 of fast-xml-parser. Red Hat classifies this flaw as important for its products, noting that the impact is limited to the user's browser context and requires user interaction to trigger the XSS. No known exploits are reported in the wild. The vendor advisory and Red Hat advisory confirm the vulnerability and the availability of a fix in version 5.3.5.
Potential Impact
This vulnerability allows an attacker to bypass XML entity encoding protections and inject arbitrary scripts into the parsed XML output. When this output is rendered in a user's browser, it can lead to Cross-Site Scripting (XSS), potentially enabling unauthorized code execution in the context of the victim's browser. The impact is limited to the confidentiality and integrity of the user's browser session and does not affect system availability. The vulnerability requires that the malicious XML be parsed and the output rendered to a user, thus involving user interaction. No active exploitation has been reported.
Mitigation Recommendations
A fix is available in fast-xml-parser version 5.3.5. Users and vendors are advised to upgrade to this version to remediate the vulnerability. Red Hat currently has no alternative mitigations that meet their criteria for ease of use and applicability. Therefore, upgrading to the fixed version is the recommended remediation.
CVE-2026-25896: CWE-185: Incorrect Regular Expression in NaturalIntelligence fast-xml-parser
Description
fast-xml-parser allows users to validate XML, parse XML to JS object, or build XML from JS object without C/C++ based libraries and no callback. From 4.1.3to before 5.3.5, a dot (.) in a DOCTYPE entity name is treated as a regex wildcard during entity replacement, allowing an attacker to shadow built-in XML entities (<, >, &, ", ') with arbitrary values. This bypasses entity encoding and leads to XSS when parsed output is rendered. This vulnerability is fixed in 5.3.5.
CVSS v3.1
Score 9.3critical
Affected software
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The fast-xml-parser library versions >=4.1.3 and <5.3.5 contain a flaw where a dot character in a DOCTYPE entity name is incorrectly treated as a regular expression wildcard during entity replacement. This incorrect handling allows an attacker to shadow built-in XML entities such as <, >, &, ", and ' with arbitrary values. As a result, entity encoding can be bypassed, leading to Cross-Site Scripting (CWE-79) when the parsed XML output is subsequently rendered in a user context. The vulnerability has a CVSS v3.1 score of 9.3 (critical) and is fixed in version 5.3.5 of fast-xml-parser. Red Hat classifies this flaw as important for its products, noting that the impact is limited to the user's browser context and requires user interaction to trigger the XSS. No known exploits are reported in the wild. The vendor advisory and Red Hat advisory confirm the vulnerability and the availability of a fix in version 5.3.5.
Potential Impact
This vulnerability allows an attacker to bypass XML entity encoding protections and inject arbitrary scripts into the parsed XML output. When this output is rendered in a user's browser, it can lead to Cross-Site Scripting (XSS), potentially enabling unauthorized code execution in the context of the victim's browser. The impact is limited to the confidentiality and integrity of the user's browser session and does not affect system availability. The vulnerability requires that the malicious XML be parsed and the output rendered to a user, thus involving user interaction. No active exploitation has been reported.
Mitigation Recommendations
A fix is available in fast-xml-parser version 5.3.5. Users and vendors are advised to upgrade to this version to remediate the vulnerability. Red Hat currently has no alternative mitigations that meet their criteria for ease of use and applicability. Therefore, upgrading to the fixed version is the recommended remediation.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-02-06T21:08:39.130Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Vendor Advisory Urls
- [{"url":"https://access.redhat.com/security/cve/CVE-2026-25896","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:7110","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:7128","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:6174","vendor":"Red Hat"},{"url":"https://access.redhat.com/errata/RHSA-2026:6802","vendor":"Red Hat"}]
Threat ID: 6998cf5abe58cf853bb24fa1
Added to database: 02/20/2026, 21:17:14 UTC
Last enriched: 08/14/2026, 13:06:33 UTC
Last updated: 08/25/2026, 11:02:25 UTC
Views: 1455
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.