You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Encrypted .aze files inside a moved folder can no longer be decrypted ("Failed to decrypt") #4753
Describe the bug
When a folder that contains Amaze-encrypted (.aze) files is moved (Cut → Paste) within the same storage, the saved encryption records of the files inside it are not updated and still point to the old paths. Decrypting a moved file then fails: no password prompt is shown, only a "Failed to decrypt" toast, and nothing is decrypted.
To Reproduce
Steps to reproduce the behavior:
Create /sdcard/F1/a.txt with some text, and an empty folder /sdcard/Dest.
In Amaze, encrypt F1/a.txt with the Amaze format (.aze), then delete the plain a.txt.
(Control) Decrypting F1/a.txt.aze in place shows the password dialog and, with the correct password, restores the original text.
Tap ⋮ on F1 → Cut, open Dest, tap PASTE. The file is now at /sdcard/Dest/F1/a.txt.aze.
Open Dest/F1 and decrypt a.txt.aze.
No password dialog appears and no decrypted file is produced. A "Failed to decrypt" toast is shown.
In explorer.db, the encrypted table still had the record at the old path …/F1/a.txt.aze after the move.
Expected behavior
Moving a folder updates the encryption records of every encrypted file inside it (recursively), so the moved files can be decrypted as before.
Screenshots
After moving F1 into Dest: decrypting Dest/F1/a.txt.aze shows "Failed to decrypt".
Smartphone (please complete the following information):
Device: XiaoMi 17 Pro max
OS: Android 16
Rooted: No
Version: 3.11.4
Additional context
Code on the default branch release/4.0 (94afab3):
Moves within the same storage finish in MoveFilesTask.onMovedCorrectly. It updates the record only for a selected item whose own name ends in .aze, and does not look inside selected folders: MoveFilesTask.kt#L114-L131
Moves that fall back to CopyService (e.g. across storages) use findAndReplaceEncryptedEntry, which does recurse into folders: CopyService.java#L311-L323
So the same-storage move path is the one that misses files inside folders. I only tested a same-storage move of a folder.
Activity
guireviveguirevive-svg commentedon Oct 21, 2026
I also encountered this bug, which really annoys me @EmmanuelMess @TranceLove