SSTI can occur when an attacker inserts code into template files which then get compiled by the server. This can lead to the execution of malicious code on the server.
‍