CDATA Section Breakout via Unsanitised ]]> in xml_builder
XML Injection vulnerability in joshnuss xml_builder (XmlBuilder module) allows Content Spoofing, XML Injection. This vulnerability is associated with program files lib/xml_builder.ex and program routines XmlBuilder.generate/1, XmlBuilder.generate/2, XmlBuilder.escape/1. The escape/1 clause for {:cdata, data} in lib/xml_builder.ex concatenates data verbatim between the CDATA opener without rewriting or splitting on the embedded ]]> sequence. Because CDATA sections have no internal escape mechanism, the only safe way to embed arbitrary bytes is to split on ]]> and emit adjacent CDATA sections. An attacker who can supply input containing ]]> closes the CDATA section early; any bytes that follow are parsed as ordinary XML markup by downstream consumers, allowing injection of arbitrary elements, text, or entity references into the output document. This issue affects xml_builder: from 0.0.7 before 2.4.1.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2026-47080
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 4 Nov 2026, 18:38 UTC · Revision 1
Source evidence
CDATA Section Breakout via Unsanitised ]]> in xml_builder
core-osv · Original sourcePublished 21 Aug 2026, 09:49 UTC
XML Injection vulnerability in joshnuss xml_builder (XmlBuilder module) allows Content Spoofing, XML Injection. This vulnerability is associated with program files lib/xml_builder.ex and program routines XmlBuilder.generate/1, XmlBuilder.generate/2, XmlBuilder.escape/1. The escape/1 clause for {:cdata, data} in lib/xml_builder.ex concatenates data verbatim between the CDATA opener without rewriting or splitting on the embedded ]]> sequence. Because CDATA sections have no internal escape mechanism, the only safe way to embed arbitrary bytes is to split on ]]> and emit adjacent CDATA sections. An attacker who can supply input containing ]]> closes the CDATA section early; any bytes that follow are parsed as ordinary XML markup by downstream consumers, allowing injection of arbitrary elements, text, or entity references into the output document. This issue affects xml_builder: from 0.0.7 before 2.4.1.
osv:CVE-2026-47080
Complete source record
{
"id": "f592e8a3d6ee2d6ca7fb869b8049a59734d30eaed1860206e345a010af27dba3",
"url": "https://osv.dev/vulnerability/CVE-2026-47080",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "CDATA Section Breakout via Unsanitised ]]> in xml_builder",
"summary": "XML Injection vulnerability in joshnuss xml_builder (XmlBuilder module) allows Content Spoofing, XML Injection. This vulnerability is associated with program files lib/xml_builder.ex and program routines XmlBuilder.generate/1, XmlBuilder.generate/2, XmlBuilder.escape/1. The escape/1 clause for {:cdata, data} in lib/xml_builder.ex concatenates data verbatim between the CDATA opener without rewriting or splitting on the embedded ]]> sequence. Because CDATA sections have no internal escape mechanism, the only safe way to embed arbitrary bytes is to split on ]]> and emit adjacent CDATA sections. An attacker who can supply input containing ]]> closes the CDATA section early; any bytes that follow are parsed as ordinary XML markup by downstream consumers, allowing injection of arbitrary elements, text, or entity references into the output document. This issue affects xml_builder: from 0.0.7 before 2.4.1.",
"evidence": "osv:CVE-2026-47080",
"products": [],
"severity": "low",
"structured": {
"id": "CVE-2026-47080",
"aliases": [
"CVE-2026-47080",
"EEF-CVE-2026-47080",
"GHSA-67r9-hmxw-h595"
],
"metrics": [
{
"type": "CVSS_V4",
"score": "CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:N/SC:N/SI:L/SA:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/joshnuss/xml_builder",
"type": "GIT",
"events": [
{
"introduced": "26766f884ed19adee1563522c7afb5f056a6f3b5"
},
{
"fixed": "bfb1ada071ccc1e384c30f782197ca5154106706"
}
],
"database_specific": {
"extracted_events": [
{
"range": [
{
"introduced": "26766f884ed19adee1563522c7afb5f056a6f3b5"
},
{
"fixed": "bfb1ada071ccc1e384c30f782197ca5154106706"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StandardRange"
},
{
"range": [
{
"fixed": "bfb1ada071ccc1e384c30f782197ca5154106706"
}
],
"source": "REFERENCES_COMMIT"
}
]
}
}
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-47080.json"
}
}
],
"modified": "2026-10-28T02:30:38.173512099Z",
"provider": "osv",
"references": [
"https://cna.erlef.org/cves/CVE-2026-47080.html",
"https://github.com",
"https://osv.dev/vulnerability/EEF-CVE-2026-47080",
"https://repo.hex.pm",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/47xxx/CVE-2026-47080.json",
"https://github.com/joshnuss/xml_builder/security/advisories/GHSA-67r9-hmxw-h595",
"https://nvd.nist.gov/vuln/detail/CVE-2026-47080",
"https://github.com/joshnuss/xml_builder/commit/bfb1ada071ccc1e384c30f782197ca5154106706",
"https://github.com/joshnuss/xml_builder",
"https://vincent.vulcoord.net/score/?state=Not+Scored&year=2026&year=2025&assigned_to=88bc49d9-8ddd-4227-affc-a613e67abc4d&ordering=-published&cve=CVE-2026-47080"
],
"provider_metadata": {
"cwe_ids": [
"CWE-91"
],
"cna_assigner": "EEF",
"unresolved_ranges": [
{
"extracted_events": [
{
"range": [
{
"introduced": "0.0.7"
},
{
"fixed": "2.4.1"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StandardRange"
}
]
}
],
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/47xxx/CVE-2026-47080.json"
}
},
"related_cves": [
{
"value": "CVE-2026-47080",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 505768,
"published_at": "2026-08-21T09:49:34.772+00:00"
}