CVE-2021-26119 json
Sandbox escape through template_object in smarty
published 2021-02-22 5 y ago modified 2026-06-17 4 mo ago also GHSA-w5hr-jm4j-9jvq , EUVD-2021-0717
- cvss
- 7.5
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 8.5%
- EPSS 8.5% chance of exploitation in 30 days, percentile 95%
- public exploits
- 0
- none known
Summary
Smarty before 3.1.39 allows a Sandbox Escape because $smarty.template_object can be accessed in sandbox mode.
Patch / fix
- packagist smarty/smarty 3.1.39
- smarty smarty 3.1.39
- smarty3 Debian 14, Debian 13, Debian 12 3.1.39-1
debian advisories DEBIAN-CVE-2021-26119
- smarty3 Ubuntu 18.04 LTS 3.1.31+20161214.1.c7d42e4+selfpack1-3ubuntu0.1
- smarty3 Ubuntu Pro 16.04 LTS 3.1.21-1ubuntu1+esm1
- smarty3 Ubuntu Pro 20.04 LTS 3.1.34+20190228.1.c9f0de05+selfpack1-1ubuntu0.1~esm1
ubuntu advisories UBUNTU-CVE-2021-26119
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- security.gentoo.org/glsa/202105-06 advisory
Exploit prediction
8.49% chance of exploitation in the next 30 days, higher than 95% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N |
| NVD | 2.0 | 5.0 | AV:N/AC:L/Au:N/C:N/I:P/A:N |
| GitHub | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| packagist | smarty/smarty | <3.1.39 |
3.1.39 |
References
-
security.gentoo.org
/glsa/202105-06
vendor-advisory, web, patch, third-party-advisory
-
debian.org
/security/2022/dsa-5151
vendor-advisory, web, third-party-advisory
-
github.com
/smarty-php/smarty/blob/master/CHANGELOG.md
web, release-notes, third-party-advisory
-
lists.debian.org
/debian-lts-announce/2021/04/msg00004.html
mailing-list, web, third-party-advisory
-
lists.debian.org
/debian-lts-announce/2021/04/msg00014.html
mailing-list, web, third-party-advisory
-
github.com
/smarty-php/smarty/security/advisories/GHSA-w5hr-jm4j-9jvq
web
-
nvd.nist.gov
/vuln/detail/CVE-2021-26119
advisory
-
github.com
/FriendsOfPHP/security-advisories/blob/master/smarty/smarty/CVE-2021-26119.yaml
web
-
github.com
/smarty-php/smarty
web
-
srcincite.io
/blog/2021/02/18/smarty-template-engine-multiple-sandbox-escape-vulnerabilities.html
web
Sources
- CVE List CVE-2021-26119
- GitHub Advisory GHSA-w5hr-jm4j-9jvq
- NVD CVE-2021-26119
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.