Skip to content

grav

v2.0.4 Security

This release includes 2 security fixes for security teams reviewing exposed deployments.

Published 27d Documentation
✓ No known CVEs patched
Read the diff → Tool health → What is this tool? →
This release patches 2 known CVEs

Topics

cms content content-management doctrine flat-file grav
+9 more
markdown php php7 symfony twig website website-builder website-generation yaml

Affected surfaces

auth breaking_upgrade

Summary

AI summary

Updates Bugfix, New, and https://github.com/getgrav/grav/security/advisories/GHSA-vwg3-w8w3-pc79 across a mixed release.

Full changelog

New

  • Plugins can now register trusted iframe hosts so legitimate provider embeds (such as YouTube) are no longer blanked by the content XSS scan on hardened sites.
  • Added an onXssTrustedMarkup event that lets a plugin exempt its own rendered markup from the content XSS scan without weakening it for editor-authored content.

Bugfix

  • [security] Grav's .htaccess rules blocking sensitive folders and files are now matched case-insensitively, closing a bypass where, on case-insensitive filesystems (Windows, macOS, some Docker mounts), a differently-cased request could reach files such as account and config YAML; existing sites are healed on upgrade (GHSA-vwg3-w8w3-pc79).
  • [security] The user/data folder now ships a media-aware allowlist that serves uploaded assets such as images, fonts, CSS and JS while keeping data files like YAML and JSON blocked, and upgrading widens an over-narrow allowlist from earlier security updates in place so legitimate theme assets stop returning 403. Fixes #4169.
  • [security] The Twig regex_replace filter now returns its input unchanged instead of null when a pattern hits a PCRE error such as a backtrack-limit, so a catastrophic pattern can no longer break output (GHSA-37f3-6p89-6qr9).
  • bin/gpm self-upgrade no longer fails on shared-folder setups such as a VirtualBox shared folder, where the bin directory holding the running script could not be deleted, by overwriting the upgrade files in place instead. Fixes #4171.
  • Debug messages logged during API requests now reach the Admin2 API debug panel and Clockwork even when the debugger is set to PHP DebugBar. Fixes grav-plugin-admin2#76.
  • Resizing an image larger than its original size with ?resize= no longer pads it onto an oversized canvas with a white border, returning the image at its natural size instead unless ?forceresize is used. Fixes #4173.
  • Turning off the Twig sandbox no longer breaks pages or modules that contain a form, which previously failed with a "SandboxExtension extension is not enabled" error. Fixes #4175.
  • A blueprint validation error now names the value it rejected, so a message like "Invalid input in Process" explains what actually caused it. Relates to #4178.
  • Adding a blocked item to the Twig sandbox allowlist from the Tools report now clears that block from the recent-blocks list. Fixes grav-plugin-admin2#85.

Security Fixes

  • GHSA-vwg3-w8w3-pc79 – .htaccess rules now match case‑insensitively, closing bypass on case‑insensitive filesystems
  • GHSA-37f3-6p89-6qr9 – Twig `regex_replace` filter returns input unchanged instead of null when PCRE errors occur

Weekly OSS security release digest.

The CVE patches and breaking changes that affected production tools this week. One email, every Sunday.

No spam, unsubscribe anytime.

Share this release

Track grav

Get notified when new releases ship.

Sign up free

About grav

Modern, Crazy Fast, Ridiculously Easy and Amazingly Powerful Flat-File CMS powered by PHP, Markdown, Twig, and Symfony

All releases →

Related context

Beta — feedback welcome: [email protected]