Ever since we #5913 have been sending invalid reject messages for transactions and blocks.
net: Fix sent reject messages for blocks and transactions #7179
pull laanwj wants to merge 2 commits into bitcoin:master from laanwj:2015_12_fix_reject_message changing 5 files +123 −6-
laanwj commented at 1:58 PM on December 7, 2015: member
-
9fc6ed6003
net: Fix sent reject messages for blocks and transactions
Ever since we #5913 have been sending invalid reject messages for transactions and blocks.
- laanwj added the label Needs backport on Dec 7, 2015
-
dcousens commented at 2:30 PM on December 7, 2015: contributor
Worth adding a regression test?
-
laanwj commented at 2:47 PM on December 7, 2015: member
Would make sense.
-
laanwj commented at 9:40 AM on December 8, 2015: member
To be clear, this solves the following issue:
Normal reject message
2015-12-07 20:16:52 peer=1096 Reject tx code 64: non-final: hash 54fae12b1dc553ec56137138ad28304569c9b3a69791fca5a02664b379a7d6baReject message from 0.11.99+
2015-12-04 16:07:00 peer=322 Reject tx code 66: : hash 6e6f69746361736e617274206565726620646574696d696c20657461721d0000Reason seems empty, and part of the reason message ends up in the "hash". This is due to the reject code being sent as multiple bytes instead of one, misaligning the message.
Edit: trying to think of a test. Hopefully it could fit somewhere in the Python P2P test framework, without creating a new script.
- laanwj added this to the milestone 0.12.0 on Dec 8, 2015
-
MarcoFalke commented at 9:47 AM on December 8, 2015: member
utACK 9fc6ed6
-
laanwj commented at 4:15 PM on December 8, 2015: member
Added basic tests for rejection of blocks and transactions. (tested that they pass with this patch, and fail without)
- laanwj force-pushed on Dec 8, 2015
- laanwj force-pushed on Dec 8, 2015
- laanwj force-pushed on Dec 8, 2015
-
20411903d7
test: Add basic test for `reject` code
Extend P2P test framework to make it possible to expect reject codes for transactions and blocks.
- laanwj force-pushed on Dec 9, 2015
-
sdaftuar commented at 10:18 AM on December 9, 2015: member
Sure, will take a look.
- laanwj merged this on Dec 10, 2015
- laanwj closed this on Dec 10, 2015
- laanwj referenced this in commit 5dc63ed1ca on Dec 10, 2015
- laanwj referenced this in commit 44fef99e66 on Dec 10, 2015
-
sdaftuar commented at 11:24 AM on December 10, 2015: member
post-merge ACK. The extension to the test framework seems like a good idea!
- luke-jr referenced this in commit e08060dd84 on Jan 10, 2016
- luke-jr referenced this in commit 3e167cfddd on Jan 10, 2016
-
laanwj commented at 8:08 AM on February 4, 2016: member
This is cherry-picked to 0.12 as 44fef99e666e85caa7616765412d7becf97ab673, removing needs backport label
- laanwj removed the label Needs backport on Feb 4, 2016
- zkbot referenced this in commit 19a8c45f42 on Aug 13, 2021
- zkbot referenced this in commit 8e9f44cbe2 on Aug 13, 2021
- zkbot referenced this in commit cf9a0799b4 on Aug 17, 2021
- MarcoFalke locked this on Sep 8, 2021
Milestone
0.12.0