NIST deprecates RSA-2048 from 2030. Find every one of them before attackers do.
🐘
🐘 Packagist
Not in CISA KEV
HIGH severity

CVE-2024-45411 — twig

HIGHFix: twigphp/Twig@11f68e2

CVE-2024-45411 is a high-severity (CVSS 8.5) CWE-693 vulnerability in twig/twig. A fix is available for twig/twig — see the affected versions and patch details below.

Twig has a possible sandbox bypass

Also known asGHSA-6j75-5wfj-gh66
Published
Updated
Affected
4 pkgs
Patched
4 / 4
Exploits
None indexed
Exploitation data as of Nov 10, 2026 · OSV.dev, NVD, FIRST.org (EPSS)

Exploitation Status

No confirmed exploitation observed yet

  • A successful exploit gives an attacker total control of the affected component, not partial access.
  • CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.

Exploitation and automatability from CISA’s SSVC triage for CVE-2024-45411.

EPSS Exploitation Probability

via FIRST.org ↗
0.8%probability of exploitation in next 30 days
Lower Risk0.00%
Lower risk than most CVEs58th percentile — riskier than 58% of all scored CVEsHighest risk
0.00%0.45%0.90%1.35%0.1%0.8%May 26Sep 26Nov 26

Probability of exploitation in the next 30 days, from FIRST.org EPSS.

How urgent is this, really

Where this sits among everything scored

Real-World Exposure

4 pkgs affected
🐘twig/twig🐘twig/twig🐘twig/twig🐘twig/twig

Real-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.

Description

Description

Under some circumstances, the sandbox security checks are not run which allows user-contributed templates to bypass the sandbox restrictions.

The security issue happens when all these conditions are met:

  • The sandbox is disabled globally;
  • The sandbox is enabled via a sandboxed include() function which references a template name (like included.twig) and not a Template or TemplateWrapper instance;
  • The included template has been loaded before the include() call but in a non-sandbox context (possible as the sandbox has been globally disabled).

Resolution

The patch ensures that the sandbox security checks are always run at runtime.

Credits

We would like to thank Fabien Potencier for reporting and fixing the issue.

Affected Packages

4 total 4 fixed
EcosystemPackageVulnerable rangeFix
🐘Packagisttwig/twig≥ 1.0.0&&< 1.44.81.44.8composer require twig/twig:^1.44.8
🐘Packagisttwig/twig≥ 2.0.0&&< 2.16.12.16.1composer require twig/twig:^2.16.1
🐘Packagisttwig/twig≥ 3.12.0&&< 3.14.03.14.0composer require twig/twig:^3.14.0
🐘Packagisttwig/twig≥ 3.0.0&&< 3.11.13.11.1composer require twig/twig:^3.11.1

Affected Products

1 product · 3 configurations
Application
twigsymfony
≥ 3.0.0 && < 3.14.0
range

Detection & mitigation playbook

Open-source dependency
  1. Detect

    Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for twig/twig, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.

  2. Fix

    Update twig/twig to 1.44.8 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2024-45411 is resolved across your whole dependency graph.

  3. Workarounds

    If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.

Fixing This On Your OS

If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.

Frequently Asked Questions

### Description Under some circumstances, the sandbox security checks are not run which allows user-contributed templates to bypass the sandbox restrictions. The security issue happens when all these conditions are met: * The sandbox is disabled globally; * The sandbox is enabled via a sandboxed `include()` function which references a template name (like `included.twig`) and not a `Template` or `TemplateWrapper` instance; * The included template has been loaded before the `include()` call but in a non-sandbox context (possible as the sandbox has been globally disabled). ### Resolution
O3 Security · Impact-Aware SCA

Is CVE-2024-45411 in your dependencies?

Find it across Packagist, including transitive dependencies.

CVE-2024-45411: twig — Fixed in 1.44.8