CVE-2025-52902
mediumpriority · track · 22EPSS 0.003 · 26 %ileEUUSEPSS · scored 2026-10-27
File Browser provides a file managing interface within a specified directory and it can be used to upload, delete, preview, rename and edit files. The Markdown preview function of File Browser prior to v2.33.7 is vulnerable to Stored Cross-Site-Scripting (XSS). Any JavaScript code that is part of a Markdown file uploaded by a user will be executed by the browser. Version 2.33.7 contains a fix for the issue.
cvss
Technical severity, 0–10. One row per scoring source.
base score 0–10 · higher = more severe · hover a vector to decode⚠ sources disagree · medium–high · 5–7.6
ssvc
A stakeholder decision — act, attend, or track — from exploitation and impact.
weaknesses
The CWE weakness classes this flaw belongs to.
affected products (5)
Products and version ranges known to be affected.
- Go github.com/filebrowser/filebrowser/v2< 2.33.7osvUSpkg:golang/github.com/filebrowser/filebrowser/v2
advisories (2)
Vendor and ecosystem advisories describing this.
- GHSA-4wx8-5gm2-2j97filebrowser allows Stored Cross-Site Scripting through the Markdown preview function2025-06-27ghsa · osvUS
## Summary ## The Markdown preview function of File Browser v2.32.0 is vulnerable to *Stored Cross-Site-Scripting (XSS)*. Any JavaScript code that is part of a Markdown file uploaded by a user will be executed by the browser ## Impact ## A user can upload a malicious Markdown file to the application which can contain arbitrary HTML code. If another user within the same scope clicks on that file, a rendered preview is opened. JavaScript code that has been included will be executed. Malicious actions that are possible include: * Obtaining a user's session token * Elevating the attacker's privileges, if the victim is an administrator (e.g., gaining command execution rights) ## Vulnerability Description ## Most Markdown parsers accept arbitrary HTML in a document and try rendering it accordingly. For instance, if one creates a file called `xss.md` with the following content: ```markdown # Hallo <b>foo</b> <img src="xx" onerror=alert(9)> <i>bar</i> ``` Bold and italic text will be rendered. Also, the renderer used in File Browser will try to display the image and execute the code in the `onerror` event handler. ## Proof of Concept ## The screenshot shows that the code from the file mentioned above has actually been executed in the victim's browser:  ## Recommended Countermeasures ## The most thorough fix would be to reconfigure the application's Markdown parser to ignore all HTML elements and only render rich text which is part of the Markdown specification. If HTML rendering is considered to be a required feature, an HTML sanitizer like DOMPurify should be used, preferably in conjunction with a *Content Security Policy* (CSP). ## Timeline ## * `2025-03-25` Identified the vulnerability in version 2.32.0 * `2025-04-11` Contacted the project * `2025-04-18` Vulnerability disclosed to the project * `2025-06-25` Uploaded advisories to the project's GitHub repository * `2025-06-26` CVE ID assigned by GitHub * `2025-06-26` Fix released with version 2.33.7 ## References ## * [DOMPurify](https://github.com/cure53/DOMPurify) * [Original Advisory](https://github.com/sbaresearch/advisories/tree/public/2025/SBA-ADV-20250325-04_Filebrowser_Stored_XSS) ## Credits ## * Mathias Tausig ([SBA Research](https://www.sba-research.org/))
- GO-2025-3784filebrowser allows Stored Cross-Site Scripting through the Markdown preview function in github.com/filebrowser/filebrowser2025-07-28vendor · osvUS
filebrowser allows Stored Cross-Site Scripting through the Markdown preview function in github.com/filebrowser/filebrowser
also known as (5)
Other names and identifiers for this entity.
sources
Which sources assert this record, and when.
references (7)
External citations — patches, advisories, analysis.
- https://github.com/filebrowser/filebrowser/commit/f19943a42e8e092e811dffbe9f4623dac36f1f0dcnnvd
- https://github.com/filebrowser/filebrowser/releasesPatchcnnvd
- https://github.com/filebrowser/filebrowser/security/advisories/GHSA-4wx8-5gm2-2j97cnnvd
- https://github.com/filebrowser/filebrowser/commit/f19943a42e8e092e811dffbe9f4623dac36f1f0denisa_euvd
- https://github.com/filebrowser/filebrowser/security/advisories/GHSA-4wx8-5gm2-2j97enisa_euvd
- https://github.com/filebrowser/filebrowser/commit/f19943a42e8e092e811dffbe9f4623dac36f1f0dPatchnvd
- https://github.com/filebrowser/filebrowser/security/advisories/GHSA-4wx8-5gm2-2j97ExploitVendor Advisorynvd
Attackers weaponise vulnerabilities like this against internet-exposed services. See what is exposed on your perimeter with a free passive scan.
Free scan