Review report

core: PR #33324

๐ŸŸ  Major

Migration skips block files numbered 100000 or higher (src/node/blockstorage.cpp:192, head)

FlatFileSeq::FileName uses %05u as a minimum width, so valid names such as blk100000.dat and rev100000.dat are possible. This length check excludes them from migration, but the code still activates the new XOR key. Omitted files remain encoded with the old key and become unreadable. Recognize the full numeric filename component supported by FlatFileSeq, or fail before changing files or keys if a valid filename cannot be handled.

๐ŸŸก Minor

Rewritten files do not preserve modification times (src/node/blockstorage.cpp:266, head)

The staged output is created as a new file and activated without copying the source file's modification time. This contradicts the PR description's timestamp-preservation promise and can cause unnecessary copies for backups that detect changes by size and modification time. Capture the source timestamp and apply it to the staged file before activation.

๐Ÿ’ก Suggestion

Verify migrated bytes decode to the originals (test/functional/feature_reobfuscation.py:61, head)

The test snapshots the original files but checks only that the migrated bytes differ. A truncated or incorrectly transformed staged file could pass these assertions; the delta unit test does not cover the migration stream or key activation. After migration, XOR the rewritten bytes with the active key and compare them with the saved originals, or otherwise verify equivalent end-to-end preservation. This tests the stated migration behavior without additional fixture setup.