Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
choo-t
· 3mo ago · 0 comments
You don't need a copy of the original data, you can simply store your change as a XOR so undoing it mean XORing it again.
Comments
[–]
Retr0id
3mo ago
However, if your change involves zeroing something out, you're back to storing the original data again.
[–]
Retr0id
3mo ago
Slightly silly idea to solve this: Hash all non-patched areas of the file to produce a key. Use the key to encrypt your XOR value. Thus the key can only be derived by someone who has either the original file, or the patched version.