XXE
Detection:
# Content type "application/json" or "application/x-www-form-urlencoded" to "applcation/xml".
# File Uploads allows for docx/xlsx/pdf/zip, unzip the package and add your evil xml code into the xml files.
# If svg allowed in picture upload, you can inject xml in svgs.
# If the web app offers RSS feeds, add your malicious code into the RSS.
# Fuzz for /soap api, some applications still running soap apis
# If the target web app allows for SSO integration, you can inject your milicious xml code in the SAML request/reponse
Check:
<?xml version="1.0"?>
<!DOCTYPE a [<!ENTITY test "THIS IS A STRING!">]>
<methodCall><methodName>&test;</methodName></methodCall>
URL | Description |
---|---|
https://github.com/payloadbox/xxe-injection-payload-list | Payloads |
https://gist.github.com/staaldraad/01415b990939494879b4 | Payloads |
https://pentestbook.six2dez.com/enumeration/web/xxe | XXE info |