---
cve: "CVE-2021-29454"
severity: "HIGH"
cvss: 8.1
epss: "1.9%"
vendor: "smarty-php"
kev: false
exploited: false
published: "2022-01-10 20:15:08"
tags: [cve, security, high]
source: tsecurity.de CVE-Dossier
exported: "2026-09-11T03:48:16+02:00"
---

# CVE-2021-29454

> 8.1 HIGH · 🧪 PoC

## Beschreibung

Smarty is a template engine for PHP, facilitating the separation of presentation (HTML/CSS) from application logic. Prior to versions 3.1.42 and 4.0.2, template authors could run arbitrary PHP code by crafting a malicious math string. If a math string was passed through as user provided data to the math function, external users could run arbitrary PHP code by crafting a malicious math string. Users should upgrade to version 3.1.42 or 4.0.2 to receive a patch.

## CVSS-Vektor

```
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N
```

| Metrik | Wert | Bewertung |
|---|---|---|
| AV Angriffsvektor | Netzwerk | bad |
| AC Komplexität | Gering | bad |
| PR Privilegien | Keine | bad |
| UI Interaktion | Erforderlich | good |
| S Scope | Unverändert | good |
| C Vertraulichkeit | Hoch | bad |
| I Integrität | Hoch | bad |
| A Verfügbarkeit | Keine | good |

## Patch verfügbar (OSV)

- b674cba13d4ae61f063aec20f84a3ec40c006124 (Commit)
- 6f4f06db7ebbad6ae7bc98027d9385e60a016906 (Commit)

## Referenzen

- <https://github.com/smarty-php/smarty/security/advisories/GHSA-29gp-2c3m-3j6m>
- <https://github.com/smarty-php/smarty/commit/215d81a9fa3cd63d82fb3ab56ecaf97cf1e7db71>
- <https://github.com/smarty-php/smarty/releases/tag/v3.1.42>
- <https://github.com/smarty-php/smarty/releases/tag/v4.0.2>
- <https://packagist.org/packages/smarty/smarty>
- <https://www.smarty.net/docs/en/language.function.math.tpl>
- <https://lists.debian.org/debian-lts-announce/2022/05/msg00005.html>
- <https://www.debian.org/security/2022/dsa-5151>
- <https://security.gentoo.org/glsa/202209-09>
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/L777JIBIWJV34HS7LXPIDWASG7TT4LNI/>
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/BRAJVDRGCIY5UZ2PQHKDTT7RMKG6WJQQ/>

---
_Exportiert aus dem [tsecurity.de CVE-Dossier](https://tsecurity.de/cve?cve=CVE-2021-29454) · Datenquellen: EUVD (ENISA), NVD, OSV, CISA KEV, FIRST EPSS, Exploit-DB, BSI BITS_
