Repository navigation
Conversation
Enable encrypted file and folder transfers with confirmation when crossing encryption states. Reuse folder creation and upload operations, preserve display names, and delete move sources only after a complete copy with a matching source version. Assisted-by: Codex:GPT-6 Signed-off-by: Li Wei <caeser222000@sohu.com>
Only persist upload results and encryption lock tokens when the reused upload operation has a stored upload ID. Copy and move transfers execute synchronously without a queue entry. Assisted-by: Codex:GPT-6 Signed-off-by: Li Wei <caeser222000@sohu.com>
Signed-off-by: O.O <caeser222000@163.com> Assisted-by: Codex:GPT-6
Signed-off-by: O.O <caeser222000@163.com> Assisted-by: Codex:GPT-6
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Android client currently does not support copying or moving encrypted files and folders into either ordinary or encrypted folders. This adds those operations while reusing the existing folder creation and upload code.
When the destination has a different encryption state, show a confirmation before transferring. Ordinary items entering an encrypted folder are encrypted. Encrypted files entering an ordinary folder are decrypted. For encrypted folders entering an ordinary folder, offer the choice to keep the folders encrypted or decrypt their contents.
Use decrypted names for destination names and ciphertext paths for server requests. A move deletes the source only after the complete copy succeeds, with an ETag condition to preserve a source changed during transfer. Unsynced local edits and conflicts also preserve the source. Temporary transfer uploads do not update nonexistent upload queue entries.
Validation
The contributor tested the operations on an Android phone against a live Nextcloud instance and supplied the client logs. The logs confirm these file operations:
An overwrite attempt returned
INVALID_OVERWRITEbefore any file upload or deletion. The logs also exposed attempts to update upload ID-1; this PR fixes that and includes regression tests. Personal logs and file names are not attached.Checklist
AI assistance
This contribution was developed and tested with assistance from Codex (GPT-6). The problem statement and requested behavior above are translated from the contributor's own messages; the contributor performed the phone tests and authorized publication and the additional test details derived from the exported logs.