GitHub Advisoryadvisory · Packagist
GHSA-3rpf-5rqv-689q PHP Code Injection by malicious function name in smarty
CRITICAL
Official page ↗
- Aliases
- CVE-2021-26120
- Ecosystem
- Packagist
- Packages
- smarty/smarty
- Severity
- Critical
- CVSS vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Weaknesses
- CWE-94
- Reviewed
- 2021-02-26
Affected packages
• Packagist smarty/smarty: < 3.1.39 → fixed in 3.1.39
Description
Template authors could inject php code by choosing a malicous {function} name. Sites that cannot fully trust template authors should update as soon as possible. Please upgrade to 3.1.39 or higher.
Related
Alias · CVE (1)
- CVE-2021-26120 Smarty before 3.1.39 allows code injection via an unexpected function name after a {function name= substring. vulnerability
Weakness · CWE (1)
- CWE-94 Improper Control of Generation of Code weakness
References
- https://github.com/smarty-php/smarty/security/advisories/GHSA-3rpf-5rqv-689q web
- https://nvd.nist.gov/vuln/detail/CVE-2021-26120 advisory
- https://github.com/smarty-php/smarty/commit/165f1bd4d2eec328cfeaca517a725b46001de838 web
- https://github.com/FriendsOfPHP/security-advisories/blob/master/smarty/smarty/CVE-2021-26120.yaml web
- https://github.com/smarty-php/smarty package
- https://github.com/smarty-php/smarty/blob/master/CHANGELOG.md web
- https://github.com/smarty-php/smarty/blob/master/CHANGELOG.md#3139---2021-02-17 web
- https://lists.debian.org/debian-lts-announce/2021/04/msg00004.html web
- https://lists.debian.org/debian-lts-announce/2021/04/msg00014.html web
- https://security.gentoo.org/glsa/202105-06 web
- https://srcincite.io/blog/2021/02/18/smarty-template-engine-multiple-sandbox-escape-vulnerabilities.html web
- https://www.debian.org/security/2022/dsa-5151 web