CVE-2021-29440: Twig allowing dangerous PHP functions by default

Published Apr 13, 2021
·
Updated

Grav is a file based Web-platform. Twig processing of static pages can be enabled in the front matter by any administrative user allowed to create or edit pages. As the Twig processor runs unsandboxed, this behavior can be used to gain arbitrary code execution and elevate privileges on the instance. The issue was addressed in version 1.7.11.

Affected Software

1 affected component
getgrav Grav<1.7.11

Event History

Apr 13, 2021
CVE Published
via MITRE·07:55 PM
Data Sourced
via MITRE·07:55 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

What is CVE-2021-29440?

CVE-2021-29440 is a vulnerability in the Grav CMS that allows arbitrary code execution and privilege escalation.

2

What is the severity of CVE-2021-29440?

CVE-2021-29440 has a severity rating of high, with a score of 7.2.

3

How can CVE-2021-29440 be exploited?

CVE-2021-29440 can be exploited by enabling Twig processing of static pages in the front matter, which allows an administrative user to execute arbitrary code and elevate privileges.

4

Which versions of Grav are affected by CVE-2021-29440?

Grav versions up to and excluding 1.7.11 are affected by CVE-2021-29440.

5

Is there a fix for CVE-2021-29440?

Yes, upgrading to Grav version 1.7.11 or newer is the recommended fix for CVE-2021-29440.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203