Vulnerability · Published Sep 5, 2026 · Assigned by VulnCheck

CVE-2026-86197Grav before 2.0.20 Cross-Site Scripting via Assets Sandbox

Medium 5.1

In plain English

A medium-severity cross-site scripting in grav from getgrav. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 36% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 4.0)5.1Medium
Exploit odds (30 days)0.4%top 64.4% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

Grav before 2.0.20 contains a cross-site scripting vulnerability in the Twig sandbox policy that allowlists addJs and addCss methods on Grav\Common\Assets without proper output escaping. Page editors can inject arbitrary script by registering malicious assets or injecting attributes, which are rendered unescaped into document head tags and executed for all visitors including administrators.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Packagistgetgrav/grav2.0.20GHSA-8hgv-xc77-jmcr

Affected products (as reported)

VendorProductVersions
getgrav grav 0 – before 2.0.20

Weakness: CWE-79 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

References