GHSA-29gp-2c3m-3j6m

    Dashboard / Vulnerabilities / GHSA-29gp-2c3m-3j6m

    GHSA-29gp-2c3m-3j6m

    Published: 12 Jan 2022Last Modified: 8 Jul 2026

    Summary: Sandbox Escape by math function in smarty

    Details: ### Impact Template authors could run arbitrary PHP code by crafting a malicious math string. If a math string is passed through as user provided data to the math function, external users could run arbitrary PHP code by crafting a malicious math string. ### Patches Please upgrade to 4.0.2 or 3.1.42 or higher. ### References See [documentation on Math function](https://www.smarty.net/docs/en/language.function.math.tpl). ### For more information If you have any questions or comments about this advisory please open an issue in [the Smarty repo](https://github.com/smarty-php/smarty)

    Affected packages

    Package

    Name: smarty/smarty

    Purl: pkg:composer/smarty/smarty

    Affected ranges

    Type: ECOSYSTEM

    Events:

    Introduced- 0
    Fixed -3.1.42

    Affected versions

    v2.6.24
    v2.6.25
    v2.6.26
    v2.6.27
    v2.6.28
    v2.6.29
    v2.6.30
    v2.6.31
    v2.6.33

    Common Vulnerability Scoring System

    Attack Vector
    Network
    Adjacent
    Local
    Physical
    Privileges Required
    None
    Low
    High
    User Interaction
    None
    Required
    Scope
    Unchanged
    Changed
    Confidentiality
    None
    Low
    High
    Integrity
    None
    Low
    High
    Availability
    None
    Low
    High
    GHSA-29gp-2c3m-3j6m | CVE-DB