highCVSS 8.1Vulnerability

CVE-2026-62685

## Summary FileBrowser confines each user to a *scope*: a home directory that acts as the boundary for everything they can read or write. When self-registration and automatic home-directory creation are both enabled (`Signup=true` and `CreateUserDir=true`), a new user's scope is built from their username after it passes through `cleanUsername()`. That function rewrites the name: it strips `..` and replaces every character outside `0-9A-Za-z@_\-.` with `-`. The problem is that this rewrite is **many-to-one**: different usernames can produce the same result, and FileBrowser never checks whether the resulting scope is already taken. So `team/one`, `team one`, and `team-one` all collapse to the same directory name, and whoever registers second is handed the **same home directory** as the first user instead of an isolated one. This breaks per-user isolation. An attacker can pick a username that normalizes onto a victim's directory (for example registering `alice/` or `al..ice` to land in `alice`'s home) and gain full read **and** write access to that victim's files. Because username uniqueness is enforced on the raw name, both accounts coexist normally and neither user is warned that they share storage. ## Details **1. The home directory is built straight from the cleaned username (`settings/dir.go:30`)** ```go // MakeUserDir, when CreateUserDir is true: username = cleanUsername(username) // ... userScope = path.Join(s.UserHomeBasePath, username) // line 30 userScope = path.Join("/", userScope) // line 33 ``` The user's scope is `path.Join(UserHomeBasePath, cleanUsername(username))`. **2. `cleanUsername` collapses distinct inputs to the same output (`settings/dir.go:42-52`)** ```go func cleanUsername(s string) string { s = strings.Trim(s, " ") s = strings.ReplaceAll(s, "..", "") // line 45, deletes ".." s = invalidFilenameChars.ReplaceAllString(s, "-") // line 48, any non [0-9A-Za-z@_.-] -> "-" s =

Properties

severity
high
summary
File Browser: Colliding username normalization gives two users the same home directory
epss_score
0.00553
cvss_score
8.1
ghsa_published
2026-07-20T22:19:10Z
source_url
https://github.com/advisories/GHSA-7rc3-g7h6-22m7
ghsa_updated
2026-07-20T22:19:11Z
ghsa_id
GHSA-7rc3-g7h6-22m7
cve_id
CVE-2026-62685
cvss_vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
is_ghsa_only
false
epss_percentile
0.44076

Related Entities (6)

ENRICHED_BY (1)

[Source]FIRST EPSS

VULNERABLE_TO (1)

[Software]go/github.com/filebrowser/filebrowser/v2

AFFECTS (1)

[Software]go/github.com/filebrowser/filebrowser/v2

HAS_WEAKNESS (2)

[Weakness]Use of Non-Canonical URL Paths for Authorization Decisions
[Weakness]Use of Incorrectly-Resolved Name or Reference

REPORTED_BY (1)

[Source]GitHub Advisory Database

Explore deeper with Ninja Signal's threat intelligence graph

CVE-2026-62685 (CVSS 8.1) — Ninja Signal Threat Intelligence | Ninja Signal