Skip to content
DayZeroHub
Medium Not yet writtenCVSS 5.3CVE-2026-133768

CVE-2026-133768: Sandbox property allow-list bypass via the `join` filter on non-iterable objects

Twig twig/twig

Preliminary notice: published right away from the original source data, without editorial write-up. It will shortly be replaced by a written and reviewed version.

Summary

CVE-2026-133768: medium-severity vulnerability (CVSS 5.3) in Twig twig/twig.

What happened

Original description from the source: The join filter converted a value that isn't iterable with (array) $value. For an object, that gives every property, including the private and protected ones. A sandboxed template allowed to use join could therefore print properties that the policy denies, and that templates can't read otherwise: {{ user|join(',') }} A value that isn't iterable is now joined as a single item. A Stringable object prints its checked string, and other objects throw, as with the first and last filters.

Why it matters

Medium severity, CVSS 5.3.

Affected products and versions

Twig twig/twig < 3.31.1

ProductVersionsFixed in
Twig twig/twig< 3.31.1—

Action recommended by the source

See the official references for the fix or mitigation.

Information taken from the source or the vendor. Verify it at the original link before acting.

Sources and references

Weaknesses (CWE): CWE-863

Relevant change history

  1. Published

    Preliminary advisory published.