Skip to content

Conversation

@PastaPastaPasta
Copy link
Member

Tests currently fail. I did my best to fix them, this is a dependency for further p2p refactoring and changes I have done.

Copy link

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See inline comments + should apply the same logic to NetMsgType::REJECT messages in governance.cpp and privatesend-client/server.cpp

@UdjinM6 UdjinM6 added this to the 16 milestone Apr 16, 2020
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

General comment regarding future BIP61-related backports. IIRC, Bitcoin eventually sets this to false and then entirely removes BIP61 support. The removal of BIP61 from Bitcoin Core was extremely controversial from the standpoint of mobile wallets.

Not sure what our plan is for when we get to that point, but wanted to bring it up so we do not blindly follow Bitcoin. I imagine @HashEngineering and @QuantumExplorer will want to provide input on that.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct, I've seen this, but these backports at this point are needed for resolving conflicts. Also, I do think their reasoning for removing it made senes

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I strongly encourage the continued use of BIP61, the reasoning to remove it was too weak in Bitcoin.

@PastaPastaPasta PastaPastaPasta requested a review from UdjinM6 April 16, 2020 15:20
@PastaPastaPasta PastaPastaPasta requested a review from UdjinM6 April 17, 2020 15:25
@UdjinM6
Copy link

UdjinM6 commented Apr 18, 2020

Needs rebase

@PastaPastaPasta
Copy link
Member Author

rebased on develop

laanwj and others added 5 commits April 18, 2020 16:37
…ing of BIP61 notifications

87fe292 doc: Mention disabling BIP61 in bips.md (Wladimir J. van der Laan)
fe16dd8 net: Add option `-enablebip61` to configure sending of BIP61 notifications (Wladimir J. van der Laan)

Pull request description:

  This commit adds a boolean option `-peersendreject`, defaulting to `1`, that can be used to disable the sending of [BIP61](https://github.com/bitcoin/bips/blob/master/bip-0061.mediawiki) `reject` messages. This functionality has been requested for various reasons:

  - security (DoS): reject messages can reveal internal state that can be used to target certain resources such as the mempool more easily.

  - bandwidth: a typical node sends lots of reject messages; this counts against upstream bandwidth. Also the reject messages tend to be larger than the message that was rejected.

  On the other hand, reject messages can be useful while developing client software (I found them indispensable while creating bitcoin-submittx), as well as for our own test cases, so whatever the default becomes on the long run, IMO the functionality should be retained as option. But that's a discussion for later, for now it's simply a node operator decision.

  Also adds a RPC test that checks the functionality.

Tree-SHA512: 9488cc53e13cd8e5c6f8eb472a44309572673405c1d1438c3488f627fae622c95e2198bde5ed7d29e56b948e2918bf1920239e9f865889f4c37c097c37a4d7a9
Signed-off-by: Pasta <[email protected]>
@PastaPastaPasta
Copy link
Member Author

rebased again to (hopefully) resolve tests

Copy link

@UdjinM6 UdjinM6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

@UdjinM6 UdjinM6 merged commit d804a75 into dashpay:develop Apr 19, 2020
@PastaPastaPasta PastaPastaPasta deleted the backport-13134 branch April 19, 2020 15:53
gades pushed a commit to cosanta/cosanta-core that referenced this pull request Feb 5, 2022
…ding of BIP61 notifications (dashpay#3414)

* Merge bitcoin#13134: net: Add option `-enablebip61` to configure sending of BIP61 notifications

87fe292 doc: Mention disabling BIP61 in bips.md (Wladimir J. van der Laan)
fe16dd8 net: Add option `-enablebip61` to configure sending of BIP61 notifications (Wladimir J. van der Laan)

Pull request description:

  This commit adds a boolean option `-peersendreject`, defaulting to `1`, that can be used to disable the sending of [BIP61](https://github.com/bitcoin/bips/blob/master/bip-0061.mediawiki) `reject` messages. This functionality has been requested for various reasons:

  - security (DoS): reject messages can reveal internal state that can be used to target certain resources such as the mempool more easily.

  - bandwidth: a typical node sends lots of reject messages; this counts against upstream bandwidth. Also the reject messages tend to be larger than the message that was rejected.

  On the other hand, reject messages can be useful while developing client software (I found them indispensable while creating bitcoin-submittx), as well as for our own test cases, so whatever the default becomes on the long run, IMO the functionality should be retained as option. But that's a discussion for later, for now it's simply a node operator decision.

  Also adds a RPC test that checks the functionality.

Tree-SHA512: 9488cc53e13cd8e5c6f8eb472a44309572673405c1d1438c3488f627fae622c95e2198bde5ed7d29e56b948e2918bf1920239e9f865889f4c37c097c37a4d7a9

* 0.17 -> 0.16

Signed-off-by: Pasta <[email protected]>

* tx1 -> base_ tx fixing 13134

Signed-off-by: Pasta <[email protected]>

* move added bip61 message checking up

Signed-off-by: Pasta <[email protected]>

* Dash specific code, only send reject messages if bip61 is enabled

Signed-off-by: Pasta <[email protected]>

* Fix invalidtxrequest.py

Co-authored-by: Wladimir J. van der Laan <[email protected]>
Co-authored-by: UdjinM6 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants