Twig versions 2.16.x and 3.9.0 through 3.25.x contain a sandbox bypass vulnerability when using a SourcePolicyInterface that allows attackers with template rendering capabilities to pass arbitrary PHP callables to sort, filter, map, and reduce filters. Attackers can exploit the runtime check that fails to use the current template source to bypass sandbox restrictions and execute arbitrary code when the sandbox is enabled through a source policy rather than globally.
Twig template engine versions 2.16.x and 3.9.0-3.25.x contain a sandbox bypass vulnerability allowing attackers to execute arbitrary PHP code through template filters when using SourcePolicyInterface. Organizations using Twig for template rendering with sandbox protection are at risk of code execution attacks.
تحتوي نسخ محرك قوالب Twig على ثغرة تسمح للمهاجمين بتجاوز قيود الحماية الرملية عند استخدام واجهة سياسة المصدر. يمكن للمهاجمين الذين لديهم إمكانية عرض القوالب تمرير دوال PHP عشوائية إلى مرشحات الفرز والتصفية والخريطة والتقليل. الفحص في وقت التشغيل يفشل في استخدام مصدر القالب الحالي مما يسمح بتنفيذ أكواد عشوائية.
محرك قوالب Twig الإصدارات 2.16.x و3.9.0-3.25.x يحتوي على ثغرة تجاوز الحماية الرملية تسمح للمهاجمين بتنفيذ كود PHP عشوائي عبر مرشحات القوالب. المنظمات التي تستخدم Twig لعرض القوالب مع حماية الحماية الرملية معرضة لهجمات تنفيذ الأكواد.
Update Twig to version 2.17.0 or later for 2.16.x branch, or 3.26.0 or later for 3.9.0+ branch. Implement strict input validation for template sources and disable dynamic template rendering from untrusted sources. Review and restrict template filter usage in production environments.
قم بتحديث Twig إلى الإصدار 2.17.0 أو أحدث للفرع 2.16.x، أو 3.26.0 أو أحدث للفرع 3.9.0+. قم بتطبيق التحقق الصارم من صحة مصادر القوالب وتعطيل عرض القوالب الديناميكية من مصادر غير موثوقة. راجع وقيد استخدام مرشحات القوالب في بيئات الإنتاج.