Lab: Server-side template injection using documentation
Summary: PortSwigger published a lab in which the target application is vulnerable to server-side template injection, and solving it requires identifying the template engine and using its documentation to work out how to execute arbitrary code. The goal is to delete the morale.txt file from Carlos's home directory, with the option of adapting a well-known exploit by @albinowax if the documentation-only approach fails.
What you should know: The exercise shows that a template engine's own documentation can be enough to turn an injection point into arbitrary code execution and file deletion in a user's home directory, so the reference material you rely on for legitimate development is also an attacker's playbook.
Read the original at PortSwigger Research ↗
- Topics
- Vulnerabilities & Patching
- Related
- Attackers Exploit UnrealIRCd Flaw That Enables Server-Level Command Injection Cyber Risks · Nov 14, 2026U.S. CISA adds Check Point and UnrealIRCd flaws to its Known Exploited Vulnerabilities catalog Cyber Risks · Nov 14, 2026PostgreSQL Patches 52 Flaws, Including 22-Year-Old Bug Enabling Authenticated RCE Cyber Risks · Nov 13, 2026