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

- Severity: Medium 5.1 (CVSS:4.0, scored by VulnCheck) `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`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.26%, higher than 18% of CVEs (2026-12-01)
- Published: 2026-08-21T19:14:59.000Z
- Modified: 2026-10-08T16:17:55.950Z
- Also known as: GHSA-8hgv-xc77-jmcr
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: VulnCheck

## 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.

(As written by CVE List.)

## Affected

- getgrav grav: before 2.0.20 (not affected: 2.0.20)
- getgrav/grav (Packagist): before 2.0.20

## Every score

- VulnCheck: CVSS:4.0 5.1 Medium `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`
- GitHub: CVSS:4.0 Medium `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

- <https://github.com/getgrav/grav/security/advisories/GHSA-8hgv-xc77-jmcr> (vendor-advisory, web)
- <https://www.vulncheck.com/advisories/grav-before-2.0.20-cross-site-scripting-via-assets-sandbox> (third-party-advisory)
- <https://github.com/getgrav/grav/commit/a4e8c4b748eb338ee7ab1dd26e7620a93bade047> (web)
- <https://github.com/getgrav/grav> (package)
- <https://github.com/getgrav/grav/releases/tag/2.0.20> (web)

## Sources

- CVE List: [CVE-2026-86197](https://www.cve.org/CVERecord?id=CVE-2026-86197), CVE Terms of Use, modified 2026-10-08
- GitHub Advisory Database: [GHSA-8hgv-xc77-jmcr](https://github.com/advisories/GHSA-8hgv-xc77-jmcr), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2026-86197](https://nvd.nist.gov/vuln/detail/CVE-2026-86197), Public domain, modified 2026-10-08

---

Page: https://cve.day/CVE-2026-86197 · Whole record: https://cve.day/CVE-2026-86197.json · Rebuilt by cve.day 2026-11-25T22:59:36.451Z
