Get a Demo

Let's Patch It!

Book a short call with one our specialists, we'll walk you through how Endor Patches work, and ask you a few questions about your environment (like your primary programming languages and repository management). We'll also send you an email right after you fill out the form, feel free to reply with any questions you have in advance!

CVE

CVE-2026-25890

File Browser has a Path-Based Access Control Bypass via Multiple Leading Slashes in URL
Back to all
CVE

CVE-2026-25890

File Browser has a Path-Based Access Control Bypass via Multiple Leading Slashes in URL

Summary

An authenticated user can bypass the application's "Disallow" file path rules by modifying the request URL. By adding multiple slashes (e.g., //private/) to the path, the authorization check fails to match the rule, while the underlying filesystem resolves the path correctly, granting unauthorized access to restricted files.

Details

The vulnerability allows users to bypass "Disallow" rules defined by administrators.

The issue stems from how the application handles URL path normalization and rule matching:

  1. Router Configuration: The router in http/http.go is configured with r.SkipClean(true). This prevents the automatic collapse of multiple slashes (e.g., // becoming /) before the request reaches the handler.
  2. Insecure Rule Matching: The rule enforcement logic in rules/rules.go relies on a simple string prefix match: strings.HasPrefix(path, r.Path). If a rule disallows /private, a request for //private fails this check because //private does not strictly start with /private.
  3. Filesystem Resolution: After bypassing the rule check, the non-normalized path is passed to the filesystem. The filesystem treats the multiple slashes as a single separator, successfully resolving //private/secret.txt and serving the file.

PoC

Python minimal PoC

The following steps demonstrate the vulnerability:

  1. Setup:
  • Admin user creates a folder /private and adds a file /private/secret.txt.

<img width="971" height="719" alt="Screenshot20260123151608" src="https://github.com/user-attachments/assets/2071c92e-2bbe-46f8-a338-05b0f53d381a" />

<img width="890" height="386" alt="Screenshot20260123151551" src="https://github.com/user-attachments/assets/1def540a-de26-4666-a6ab-058d5927bfbe" />

  • Admin adds a Disallow rule for user bob on the path /private.

<img width="1005" height="1126" alt="Screenshot20260123151502" src="https://github.com/user-attachments/assets/e9b57d59-f4ab-41d8-b056-8ffdaa219963" />

  1. Verification:
  • User bob requests GET /api/resources/private/secret.txt.
  • Server responds: 403 Forbidden.

<img width="1193" height="721" alt="Screenshot20260123154446" src="https://github.com/user-attachments/assets/dd092a10-2f8c-4a3c-b48f-d540c483bb5a" />

  1. Exploit:
  • User bob requests GET /api/resources//private/secret.txt.
  • Server responds: 200 OK (Bypass successful).

<img width="1193" height="721" alt="Screenshot20260123154544" src="https://github.com/user-attachments/assets/27ebb82c-f7c2-467d-ae82-f495ae3aa2d4" />

<img width="1196" height="818" alt="Screenshot20260123154618" src="https://github.com/user-attachments/assets/82035884-9a24-490d-b928-7bdd2dbe3193" />

Impact

This vulnerability impacts the confidentiality and integrity of data stored in filebrowser.

  • Confidentiality: Users can read files they are explicitly forbidden from accessing.
  • Integrity: If the user has general write permissions but is restricted from specific directories via rules, they can bypass these restrictions to rename, delete, or modify files.

Package Versions Affected

Package Version
patch Availability
No items found.

Automatically patch vulnerabilities without upgrading

Fix Without Upgrading
Detect compatible fix
Apply safe remediation
Fix with a single pull request

CVSS Version

Severity
Base Score
CVSS Version
Score Vector
C
H
U
8.1
-
3.1
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N
C
H
U
0
-
3.1
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N
C
H
U
-

Related Resources

No items found.

References

https://github.com/filebrowser/filebrowser/security/advisories/GHSA-4mh3-h929-w968, https://nvd.nist.gov/vuln/detail/CVE-2026-25890, https://github.com/filebrowser/filebrowser/commit/489af403a19057f6b6b4b1dc0e48cbb26a202ef9, https://github.com/filebrowser/filebrowser, https://github.com/filebrowser/filebrowser/releases/tag/v2.57.1

Severity

8.1

CVSS Score
0
10

Basic Information

Ecosystem
Base CVSS
8.1
EPSS Probability
0.00011%
EPSS Percentile
0.01336%
Introduced Version
0
Fix Available
2.57.1

Fix Critical Vulnerabilities Instantly

Secure your app without upgrading.
Fix Without Upgrading