Server Side Template Injection (SSTI)
Resource for more complicated payloads: https://github.com/swisskyrepo/PayloadsAllTheThings
https://book.hacktricks.xyz/
Payloads Fuzzing:
${{<%'"}}%PoC Payload for Identification:
${7*'7'}Explaining further about more template engines here: https://book.hacktricks.xyz/pentesting-web/ssti-server-side-template-injection
Remediation:
1: Secure methods
2: Sanitization
Example payloads of different templates:
Go SSTI
1)
2)
3)
4)
PHP - Smarty
PoC Enumeration Payload
RCE Payload
NodeJS - Pug
PoC Payload
RCE Payload
SpawnSync RCE Payload with arguments
Python - Jinja2
PoC Payload
RCE Payload
check_output RCE Payload with arguments
PHP - Twig
PoC Payload
RCE Payload
Last updated