/

CVE-2026-34046

Severity:

HIGH RISK

(8.8)

Broken Access Control in Langflow Flow Access Helper

CVE-2026-34046

Analyzed

Vulnerability type

Category:

Broken Access Control

CWE:

CWE-639, CWE-862

Impact:

Unauthorized Access to Other Users' Flows and Secrets

Severity:

HIGH RISK

(8.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

Langflow contained a broken access control issue in the _read_flow helper that failed to enforce ownership checks when retrieving flows by UUID.

Under normal authenticated operation, any logged-in user could read, modify, or delete flows belonging to other users, including accessing embedded plaintext API keys, by supplying their UUIDs.

Affected context

This vulnerability affects Langflow deployments that:

  • Run with authentication enabled (AUTO_LOGIN = False)
  • Use multi-user environments where flows are associated with specific users
  • Allow users to reference flows by UUID (e.g., via API calls or UI actions)

In this context, the _read_flow helper did not constrain queries by the requesting user's identity, so any valid flow UUID could be used to operate on someone else's flow.

Exploit preconditions

  • Attack surface: Application backend endpoints that read, update, or delete flows via UUID.
  • Required access: Any authenticated user account on the Langflow instance (no special roles required).
  • Trigger point: Supplying the UUID of a target flow to operations that invoke _read_flow, such as viewing, editing, or deleting a flow.
  • Why exploitation is possible: The database query inside _read_flow branched on the AUTO_LOGIN setting but, when authentication was enabled, did not enforce a user_id ownership check, causing the system to return or manipulate flows purely based on UUID.

Why this happens

The core issue is a broken access control pattern where authorization checks are incomplete and rely solely on an unscoped resource identifier.

Specifically, the _read_flow helper performed a database lookup by flow UUID and conditionally handled public/example flows when auto-login was enabled, but omitted a user_id filter on the authenticated path.

This maps to CWE-639: Authorization Bypass Through User-Controlled Key, because a user-controlled UUID was sufficient to access another user's resource, and to CWE-862: Missing Authorization, since the code path lacked a definitive ownership or permission check.

The design assumed that possession of a valid UUID implied legitimacy, rather than validating that the requesting user was the owner of, or otherwise authorized for, the target flow.

Potential impact

  • Unauthorized reading of other users' flows, including embedded plaintext API keys and other secrets.
  • Modification of another user's AI agent logic and workflow definitions, potentially altering behavior or exfiltrating data.
  • Deletion of flows belonging to other users, resulting in denial of service or data loss for affected accounts.
  • Lateral access to external services or data sources configured in other users' flows via exposed credentials.
  • Undermining of tenant isolation in shared or multi-team Langflow deployments.

General mitigation guidance

Effective mitigation focuses on enforcing consistent, explicit authorization at the resource access layer and avoiding reliance on opaque identifiers as proof of access.

Recommended defensive patterns include:

  • Scoping all flow queries by the authenticated user's identity (e.g., WHERE id = :uuid AND user_id = :current_user_id) and only relaxing this for explicitly defined public resources with clear policy.
  • Centralizing authorization logic for resource access in a dedicated layer or service, rather than embedding conditional checks in helper functions.
  • Implementing a clear model for public/example flows (e.g., a visibility field) and deriving access decisions from that model instead of configuration flags like AUTO_LOGIN.
  • Treating UUIDs and similar identifiers as untrusted, user-controlled input that always requires a permission check before returning or mutating data.
  • Minimizing or encrypting sensitive secrets stored inside flows so that accidental exposure yields less impact, and segregating secret storage from general workflow metadata.

Designing the application so that the default path is scoped to the current user and all exceptions are narrowly defined reduces the risk of similar oversights.

How teams detect issues like this

Detection typically involves both code-level and runtime monitoring strategies:

  • Static analysis and code review:
  • Flag all resource lookups by UUID or primary key that do not also constrain by user_id, tenant ID, or a similar ownership attribute.
  • Review helper functions and service methods that bypass centralized authorization middleware or contain configuration-based branching around access checks.
  • Enforce secure coding guidelines stating that every data access path must have an explicit authorization decision.
  • Automated policy enforcement:
  • Use linters or SAST tools configured with custom rules to detect missing authorization checks around database queries for user-owned resources.
  • Introduce architectural tests that verify all flow-related endpoints call a central authorization routine.
  • Runtime and log-based detection:
  • Log flow access events with requesting user ID and target flow ID, and analyze for patterns where many distinct owners' flows are accessed by a single account.
  • Monitor for unusual deletion or modification activity across many users' flows from one source account.

Combining static enforcement with behavioral analytics improves the chance of spotting both existing issues and attempts to exploit them.

Sources

SourceLink
github.comgithub.com/langflow-ai/langflow/pull/8956
github.comgithub.com/langflow-ai/langflow/security/advisories/GHSA-8c4j-f57c-35cf

Frequently asked

questions

Any user with a valid login on the affected Langflow instance could exploit it as long as they knew or could obtain the UUID of another user's flow. No elevated privileges were required, which makes it broadly exploitable in multi-user environments.

No special roles are necessary. Basic authenticated access is sufficient, because the vulnerable helper did not verify that the requester owned the flow associated with the provided UUID.

The safest approach is to centralize and enforce ownership checks on all resource access paths: every query for a user-owned flow should include a constraint on the current user's identity, and public/example resources should be modeled explicitly with their own access rules rather than inferred from configuration flags.

Preventing recurrences involves adopting a consistent authorization model, mandating explicit checks for every resource access, and validating this through code review, automated tests, and static analysis. Additionally, treat identifiers such as UUIDs as untrusted input, keep sensitive secrets out of user-editable structures where possible, and document clear patterns for handling shared or public resources.

Find out what's already
exploitable in your codebase.