You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 301acc6
Browse filesBrowse the repository at this point in the historyBrowse files
Merge #1604: [master] sigcache: harden range proof cache keys and add -norangeproofcache option
53167b1 init: add -norangeproofcache startup option to disable range proof cache (Byron Hambly)
5e5f8e6 sigcache: add proof cache key collision-resistance tests (Byron Hambly)
b0a2752 sigcache: harden proof cache keys with length-prefixed hashing (Byron Hambly)
Pull request description:
target is **master** branch, cherry-picked commits from #1600
Switch the range-proof and surjection-proof cache hashers from raw
CSHA256 concatenation to CHashWriter . This length-prefixes
every field, so distinct argument tuples with byte-identical raw
concatenations no longer collide to the same cache key.
Both caches retain per-process salted midstates with distinct domain
separators ('r' / 's').
Also adds a -norangeproofcache startup option to
disable the range proof cache without recompiling.
ACKs for top commit:
tomt1664:
ACK 53167b1 tested locally
Tree-SHA512: 35412700e9773437b67b5ef350e752201856afab5e04e850ee6f9abe2aa4dc5127f5e9c13278c66236193f3279f34ec437f603ade6ba63e8149abd6f364c0246
argsman.AddArg("-capturemessages", "Capture all P2P messages to disk", ArgsManager::ALLOW_ANY | ArgsManager::DEBUG_ONLY, OptionsCategory::DEBUG_TEST);
637
637
argsman.AddArg("-mocktime=<n>", "Replace actual time with " + UNIX_EPOCH_TIME + " (default: 0)", ArgsManager::ALLOW_ANY | ArgsManager::DEBUG_ONLY, OptionsCategory::DEBUG_TEST);
638
638
argsman.AddArg("-maxsigcachesize=<n>", strprintf("Limit sum of signature cache and script execution cache sizes to <n> MiB (default: %u)", DEFAULT_VALIDATION_CACHE_BYTES >> 20), ArgsManager::ALLOW_ANY | ArgsManager::DEBUG_ONLY, OptionsCategory::DEBUG_TEST);
639
+
argsman.AddArg("-rangeproofcache", strprintf("Enable the range proof validation cache (default: %u). Use -norangeproofcache to disable.", 1), ArgsManager::ALLOW_ANY | ArgsManager::DEBUG_ONLY, OptionsCategory::DEBUG_TEST);
639
640
argsman.AddArg("-maxtipage=<n>",
640
641
strprintf("Maximum tip age in seconds to consider node in initial block download (default: %u)",
0 commit comments