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
key-wallet-manager: include watched_outpoints in compact-filter matching (defense-in-depth for #649-class bugs) #855
Splitting this out of #649 so it survives that issue's closure once PR #851 lands.
#649's own body flagged a secondary, defense-in-depth concern: check_compact_filters_for_addresses (key-wallet-manager/src/matching.rs) queries GCS filters using only output scriptPubKeys, not watched_outpoints(). Per BIP158, the basic filter type also contains each input's prevout scriptPubKey, so this currently works in practice — but relying on that implicitly, rather than also querying watched_outpoints() explicitly (the way the mempool bloom filter already does, dash-spv/src/sync/mempool/filter.rs), leaves no defense-in-depth if filter behavior or type ever changes.
PR #851 fixes #649's primary wallet-side reconciliation bug but does not touch filter matching — this is legitimate scoping, not an oversight, but the concern needs its own tracker so it isn't silently dropped when #649 closes.
Proposed fix
Add watched_outpoints() (serialized appropriately) to the set of items queried against compact filters in check_compact_filters_for_addresses, mirroring the existing mempool bloom filter's approach.
Activity