CVE-2022-29221
Description
Smarty is a template engine for PHP, facilitating the separation of presentation (HTML/CSS) from application logic. Prior to versions 3.1.45 and 4.1.1, template authors could inject php code by choosing a malicious {block} name or {include} file name. Sites that cannot fully trust template authors should upgrade to versions 3.1.45 or 4.1.1 to receive a patch for this issue. There are currently no known workarounds.
How to fix
- smarty smarty3.1.45, 4.1.1 or later
- smarty/smarty3.1.45, 4.1.1 or later
- debian.org/security/2022/dsa-5151
- security.gentoo.org/glsa/202209-09
- lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/L777JIBIWJV34HS7LXPIDWASG7TT4LNI/
- lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/BRAJVDRGCIY5UZ2PQHKDTT7RMKG6WJQQ/
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| smarty smarty | v < 3.1.45, 4.0.0 ≤ v < 4.1.1 | 3.1.45, 4.1.1 |
| debian debian_linux | 9.0, 10.0, 11.0 | — |
| fedoraproject fedora | 36, 37 | — |
| smarty/smartyPackagist | v < 3.1.45, 4.0.0 ≤ v < 4.1.1 | 3.1.45, 4.1.1 |
Check your version
Choose the product and enter the version you run to see whether it falls in the affected range.
Attack Surface Management
See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.