CVE-2026-62992: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in smarty-php smarty
CVE-2026-62992 is a path traversal vulnerability in the Smarty PHP template engine. Versions prior to 5.8.2 and 4.5.7 do not fully resolve symbolic links before validating directory paths, allowing an attacker with write access to a trusted directory to bypass containment checks and read arbitrary files accessible to the PHP process. This issue is fixed in Smarty versions 5.8.2 and 4.5.7.
AI Analysis
Technical Summary
Smarty versions before 5.8.2 and 4.5.7 contain a path traversal vulnerability (CWE-22, CWE-61) in the Security::_checkDir() function. The function fails to fully resolve symbolic links before verifying that a requested path is within a configured secure directory. An attacker able to place or reference a symbolic link inside a directory Smarty treats as trusted (such as template or config directories) can exploit this to access files outside the intended directory, potentially reading arbitrary files accessible to the PHP process. The vulnerability is addressed by fully resolving symbolic links in the affected function in versions 5.8.2 and 4.5.7.
Potential Impact
An attacker with the ability to place or reference symbolic links in trusted Smarty directories can bypass directory containment checks and read arbitrary files accessible to the PHP process. This could lead to unauthorized disclosure of sensitive information. The CVSS 4.0 score is 6.9 (medium severity), reflecting network attack vector, low attack complexity, no user interaction, and high impact on confidentiality.
Mitigation Recommendations
Upgrade Smarty to version 5.8.2 or later, or 4.5.7 or later on the 4.x line, where the vulnerability is fixed by fully resolving symbolic links before directory validation. No other mitigations are indicated by the vendor advisory. Patch status is confirmed fixed in these versions.
CVE-2026-62992: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in smarty-php smarty
Description
CVE-2026-62992 is a path traversal vulnerability in the Smarty PHP template engine. Versions prior to 5.8.2 and 4.5.7 do not fully resolve symbolic links before validating directory paths, allowing an attacker with write access to a trusted directory to bypass containment checks and read arbitrary files accessible to the PHP process. This issue is fixed in Smarty versions 5.8.2 and 4.5.7.
CVSS v4.0
Score 6.9medium
Affected software
smarty-php
smarty
pkg:composer/smarty-php/smartyRun on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
Smarty versions before 5.8.2 and 4.5.7 contain a path traversal vulnerability (CWE-22, CWE-61) in the Security::_checkDir() function. The function fails to fully resolve symbolic links before verifying that a requested path is within a configured secure directory. An attacker able to place or reference a symbolic link inside a directory Smarty treats as trusted (such as template or config directories) can exploit this to access files outside the intended directory, potentially reading arbitrary files accessible to the PHP process. The vulnerability is addressed by fully resolving symbolic links in the affected function in versions 5.8.2 and 4.5.7.
Potential Impact
An attacker with the ability to place or reference symbolic links in trusted Smarty directories can bypass directory containment checks and read arbitrary files accessible to the PHP process. This could lead to unauthorized disclosure of sensitive information. The CVSS 4.0 score is 6.9 (medium severity), reflecting network attack vector, low attack complexity, no user interaction, and high impact on confidentiality.
Mitigation Recommendations
Upgrade Smarty to version 5.8.2 or later, or 4.5.7 or later on the 4.x line, where the vulnerability is fixed by fully resolving symbolic links before directory validation. No other mitigations are indicated by the vendor advisory. Patch status is confirmed fixed in these versions.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-07-14T23:10:57.031Z
- Cvss Version
- 4.0
- State
- PUBLISHED
Threat ID: 6a75f942bf8831d53989abbc
Added to database: 08/07/2026, 15:26:58 UTC
Last enriched: 08/14/2026, 16:11:57 UTC
Last updated: 09/21/2026, 22:01:36 UTC
Views: 60
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.