Summary
Flowise's files API may allow a low-privileged authenticated user to list organization files and delete files associated with other workspaces when permission checks are not enforced. The issue becomes risky when file operations rely on the active organization and user-controlled paths without validating workspace ownership or authorization.
Flowise's files API may allow a low-privileged authenticated user to list organization files and delete files associated with other workspaces when permission checks are not enforced. The issue becomes risky when file operations rely on the active organization and user-controlled paths without validating workspace ownership or authorization.
Affected context
The issue occurs in Flowise deployments where the /api/v1/files GET and DELETE routes are enabled and protected only by a feature gate. Risk is higher when these operations use the active organization context and caller-supplied paths without applying permission checks or constraining access to the active workspace.
The issue occurs in Flowise deployments where the /api/v1/files GET and DELETE routes are enabled and protected only by a feature gate. Risk is higher when these operations use the active organization context and caller-supplied paths without applying permission checks or constraining access to the active workspace.
Exploit preconditions
- Attack surface: Authenticated Flowise files API
- Required access: A valid low-privileged API key or authenticated account with unrelated permissions
- Trigger point: Requests to list files or delete a path through
/api/v1/files - Why exploitation is possible: The routes do not consistently enforce authorization, and file operations may trust the active organization identifier and user-controlled path without verifying workspace ownership
- Attack surface: Authenticated Flowise files API
- Required access: A valid low-privileged API key or authenticated account with unrelated permissions
- Trigger point: Requests to list files or delete a path through
/api/v1/files - Why exploitation is possible: The routes do not consistently enforce authorization, and file operations may trust the active organization identifier and user-controlled path without verifying workspace ownership
Why this happens
The underlying bug is a missing authorization check on file management operations. This maps to CWE-862: Missing Authorization, because the application allows a caller to invoke protected functionality without verifying that the caller is permitted to access the requested files or workspace. Relying on feature availability, active organization context, or path input is an insecure substitute for an explicit permission and resource-ownership decision.
The underlying bug is a missing authorization check on file management operations. This maps to CWE-862: Missing Authorization, because the application allows a caller to invoke protected functionality without verifying that the caller is permitted to access the requested files or workspace. Relying on feature availability, active organization context, or path input is an insecure substitute for an explicit permission and resource-ownership decision.
Potential impact
- Attackers may list files belonging to other workspaces
- Sensitive organization or workspace data could be disclosed
- Files may be deleted without authorization
- Workflows, datasets, or model-related assets could become unavailable
- Data integrity and availability may be affected across an organization
- Attackers may list files belonging to other workspaces
- Sensitive organization or workspace data could be disclosed
- Files may be deleted without authorization
- Workflows, datasets, or model-related assets could become unavailable
- Data integrity and availability may be affected across an organization
General mitigation guidance
Mitigation generally focuses on enforcing authorization at every file-operation boundary rather than relying on feature gates or client-provided context.
Defensive patterns include:
- Apply centralized permission checks to both read and destructive file operations
- Verify workspace ownership and organization membership for every requested resource
- Derive authorization context from trusted server-side identity data
- Treat file paths and resource identifiers as untrusted input and resolve them against an authorized resource model
- Use deny-by-default behavior when workspace or ownership context is missing or ambiguous
- Limit service and API-key privileges to the smallest required scope
- Record and monitor file access and deletion events for anomalous cross-workspace activity
Mitigation generally focuses on enforcing authorization at every file-operation boundary rather than relying on feature gates or client-provided context.
Defensive patterns include:
- Apply centralized permission checks to both read and destructive file operations
- Verify workspace ownership and organization membership for every requested resource
- Derive authorization context from trusted server-side identity data
- Treat file paths and resource identifiers as untrusted input and resolve them against an authorized resource model
- Use deny-by-default behavior when workspace or ownership context is missing or ambiguous
- Limit service and API-key privileges to the smallest required scope
- Record and monitor file access and deletion events for anomalous cross-workspace activity
How teams detect issues like this
Organizations can assess for this weakness through:
- Static analysis and route reviews that identify file handlers lacking centralized authorization checks
- Code review searches for GET or DELETE operations using organization, workspace, or path values without ownership validation
- Integration tests that exercise cross-workspace access with narrowly scoped API keys
- Policy checks requiring authorization middleware on sensitive file-management endpoints
- Audit-log analysis for file listings or deletions outside the caller's active workspace
- Automated security review tools that flag missing access-control checks and direct use of user-controlled resource paths
Organizations can assess for this weakness through:
- Static analysis and route reviews that identify file handlers lacking centralized authorization checks
- Code review searches for GET or DELETE operations using organization, workspace, or path values without ownership validation
- Integration tests that exercise cross-workspace access with narrowly scoped API keys
- Policy checks requiring authorization middleware on sensitive file-management endpoints
- Audit-log analysis for file listings or deletions outside the caller's active workspace
- Automated security review tools that flag missing access-control checks and direct use of user-controlled resource paths

