Skip to content

Enforce sync_paths allowlist for write, rename, and delete operations - #19

Open
mikaelweave wants to merge 3 commits into
IsmaeelAkram:masterfrom
mikaelweave:feature/enforce-sync-path-policy
Open

Enforce sync_paths allowlist for write, rename, and delete operations#19
mikaelweave wants to merge 3 commits into
IsmaeelAkram:masterfrom
mikaelweave:feature/enforce-sync-path-policy

Conversation

@mikaelweave

@mikaelweave mikaelweave commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Summary

  • enforce sync_paths and exclude_paths before every mutating FUSE operation
  • prevent disallowed dirty entries and cross-boundary renames from reaching iCloud
  • document the hard synchronization boundary and add coverage for allowed and rejected operations

Why?

When sync_paths is configured, enforce it for every local filesystem operation that can affect iCloud:

  • Create files or directories
  • Write or truncate files
  • Rename or move entries
  • Delete files or directories
  • Upload changed content

Operations outside the allowlisted paths should fail with an appropriate filesystem error such as EACCES or EPERM.

For rename and move operations, both the source and destination paths should be allowed.

exclude_paths should continue to take precedence over sync_paths.

Testing

  • python -m unittest -v test_driver (with local dependency shims because the host lacks FUSE build tooling)

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: ce92f992-712e-47b2-a98a-4b268f67db3a
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: b72c9df1-26d9-48ba-b15f-b075f2d8eb95
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: b72c9df1-26d9-48ba-b15f-b075f2d8eb95
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant