/

CVE-2026-73034

Severity:

CRITICAL RISK

(9.8)

Path Traversal (CWE-22) in DB-GPT File Upload Endpoint

CVE-2026-73034

Deferred

Vulnerability type

Category:

Path Traversal

CWE:

CWE-22

Impact:

Arbitrary File Write and Potential Remote Code Execution

Severity:

CRITICAL RISK

(9.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

DB-GPT contains a critical unauthenticated path traversal vulnerability in its Python file-upload endpoint. A remote attacker may manipulate the upload destination through the user_id HTTP header and write attacker-controlled files outside the intended directory, potentially enabling remote code execution.

Affected context

The vulnerability occurs in DB-GPT deployments where the Python file-upload endpoint is reachable over the network and uses the user_id HTTP header to construct an upload path without sufficiently restricting or canonicalizing it. The risk is highest when the service is exposed without authentication and the process can write to executable, startup, scheduled-task, or agent-related locations.

Exploit preconditions

  • Attack surface: Network-accessible Python file-upload HTTP endpoint
  • Required access: No authentication may be required when the endpoint is exposed as described
  • Trigger point: Multipart file upload handling that derives a destination path from the user_id HTTP header
  • Why exploitation is possible: Insufficient path canonicalization and containment checks may allow attacker-controlled paths to escape the designated upload directory

Why this happens

The underlying bug is an unsafe file path construction pattern. User-controlled header data is incorporated into a filesystem path without reliably normalizing the result and verifying that the resolved path remains within the intended upload root.

This behavior maps to CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal'). When attacker-influenced path components are trusted as directory or filename data, the application may perform writes in unintended filesystem locations.

Potential impact

  • Attackers may write arbitrary content to locations permitted by the service account
  • The application process may execute attacker-controlled code during startup or task processing
  • Scheduled jobs, agent scripts, or application behavior could be altered
  • Sensitive files may be overwritten or corrupted
  • The host or surrounding services could be compromised if higher-privilege write locations are reachable

General mitigation guidance

Mitigation generally focuses on removing user-controlled filesystem paths and enforcing a strict storage boundary.

Common defensive patterns include:

  • Derive storage paths from server-generated identifiers rather than request headers
  • Treat upload names and identity values as data, not directory paths
  • Canonicalize candidate paths and verify they remain beneath an approved upload root
  • Use allowlisted filenames, extensions, and content types where appropriate
  • Store uploads in isolated, non-executable locations with restrictive permissions
  • Require authentication and authorization for upload operations
  • Run the service with the minimum filesystem privileges needed
  • Apply resource limits, audit logging, and malware or content inspection for uploaded files

How teams detect issues like this

Organizations can detect path traversal risks through:

  • Static analysis rules for filesystem APIs receiving HTTP headers, parameters, or multipart metadata
  • Code review checks for string concatenation or interpolation used to construct file paths
  • Tests that verify canonical path containment and reject unexpected path components
  • Runtime monitoring for file creation outside approved upload directories
  • Web application firewall or gateway policies that restrict anomalous upload metadata
  • File integrity monitoring for startup hooks, scheduled-task directories, and agent scripts
  • Automated security review tools that flag untrusted input flowing into file-write operations

Sources

SourceLink
github.comgithub.com/eosphoros-ai/DB-GPT
github.comgithub.com/eosphoros-ai/DB-GPT/commit/e0c741bd2b5e521b128cffb3f68982dde3f7b359
github.comgithub.com/eosphoros-ai/DB-GPT/issues/3104
vulncheck.comvulncheck.com/advisories/db-gpt-path-traversal-arbitrary-file-write-via-user-id-header

Frequently asked

questions

Yes, when the DB-GPT file-upload endpoint is network reachable and does not require authentication. Exploitation still depends on the service account having permission to write to a useful target location.

Not necessarily. The described issue is unauthenticated, so network access to the affected endpoint may be sufficient.

Avoid accepting client-controlled directory paths. Generate server-side storage names, enforce canonical path containment, and place uploads in isolated non-executable storage.

Use least-privilege service accounts, require authorization for uploads, validate and normalize all path-related input, monitor unexpected file writes, and test upload handlers for directory-boundary violations.

Find out what's already
exploitable in your codebase.