forked from decred/dcrd
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mixclient: Respect standard tx size limits
In order to meet the standard tx size requirements on mainnet, peers who contribute too much to the coinjoin transaction size must be excluded from the current run before the pairing is finalized. Failing to do so will only result in a transaction that fails to publish if all peers continue the mix to completion. Exclusion is performed by iterating all current PRs in the random order determined by the set of all PRs and the current epoch. A fake coinjoin transaction which is only meant to measure the expected tx size is added to only if that peer does not overcontribute to the size. The random peer order is sufficient to prevent this algorithm from being gamed. Any peers that become excluded will attempt a mix again in the following epoch. While it could be possible, we do not currently run multiple mixes for the same pairing type by splitting the PR set into two or more sets.
- Loading branch information
Showing
2 changed files
with
111 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters