CVE-2018-13982Smarty
High 7.5 No auth needed
Follow: this CVE · Smarty · Smarty We alert you by email or Slack (account required).
- Priority
- 60
- CVSS 3.1
- 7.5
- EPSS
- 3.5% probability of exploitation in 30 days · percentile 90
- Auth required
- No
- Published
- Sep 18, 2018
- Updated
- Jun 17, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-22
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
What happens
Smarty_Security::isTrustedResourceDir() in Smarty before 3.1.33 is prone to a path traversal vulnerability due to insufficient template code sanitization. This allows attackers controlling the executed template code to bypass the trusted directory security restriction and read arbitrary files.
What to do
- Apply the vendor's security update for Smarty.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| Packagist | smarty/smarty |
< 3.1.33 |
3.1.33 |
composer require "smarty/smarty:^3.1.33" |
Per OSV / GitHub Advisories (GHSA-7gfx-wxfh-7rvm). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| smarty | smarty | < 3.1.33 |
| debian | debian_linux | 9.0 |
Official sources
References
Links published by the sources. Open them with care.
- github.com Exploit Patch Third Party Advisory
- github.com Patch Vendor Advisory
- github.com Patch Vendor Advisory
- github.com Patch Vendor Advisory
- github.com Patch Vendor Advisory
- github.com Patch Vendor Advisory
- lists.debian.org Mailing List Third Party Advisory
- lists.debian.org Mailing List Third Party Advisory
- lists.debian.org Mailing List Third Party Advisory