fix(app): saved files are the own user's alone, and iOS's copy goes

On the desktop a saved file (a recovery phrase, recovery codes, an
archive with progress) is made the own user's alone (0600, chmod(2)
through the C library already in the process) on the emptied file before
anything is written, so no other user of the machine reads it; Windows'
files keep their folder's rights. On iOS, file_picker (darwin v2.1.2)
writes a copy into the app's temporary folder for the system's picker and
never removes it, saved or cancelled: it goes once the picker is done.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-10-21 14:44:10 +02:00
commit 001ab37d09
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -11,6 +11,8 @@ environment:
dependencies:
clock: ^1.1.3
equatable: ^3.0.0
# chmod(2) for files saved on the desktop: the own user's alone (FileSaver).
ffi: ^2.2.0
# Keeping a file the app made where the person chooses (FileSaver): the
# system's dialog on Android and iOS, file_selector's on the desktop.
file_picker: ^13.1.0