Commit 6d5771b
committed
Merge bitcoin#24494: wallet: generate random change target for each tx for better privacy
9053f64 [doc] release notes for random change target (glozow)
46f2fed [wallet] remove MIN_CHANGE (glozow)
a44236a [wallet] randomly generate change targets (glozow)
1e52e6b refactor coin selection for parameterizable change target (glozow)
Pull request description:
Closes bitcoin#24458 - the wallet always chooses 1 million sats as its change target, making it easier to fingerprint transactions created by the Core wallet. Instead of using a fixed value, choose one randomly each time (within a range). Using 50ksat (around $20) as the lower bound and `min(1 million sat, 2 * average payment value)` as the upper bound.
RFC: If the payment is <25ksat, this doesn't work, so we're using the range (payment amount, 50ksat) instead.
ACKs for top commit:
achow101:
ACK 9053f64
Xekyo:
reACK 9053f64
Tree-SHA512: 45ce5d064697065549473347648e29935733f3deffc71a6ab995449431f60302d1f9911a0994dfdb960b48c48b5d8859f168b396ff2a62db67d535a7db041d35File tree
8 files changed
+157
-92
lines changed- doc
- src
- bench
- qt
- wallet
- test
- test/functional
8 files changed
+157
-92
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
| |||
66 | 67 | | |
67 | 68 | | |
68 | 69 | | |
| 70 | + | |
69 | 71 | | |
70 | 72 | | |
71 | 73 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
37 | 36 | | |
38 | 37 | | |
39 | 38 | | |
| |||
486 | 485 | | |
487 | 486 | | |
488 | 487 | | |
489 | | - | |
490 | | - | |
491 | | - | |
| 488 | + | |
492 | 489 | | |
493 | 490 | | |
| 491 | + | |
494 | 492 | | |
495 | 493 | | |
496 | 494 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
187 | 187 | | |
188 | 188 | | |
189 | 189 | | |
190 | | - | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
191 | 203 | | |
192 | 204 | | |
193 | 205 | | |
194 | 206 | | |
| 207 | + | |
195 | 208 | | |
196 | 209 | | |
197 | 210 | | |
| |||
217 | 230 | | |
218 | 231 | | |
219 | 232 | | |
| 233 | + | |
| 234 | + | |
220 | 235 | | |
221 | 236 | | |
222 | 237 | | |
| |||
231 | 246 | | |
232 | 247 | | |
233 | 248 | | |
234 | | - | |
| 249 | + | |
| 250 | + | |
235 | 251 | | |
236 | 252 | | |
237 | 253 | | |
238 | 254 | | |
239 | 255 | | |
| 256 | + | |
| 257 | + | |
240 | 258 | | |
241 | 259 | | |
242 | 260 | | |
| |||
246 | 264 | | |
247 | 265 | | |
248 | 266 | | |
249 | | - | |
| 267 | + | |
250 | 268 | | |
251 | 269 | | |
252 | 270 | | |
| |||
273 | 291 | | |
274 | 292 | | |
275 | 293 | | |
276 | | - | |
277 | | - | |
| 294 | + | |
| 295 | + | |
278 | 296 | | |
279 | 297 | | |
280 | 298 | | |
281 | 299 | | |
282 | 300 | | |
283 | | - | |
| 301 | + | |
284 | 302 | | |
285 | 303 | | |
286 | 304 | | |
| |||
380 | 398 | | |
381 | 399 | | |
382 | 400 | | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
383 | 412 | | |
384 | 413 | | |
385 | 414 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
96 | 99 | | |
97 | 100 | | |
| 101 | + | |
| 102 | + | |
98 | 103 | | |
99 | 104 | | |
100 | 105 | | |
| |||
114 | 119 | | |
115 | 120 | | |
116 | 121 | | |
117 | | - | |
| 122 | + | |
| 123 | + | |
118 | 124 | | |
119 | 125 | | |
120 | 126 | | |
121 | 127 | | |
| 128 | + | |
122 | 129 | | |
123 | 130 | | |
124 | 131 | | |
| |||
217 | 224 | | |
218 | 225 | | |
219 | 226 | | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
220 | 242 | | |
221 | 243 | | |
222 | 244 | | |
| |||
266 | 288 | | |
267 | 289 | | |
268 | 290 | | |
269 | | - | |
| 291 | + | |
| 292 | + | |
270 | 293 | | |
271 | 294 | | |
272 | 295 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
| |||
389 | 391 | | |
390 | 392 | | |
391 | 393 | | |
392 | | - | |
| 394 | + | |
| 395 | + | |
393 | 396 | | |
394 | 397 | | |
395 | 398 | | |
396 | 399 | | |
397 | | - | |
398 | | - | |
399 | | - | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
400 | 405 | | |
401 | 406 | | |
402 | 407 | | |
| |||
680 | 685 | | |
681 | 686 | | |
682 | 687 | | |
| 688 | + | |
683 | 689 | | |
684 | 690 | | |
685 | 691 | | |
| |||
0 commit comments