/

CVE-2026-133172

Severity:

HIGH RISK

(8.8)

Authorization Bypass (CWE-639) in Cozy Stack Move Handler

CVE-2026-133172

Received

Vulnerability type

Category:

Authorization Bypass

CWE:

CWE-639

Impact:

Unauthorized access to and deletion of files across instances

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

Cozy Stack's shared-drive move handler has an authorization flaw that may let an authenticated user access files belonging to another instance. The risk arises when a user who owns a shared drive can supply another instance's domain and a directory ID as the move source, potentially copying and deleting the victim's file tree.

Affected context

The issue is in the shared-drive move handler in Cozy Cloud cozy-stack versions before 1.6.69. It may be present when the handler processes a move source identified by a user-supplied domain and directory ID without adequately verifying that the requesting user is authorized to access that instance's files.

Exploit preconditions

  • Attack surface: The shared-drive move operation
  • Required access: An authenticated account that owns a shared drive
  • Trigger point: Processing a move request with a source naming another instance's domain and a directory ID
  • Why exploitation is possible: The handler may not sufficiently bind the supplied source identifiers to the user's authorized instance and file scope

Why this happens

The move handler appears to rely on user-controlled identifiers to select files without enforcing authorization against the relevant instance and directory. This maps to CWE-639: Authorization Bypass Through User-Controlled Key, in which an attacker changes a key used to identify a resource and gains access because authorization checks do not adequately constrain that lookup.

Potential impact

  • An attacker may access files belonging to another instance
  • Files or directory trees could be copied without authorization
  • A victim's file tree could be deleted as part of the move operation
  • The incident could cause data exposure, data loss, or operational disruption

General mitigation guidance

Mitigations generally focus on enforcing authorization at the point where resources are resolved and acted upon.

  • Derive tenant and instance scope from trusted authenticated context rather than accepting it solely from request parameters
  • Verify ownership and permissions for every source and destination resource before performing a move
  • Use secure-by-default resource lookups that restrict results to the caller's authorized scope
  • Apply least privilege to services and accounts that perform file operations
  • Treat client-provided identifiers as untrusted and avoid relying on obscurity or identifier unpredictability as an access control

How teams detect issues like this

  • Review move-handler code for resource lookups driven by caller-supplied domains or directory IDs
  • Use static analysis or code review checks to flag resource access that lacks nearby authorization and tenant-scope validation
  • Test authorization policies with cross-instance resource references, including both copy and delete behavior
  • Monitor for move operations involving resources outside the authenticated user's instance or permitted scope
  • Enforce policy checks at service boundaries so cross-tenant file operations are denied by default

Sources

SourceLink
github.comgithub.com/linagora/cozy-stack/blob/1.6.68/web/sharings/move.go#L250-L263
github.comgithub.com/linagora/cozy-stack/commit/983fe4b1218b8a7d83a2734b5ce2fe04227acc0c
github.comgithub.com/linagora/cozy-stack/pull/5179
github.comgithub.com/linagora/cozy-stack/releases/tag/1.6.69
hackmd.iohackmd.io/@hieund/cozy-stack-shared-drive-move-cross-instance-authz-bypass
vulncheck.comvulncheck.com/advisories/cozy-cloud-cozy-stack-1.6.62-before-1.6.69-authorization-bypass-via-shared-drive-move
hackmd.iohackmd.io/@hieund/cve-2026-133172-cozy-stack-shared-drive-move-cross-instance-authz-bypass

Frequently asked

questions

The described attack uses the shared-drive move handler. It may be exploitable through that operation when an authenticated user can submit the relevant source identifiers.

An attacker must be authenticated and own a shared drive. The description does not indicate that administrative access is required.

Resolve resources within the caller's trusted instance scope and verify authorization for both source and destination before copying or deleting files.

Treat resource identifiers as untrusted, enforce object-level authorization on every operation, and test for cross-tenant access in code review and automated security checks.

Find out what's already
exploitable in your codebase.