/

CVE-2026-55418

Severity:

HIGH RISK

(8.6)

Insecure Direct Object Reference (CWE-639) in FastGPT

CVE-2026-55418

Deferred

Vulnerability type

Category:

Insecure Direct Object Reference

CWE:

CWE-639

Impact:

Cross-tenant data exposure and unauthorized file access

Severity:

HIGH RISK

(8.6)

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

FastGPT contains an insecure direct object reference issue where S3 object keys from client requests are used without verifying tenant ownership.

Under certain multi-tenant configurations, this can allow an attacker to access other teams' files via chat-file presign and dataset preview endpoints.

Affected context

This vulnerability occurs in FastGPT deployments using a shared S3 bucket for multiple tenants or teams.

The affected file handlers authorize access based on an unrelated resource and then operate on S3 objects using keys taken directly from the request.

Because S3 keys are globally scoped within the bucket and include tenant identifiers only as path segments, object access is not inherently restricted to the caller's team.

Exploit preconditions

  • Attack surface: HTTP APIs exposing chat-file presign and dataset preview functionality
  • Required access: Ability to send authenticated or semi-authenticated requests to FastGPT's file handling endpoints
  • Trigger point: Supplying an S3 object key associated with another team in the request parameters
  • Why exploitation is possible: The handlers validate access to a different resource but do not enforce that the provided S3 key belongs to the caller's tenant, enabling cross-tenant direct object references

Why this happens

The core issue is an access control design flaw where authorization is not tightly bound to the specific object being accessed.

Instead of deriving or validating the S3 key from the authenticated tenant context, the application trusts a client-supplied key and assumes the earlier authorization check is sufficient.

This maps to CWE-639: Insecure Direct Object Reference (IDOR), where a user-controlled identifier is used to access resources without ensuring that the user is authorized for that exact resource.

Potential impact

  • An attacker may read files belonging to another team or tenant stored in the shared S3 bucket.
  • Sensitive dataset previews could be accessed by unauthorized users.
  • Chat-related file contents can be exposed, including proprietary or confidential information.
  • Multi-tenant isolation can be broken, leading to regulatory and compliance issues.

General mitigation guidance

Effective mitigation focuses on binding authorization checks to the specific resource being accessed and eliminating trust in client-supplied identifiers.

Recommended patterns include:

  • Deriving storage keys from the authenticated tenant or team context rather than taking them directly from requests.
  • Validating that any provided object key is owned by, or scoped to, the caller's tenant before signing or reading it.
  • Using per-tenant buckets, prefixes, or access policies so that cross-tenant keys cannot be referenced.
  • Treating all incoming identifiers as untrusted and enforcing strict authorization rules at the object level.

How teams detect issues like this

Detection commonly involves:

  • Static analysis or security review to locate code paths where user-controlled identifiers are passed to storage APIs or presign operations without tenant ownership checks.
  • Reviewing controller and handler logic for mismatches between the resource being authorized and the resource actually accessed (e.g., separate IDs for auth and S3 operations).
  • Applying policy-based checks that require object-level authorization for any file access in multi-tenant contexts.
  • Leveraging automated code scanning tools configured with rules for IDOR patterns and insecure resource key usage.

Sources

SourceLink
github.comgithub.com/labring/FastGPT/commit/decb6d2fb1417fb9e2bca145d2dcc9cbcf06396c
github.comgithub.com/labring/FastGPT/pull/7104
github.comgithub.com/labring/FastGPT/releases/tag/v4.15.0-beta5
github.comgithub.com/labring/FastGPT/security/advisories/GHSA-6rxv-p43w-mmx5

Frequently asked

questions

Exploitability depends on whether an attacker can obtain or guess valid S3 object keys for other teams and has access to the affected endpoints; in multi-tenant deployments with shared buckets, this can be practical.

The attacker typically needs network access to FastGPT's APIs and sufficient credentials or session context to call the chat-file presign or dataset preview endpoints, but does not need to be part of the victim team.

Tie authorization directly to the object being accessed: derive or validate S3 keys from the authenticated tenant context, enforce that only tenant-owned keys can be used, and avoid relying on unrelated resource checks for file access.

Adopt consistent access control patterns for all resource identifiers, treat client-supplied IDs as untrusted, enforce tenant scoping at storage and application layers, and include IDOR-focused checks in code review and automated security testing.

Find out what's already
exploitable in your codebase.