mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-10 05:57:59 +01:00
Merge bitcoin/bitcoin#28207: mempool: Persist with XOR
fa6b053b5cmempool: persist with XOR (MarcoFalke) Pull request description: Currently the `mempool.dat` file stores data received from remote peers as-is. This may be problematic when a program other than Bitcoin Core tries to interpret them by accident. For example, an anti-virus program or other program may scan the file and move it into quarantine, or delete it, or corrupt it. While the local wallet is expected to re-submit any pending transactions, unrelated transactions may be missing from the mempool after a restart. This may cause fee estimates to be off, or may cause block relay to be slower. Fix this, similar to https://github.com/bitcoin/bitcoin/pull/6650, by rolling a random XOR pattern over the dat file when writing or reading it. Obviously this can only protect against programs that accidentally and unintentionally are trying to mess with the dat file. Any program that intentionally wants to mess with the dat file can still trivially do so. ACKs for top commit: achow101: re-ACKfa6b053b5cglozow: reACKfa6b053b5cismaelsadeeq: ACKfa6b053b5cTree-SHA512: ded2ce3d81bc944b828263534e3178a1e45a914fe8e024f4a14c6561a73e301820944ecc75dd704b3d4221a7a3a5c0597ccab79546250c1197609ee981fe324e
This commit is contained in:
7
doc/release-notes-28207.md
Normal file
7
doc/release-notes-28207.md
Normal file
@@ -0,0 +1,7 @@
|
||||
mempool.dat compatibility
|
||||
========================
|
||||
|
||||
The `mempool.dat` file created by -persistmempool or the savemempool RPC will
|
||||
be written in a new format, which can not be read by previous software
|
||||
releases. To allow for a downgrade, a temporary setting `-persistmempoolv1` has
|
||||
been added to fall back to the legacy format.
|
||||
Reference in New Issue
Block a user