PT-2021-6745 · Smarty+2 · Smarty+2
Highwisskid
·
Published
2021-03-30
·
Updated
2022-12-08
·
CVE-2021-29454
CVSS v2.0
9.0
High
| Vector | AV:N/AC:L/Au:S/C:C/I:C/A:C |
Name of the Vulnerable Software and Affected Versions
Smarty versions prior to 3.1.42 and 4.0.2
Description
The issue is related to the incorrect handling of code generation in the Smarty template engine for PHP. This allows template authors to run arbitrary PHP code by crafting a malicious math string. If a math string is passed through as user-provided data to the math function, external users could run arbitrary PHP code by crafting a malicious math string.
Recommendations
To resolve the issue, users should upgrade to version 3.1.42 or 4.0.2 to receive a patch.
As a temporary workaround, consider restricting the use of the math function to minimize the risk of exploitation.
Avoid using user-provided data in the math function until the issue is resolved.
Exploit
Fix
Special Elements Injection
Code Injection
Found an issue in the description? Have something to add? Feel free to write us 👾
Related Identifiers
Affected Products
Linuxmint
Smarty
Ubuntu