How to use XXE to your Advantage
summary
Demonstrates using an external DTD callback to force a vulnerable XML parser to fetch a remote DTD, read /etc/passwd, and send it to an attacker-controlled port; a Python tool Doulos (Python3) generates the XML payload and DTD and the demo achieves retrieval via a netcat listener with a base64 chunk that is decoded to reveal the passwd file. Covers mitigations: disable external entities, validate XML against a strict schema, and patch XML parsers.
AI-written summary · about
chapters (40)
- 0:00Introduction
- 3:38Roadmap
- 4:11Key takeaways
- 5:15What is XXE
- 6:02What does XXE mean
- 6:49Remote code execution
- 7:49Overview of XML
- 9:31What uses XML
- 10:04Wellformed XML
- 11:31Wellformed Example
- 12:18Valid Example
- 13:32XXE Attacks
- 15:41XXE Error
- 15:58Outofband
- 16:39Demo
- 17:04Parser
- 17:36attacker terminal
- 18:02how this attack will work
- 18:56open to the public
- 19:29Python 2 vs Python 3
- 20:02Doulos
- 20:13Halloween
- 20:34Fun fact
- 20:54Create XXE payload
- 21:47Create DTD file
- 23:04Variables
- 23:14Instructions
- 27:23Base64
- 27:36Port Base64
- 28:16SuperDuper
- 29:03Red Team
- 29:18XXE Limitations
- 30:02Base64 Limitations
- 30:28Detection Prevention
- 35:19Red Blue Purple Teams
- 35:49XXE is boring
- 37:20Penetration testing vs Red teaming
- 41:46Blue teaming
- 50:16Devils Advocate
- 56:13Questions
