CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-75831

CVE-2026-75831: Stored Cross-Site Scripting in Grav CMS Audio/Video Media Rendering

Amit Schendel
Amit Schendel
Senior Security Researcher

Sep 17, 2026·6 min read·6 visits

Executive Summary (TL;DR)

A stored Cross-Site Scripting vulnerability in Grav CMS versions prior to 2.0.15 allows authenticated editors to insert arbitrary JavaScript via malicious audio/video file paths, which executes in the context of any user (including administrators) viewing the page.

Improper neutralization of input during web page generation in Grav CMS allows authenticated users with page modification privileges to execute stored Cross-Site Scripting (XSS) attacks. The flaw exists in AudioMediaTrait and VideoMediaTrait where media source URLs are concatenated directly into HTML templates without proper escaping.

Vulnerability Overview

The Stored Cross-Site Scripting (XSS) vulnerability, tracked as CVE-2026-75831 and GHSA-6qw9-4vv5-jr97, exists within the core media processing architecture of the Grav Content Management System (CMS). Grav utilizes a flat-file structure and processes Markdown elements through specialized traits that generate HTML structures. When handling audio and video file attachments, the system renders media elements via the Parsedown engine by invoking specific trait methods.

Specifically, the AudioMediaTrait and VideoMediaTrait components are responsible for transforming media markup into standard HTML <audio> and <video> tags. During this process, the system dynamically generates <source> elements using media path variables. If an authenticated user with page editing privileges submits a crafted path containing specific characters, those characters bypass standard encoding pipelines.

This vulnerability allows an attacker to insert arbitrary HTML and JavaScript directly into the rendered output of the page. Consequently, any subsequent user who accesses the compromised page will execute the injected script within their browser context. The vulnerability is classified under CWE-79 (Improper Neutralization of Input During Web Page Generation).

Root Cause Analysis

The primary defect resides in the implementation of the sourceParsedownElement method within both AudioMediaTrait and VideoMediaTrait. In vulnerable versions of Grav (prior to 2.0.15), this method constructs the HTML representing the media source by concatenating the unescaped path variable, $location, directly into a raw HTML template string.

While traditional image elements process source parameters through an attribute-escaping pipeline that filters special characters, the audio and video subsystems construct a hardcoded <source src="..."> string inside a rawHtml array key. This bypassed the standard security wrappers of the Parsedown engine. When a content editor uploads or links a media file, any query parameters or URL fragment structures appended to the filename are captured in the $location variable.

