Commit 6f17f5b
committed
Merge bitcoin#32646: p2p: Add witness mutation check inside FillBlock
Backport of bitcoin#32646 (commits bac9ee4, 28299ce), slimmed for Dash. PartiallyDownloadedBlock::FillBlock now calls IsBlockMutated() instead of CheckBlock() as a belt-and-suspenders mutation check on reconstructed compact blocks, and the vestigial READ_STATUS_CHECKBLOCK_FAILED status is removed.
Dash adaptations: no segwit, so FillBlock keeps its 2-arg signature (no segwit_active parameter) and the mutation mock hook becomes IsBlockMutatedFn = std::function<bool(const CBlock&)> (m_check_block_mutated_mock). The fuzz harness is updated to mock IsBlockMutated instead of CheckBlock.1 parent f43c2b8 commit 6f17f5b
4 files changed
Lines changed: 15 additions & 60 deletions
File tree
- src
- test/fuzz
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
203 | 203 | | |
204 | 204 | | |
205 | 205 | | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
216 | 210 | | |
217 | 211 | | |
218 | 212 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
87 | | - | |
88 | | - | |
89 | 87 | | |
90 | 88 | | |
91 | 89 | | |
| |||
136 | 134 | | |
137 | 135 | | |
138 | 136 | | |
139 | | - | |
140 | | - | |
| 137 | + | |
| 138 | + | |
141 | 139 | | |
142 | 140 | | |
143 | 141 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3674 | 3674 | | |
3675 | 3675 | | |
3676 | 3676 | | |
3677 | | - | |
3678 | | - | |
3679 | | - | |
3680 | | - | |
3681 | | - | |
3682 | | - | |
3683 | | - | |
3684 | | - | |
3685 | | - | |
3686 | | - | |
3687 | | - | |
3688 | | - | |
3689 | | - | |
3690 | | - | |
3691 | | - | |
3692 | | - | |
3693 | | - | |
| 3677 | + | |
3694 | 3678 | | |
3695 | 3679 | | |
3696 | 3680 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
32 | 32 | | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
| 33 | + | |
| 34 | + | |
39 | 35 | | |
40 | 36 | | |
41 | 37 | | |
| |||
103 | 99 | | |
104 | 100 | | |
105 | 101 | | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
125 | 105 | | |
126 | 106 | | |
127 | 107 | | |
128 | 108 | | |
129 | 109 | | |
130 | 110 | | |
131 | | - | |
| 111 | + | |
132 | 112 | | |
133 | 113 | | |
134 | | - | |
135 | 114 | | |
136 | | - | |
| 115 | + | |
137 | 116 | | |
138 | 117 | | |
139 | 118 | | |
| |||
0 commit comments