Files
Ferdinand Thiessen d9625876fd fix(encryption): keep the encrypted version the copy was written with
A copy re-encrypts the target, so the signature of its blocks is keyed on
the version of the target - the version of the file it overwrites plus one -
and not on the version of the source. Two writers overwrite that value after
the stream recorded it: updateEncryptedVersion() resets it to 1 for every
copy, and Cache::copyFromCache() then puts the source's version on the
target. Reading the copy back fails with "Bad Signature" whenever those
differ, which is the case for every copy of a file that was written more
than once and for every copy onto an existing file.

Take the version the stream recorded for the target instead of resetting it,
and let it win over the source's version when the cache entry of the copy is
written.

Assisted-by: ClaudeCode:claude-opus-5
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2026-09-20 22:28:03 +00:00
..
2024-05-24 13:11:22 +02:00
2025-07-01 16:26:50 +02:00
2024-05-24 13:11:22 +02:00
2025-07-01 16:26:50 +02:00
2025-07-01 16:26:50 +02:00