Although the core Grav architecture contains filtering logic to strip leading hash symbols (#) from parameters via the urlHash helper, it does not neutralize quotes, angle brackets, or script structures within the body of the URL fragment itself. This allows an attacker to craft a media reference where the fragment contains double quotes to break out of the HTML attribute value boundary.

Code Analysis

A comparison of the vulnerable codebase and the patched implementation demonstrates how the unescaped path variable was processed. In vulnerable releases, the code directly concatenated the path variable into the HTML string.

// Vulnerable implementation in AudioMediaTrait.php
protected function sourceParsedownElement(array $attributes, $reset = true)
{
    // ...
    return [
        'name' => 'audio',
        'rawHtml' => '<source src="' . $location . '">Your browser does not support the audio tag.',
        'attributes' => $attributes
    ];
}

The fix, introduced in Grav version 2.0.15, wraps the $location variable in PHP's standard htmlspecialchars function with the ENT_QUOTES configuration flag. This ensures that any double or single quotes, as well as angle brackets, are fully encoded to their respective HTML entities before rendering.

// Patched implementation in AudioMediaTrait.php
protected function sourceParsedownElement(array $attributes, $reset = true)
{
    // ...
    return [
        'name' => 'audio',
        'rawHtml' => '<source src="' . htmlspecialchars($location, ENT_QUOTES, 'UTF-8') . '">Your browser does not support the audio tag.',
        'attributes' => $attributes
    ];
}

Because the browser parser treats encoded entity characters as literal strings rather than executable syntactic elements, the execution boundary remains intact. An attacker's attempt to break out of the src attribute is rendered inert.

Exploitation Methodology

Exploitation requires an attacker to possess privileges that allow the creation or modification of Markdown pages within the Grav CMS. Such roles typically include Authors, Editors, or Contributors. The attacker initiates the exploit by embedding a media attachment containing a malformed filename fragment.

The payload relies on appending a double-quote character, a closing angle bracket, and a scripting payload to the media URL. For example, inserting a payload like video.mp4#"><script>alert(document.cookie)</script> breaks the structural syntax of the <source> tag.

When the system renders this Markdown page, the output converts into the following HTML structure: <source src="video.mp4#"><script>alert(document.cookie)</script>">. The browser parses the script block as an independent DOM node and executes it immediately under the security origin of the hosting domain.

Impact Assessment

The impact of CVE-2026-75831 is significant due to the stored nature of the script. Once an administrative user views the page, the injected JavaScript executes with the permissions of that administrator's active session. This can lead to complete session hijacking, cookie theft, or administrative actions performed silently in the background.

Because Grav uses administrative tokens and REST APIs to manage user accounts and system configuration, the malicious script can trigger requests that create new super-administrator accounts or execute file upload commands. Such actions can result in arbitrary code execution on the server hosting the CMS.

The vulnerability is assigned a CVSS v3.1 score of 7.6, indicating high severity due to the potential for scope change and high confidentiality impact. The EPSS score indicates a low initial probability of active exploitation in the wild, but administrators should treat any instance of stored script injection as critical.

Remediation & Defenses

The primary remediation strategy is upgrading the Grav CMS core installation to version 2.0.15 or newer. This version implements comprehensive attribute escaping on all audio and video media rendering pathways.

For environments where immediate system upgrades are impractical, administrators should implement a Content Security Policy (CSP) header that restricts script execution. Specifically, enforcing a policy that forbids inline scripts or requires unique cryptographic nonces prevents the injected payload from running even if the HTML structure is compromised.

Additionally, security teams can audit the existing Markdown pages by querying the file system for media extensions followed by suspicious HTML characters. Running a system-wide search inside the user/pages/ directory using regular expressions assists in locating pre-existing malicious payloads.

Official Patches

getgravOfficial patch fixing rawHtml source URL escaping

Fix Analysis (1)

Technical Appendix

CVSS Score
7.6/ 10
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:L/A:N
EPSS Probability
0.31%
Top 76% most exploited

Affected Systems

Grav CMS

Affected Versions Detail

Product
Affected Versions
Fixed Version
Grav
getgrav
< 2.0.152.0.15
AttributeDetail
CWE IDCWE-79
Attack VectorNetwork (AV:N)
CVSS v3.1 Score7.6 (High)
EPSS Score0.00313 (0.31%)
ImpactStored Cross-Site Scripting (XSS)
Exploit StatusProof-of-Concept
KEV StatusNot Listed

MITRE ATT&CK Mapping

T1189Drive-by Compromise
Initial Access
T1185Browser Session Hijacking
Collection
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

The product does not neutralize or incorrectly neutralizes user-controlled input before it is placed in output that is used as a web page that is served to other users.

Known Exploits & Detection

GitHub Security AdvisoryDescription of the stored XSS vulnerability and remediation details

Vulnerability Timeline

Vulnerability reported to the Grav development team
2026-07-30
Developer Andy Miller commits the fix
2026-07-31
Grav version 2.0.15 is officially released
2026-08-03
CVE-2026-75831 is published by VulnCheck and populated into NVD
2026-08-18

References & Sources

  • [1]GHSA-6qw9-4vv5-jr97: Stored XSS in Grav CMS Audio/Video Media Rendering
  • [2]Grav Fix Commit
  • [3]VulnCheck Advisory for CVE-2026-75831
  • [4]NVD - CVE-2026-75831

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•1 minute ago•CVE-2026-72819
8.8

CVE-2026-72819: Remote Code Execution in Grav CMS via Dynamic Callable Validation Bypass in Blueprint

CVE-2026-72819 is a high-severity Remote Code Execution (RCE) vulnerability in Grav CMS before version 2.0.13. The vulnerability lies in the validation of dynamic data providers (callbacks) within the Flex Objects plugin settings and blueprints, allowing administrative users to bypass validation checks via array-notation callables. This validation failure enables administrative users to execute arbitrary PHP classes and methods, including the GPM Installer unZip routine, leading to full remote code execution on the server.

Amit Schendel
Amit Schendel
0 views•9 min read
•about 1 hour ago•CVE-2026-75523
5.9

CVE-2026-75523: Exposure of Sensitive Query Parameter Secrets in Steeltoe Actuator Endpoints

Steeltoe, a popular framework for building cloud-native .NET applications, contains a critical data-exposure flaw in its HttpExchanges actuator endpoint before version 4.3.0. When explicitly configured to include query strings, the system records and stores sensitive values (such as OAuth tokens and credentials) in memory and application debug logs without sanitization, exposing them to unauthorized network actors.

Alon Barad
Alon Barad
2 views•5 min read
•about 2 hours ago•CVE-2026-86039
8.2

CVE-2026-86039: Signature Verification Bypass and Address Book Poisoning in @libp2p/peer-store

A logic verification vulnerability in `@libp2p/peer-store` (part of the `js-libp2p` ecosystem) allows unauthenticated remote attackers to bypass identity verification and poison a victim node's peer store database with arbitrary network multiaddresses. This occurs because `consumePeerRecord()` fails to ensure that the signature's identity matches the inner record payload's identity.

Alon Barad
Alon Barad
3 views•9 min read
•about 4 hours ago•CVE-2026-86071
3.7

CVE-2026-86071: Path Traversal Vulnerability in Junrar Archive Library

A directory traversal vulnerability exists in the Junrar archive extraction library prior to version 7.6.1. When extracting crafted RAR archives, the library allows unauthorized directory creation outside the designated destination root due to improper path normalization during directory creation.

Alon Barad
Alon Barad
8 views•8 min read
•about 5 hours ago•CVE-2026-63506
8.8

CVE-2026-63506: Broken Access Control in TinaCMS isAuthorized Authentication Handler

CVE-2026-63506 is a critical authorization bypass vulnerability in TinaCMS self-hosted backend authentication packages (@tinacms/auth and next-tinacms-azure). By exploiting a request-controlled clientID parameter, unauthenticated attackers with an active token for any developer-registered TinaCloud application can bypass tenant boundaries and execute unauthorized administrative operations, including full GraphQL database interactions and arbitrary media management.

Amit Schendel
Amit Schendel
6 views•7 min read
•about 6 hours ago•CVE-2026-85078
6.5

CVE-2026-85078: HTTP Request Smuggling via Chunked Trailers in Sanic Core HTTP Parser

CVE-2026-85078 describes a critical request-boundary integrity vulnerability (HTTP Request Smuggling) in Sanic, an open-source high-performance Python web server and framework. The vulnerability exists within Sanic's core HTTP/1.1 chunked-body parser. Prior to the patched versions, when processing a chunked transfer-encoded request, Sanic's parser failed to fully consume or validate the trailer-part following the terminating zero-size chunk.

Amit Schendel
Amit Schendel
6 views•6 min read