# Xxe

> Hunt XML External Entity flaws in parsers and validate file read / SSRF impact with strict negative controls.

- Skill: `purpleailab/xxe` (Agent Skill)
- Install (CLI): `npx skillmds@latest add purpleailab/xxe`
- Raw SKILL.md: https://api.skillmd.com/api/skills/purpleailab/xxe/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: purpleailab (https://skillmd.com/u/purpleailab)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/purpleailab/xxe

---


# XXE Playbook

## Find parser sinks
- Java: `DocumentBuilderFactory`, `SAXParserFactory`, `XMLInputFactory`
- Python: `lxml.etree`, `xml.dom.minidom`, `xml.sax`
- .NET: `XmlDocument`, `XDocument`, `XmlReader`

## Dangerous defaults
- DTD enabled
- External entities enabled
- Network/file entity resolution enabled

## Payloads
- File read: entity to `file:///etc/passwd`
- SSRF: entity to internal URL (metadata service, localhost admin)

## Validation
- Positive: parser output contains file content or internal response markers.
- Negative: same XML without entity expansion must not leak content.

