Skip to content

Fix acquisition ZIP integrity checks#106

Open
besendorf wants to merge 1 commit into
mainfrom
fix/zip-archive-integrity
Open

Fix acquisition ZIP integrity checks#106
besendorf wants to merge 1 commit into
mainfrom
fix/zip-archive-integrity

Conversation

@besendorf

Copy link
Copy Markdown
Collaborator

Summary

This fixes cases where AndroidQF could finish secure storage after producing an invalid or incomplete ZIP archive.

The root cause was that finalization errors from archive/zip and the underlying files were not checked, so failures while writing the ZIP central directory could be missed. The archive writer now closes, syncs, and verifies the ZIP before reporting success.

The change also writes encrypted output through a temporary file before renaming it into place, avoids appending to existing encrypted output, and skips the destination archive if it is inside the source directory.

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