Repository navigation
tw-pack: read_strict refuses a plain pack when a key is given; scrypt cap 18 - #354
Merged
Merged
Conversation
… cap 18 - read_strict(bytes, unseal): with a passphrase or an identity, a pack that is not encrypted is refused (pack.not_encrypted). For a sync location with encryption on, where accepting a plain version would let anyone who can write there change this device's configuration. - The largest scrypt work factor a pack may ask for is now the one packs are written with (18), like the sync keyring; 22 meant about 4 GiB. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
tw_pack::read_strict(bytes, unseal): the same asread, except that withUnseal::PassphraseorUnseal::Identitya pack that is not encrypted is refused withPackError::NotEncrypted(pack.not_encrypted).readkeeps accepting either, which is what importing a file the user picked needs. Sync should read versions withread_strictwhen the location is encrypted.Local runs:
cargo fmt --check,cargo clippy --workspace --all-targets -D warnings,cargo test -p tw-pack,cargo test -p tw-sync, message code manifest.🤖 Generated with Claude Code