# CVE-2026-66295: Processing instruction target and content emitted unescaped in Saxy encoder allows XML injection

- Severity: Low 2.1 (CVSS:4.0, scored by EEF) `CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:L/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.21%, higher than 12% of CVEs (2026-12-01)
- Published: 2026-11-06T10:16:45.577Z
- Modified: 2026-11-26T17:23:03.231Z
- Also known as: EEF-CVE-2026-66295, GHSA-f9r9-vrxq-g566
- Weaknesses: CWE-91
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: EEF

## Description

Saxy's XML encoder writes the target and the content of a processing instruction into the output document verbatim, without validation or escaping. The encoder builds the construct by concatenating both fields between <? and ?>, so neither field is checked against the constraints the XML specification places on it.

Because ?> terminates a processing instruction, a target or content value containing that sequence closes the construct at a position the attacker chooses. Everything the attacker writes after it is emitted as ordinary markup at document level, which allows arbitrary elements, attributes, and further processing instructions to be injected into the serialized document. Appending a matching <? keeps the encoder's own terminator well-formed, so the result still parses and the injection is silent rather than a visible corruption. The target is additionally unconstrained by the XML Name production, which permits injection before the remainder of the processing instruction.

The result is XML injection into a serialized document: the tree the application asks Saxy to encode and the tree a downstream parser reads back are no longer the same. Character data, attribute values, and comments are all escaped by the encoder, so processing instructions are the one construct that passes user bytes through untouched. Since Saxy.XML.processing_instruction/2 is a documented public builder, an application inherits the flaw without misusing the API. The consequences depend on what consumes the XML: forged records in a feed or export read by another system, injected stylesheet or rendering directives, or active content where the output is served to a browser as XML or SVG.

This issue affects saxy: from 0.7.0 before 1.7.0.

(As written by CVE List.)

## Affected

- saxy: from 0.7.0 before 1.7.0
- qcam/saxy: from 7266632e9407842f28ffac254c56dc41210a5690 before 4aeb80e2acc318f57bd7453ad2eafd59101a90e0
- saxy (Hex): from 0.7.0 before 1.7.0
- https://github.com/qcam/saxy: from 7266632e9407842f28ffac254c56dc41210a5690 before 4aeb80e2acc318f57bd7453ad2eafd59101a90e0

## Every score

- EEF: CVSS:4.0 2.1 Low `CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:L/SA:N`
- Erlang Ecosystem Foundation: CVSS:4.0 `CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:L/SA:N`

## References

- <https://github.com/qcam/saxy/security/advisories/GHSA-f9r9-vrxq-g566> (advisory, related, vendor-advisory)
- <https://cna.erlef.org/cves/CVE-2026-66295.html> (related, web)
- <https://osv.dev/vulnerability/EEF-CVE-2026-66295> (related)
- <https://github.com/qcam/saxy/commit/7266632e9407842f28ffac254c56dc41210a5690> (related, web)
- <https://github.com/qcam/saxy/commit/4aeb80e2acc318f57bd7453ad2eafd59101a90e0> (fix, patch)
- <https://hex.pm/packages/saxy> (package)

## Sources

- CVE List: [CVE-2026-66295](https://www.cve.org/CVERecord?id=CVE-2026-66295), CVE Terms of Use, modified 2026-11-19
- Erlang Ecosystem Foundation: [EEF-CVE-2026-66295](https://osv.dev/vulnerability/EEF-CVE-2026-66295), CC-BY-4.0, modified 2026-11-26
- NVD: [CVE-2026-66295](https://nvd.nist.gov/vuln/detail/CVE-2026-66295), Public domain, modified 2026-11-12

---

Page: https://cve.day/CVE-2026-66295 · Whole record: https://cve.day/CVE-2026-66295.json · Rebuilt by cve.day 2026-11-26T17:37:06.928Z
