UNIX Symbolic Link (Symlink) Following Affecting smarty/smarty package, versions <4.5.7>=5.0.0, <5.8.2


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.36% (30th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about UNIX Symbolic Link (Symlink) Following vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PHP-SMARTYSMARTY-18689644
  • published12 Aug 2026
  • disclosed7 Aug 2026
  • creditUnknown

Introduced: 7 Aug 2026

NewCVE-2026-62992  (opens in a new tab)
CWE-22  (opens in a new tab)
CWE-61  (opens in a new tab)

How to fix?

Upgrade smarty/smarty to version 4.5.7, 5.8.2 or higher.

Overview

Affected versions of this package are vulnerable to UNIX Symbolic Link (Symlink) Following via the Security::_checkDir process. An attacker can access arbitrary files outside of trusted directories by creating a symbolic link within a trusted directory and causing a template to reference that path. This is only exploitable if an attacker can create a symlink inside a trusted directory and influence template references.

Workaround

This vulnerability can be mitigated by ensuring no untrusted symlinks can be created within any directory listed in secure_dir or the trusted template directories, and by restricting write access to those directories to trusted processes only.

CVSS Base Scores

version 4.0
version 3.1