1024-lab SmartAdmin Server-Side Template Injection Vulnerability

Vulnerability

A server-side template injection vulnerability has been identified in 1024-lab/lab1024 SmartAdmin versions through 3.29. This issue arises in the email template rendering functionality, which utilizes the Apache FreeMarker template engine. The vulnerability is located in the 'freemarkerResolverContent' function of 'MailService.java'. An attacker with access to modify the 'template_content' field in the 't_mail_template' table can inject arbitrary FreeMarker expressions. These injected expressions are executed on the server when the email is sent, potentially leading to remote code execution with the application's server privileges, and allowing complete system compromise.

Impact

Exploitation of this vulnerability allows for server-side template injection, with the potential for remote code execution on the application server.

Reproduction

To reproduce this vulnerability, an attacker must have the ability to modify the 'template_content' field in the 't_mail_template' table. Once this access is obtained, arbitrary FreeMarker expressions can be injected into the template content. When an email is sent using the modified template, the injected expressions are executed on the server, leading to code execution.

Added: Mar 8, 2026, 9:22 AM
Updated: Mar 8, 2026, 9:22 AM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
10.0
exploitability
5.7
remediation
0.0
relevance
3.8
threat
6.4
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.