Page MenuHomePhabricator

Do not check for non replay protected transaction in CheckInputs
ClosedPublic

Authored by deadalnix on Aug 8 2017, 00:25.

Details

Summary

Now that we do replay protected txns only, this can go.

Test Plan
make check
../qa/pull-tester/rpc-tests.py

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I tested this on a real bitcoin server on mainnet I'm getting BUCash nodes getting banned with the non-mandatory-script-verify-flag message.

I am not sure this is what we want.. is it?

UPDATE: ban/misbehaving thing happens 100% of the time on BUCash peers:
2017-08-08 17:18:37 Warning: not punishing addnoded peer 174.4.126.223:8333!
2017-08-08 17:18:40 Misbehaving: 174.4.126.223:8333 peer=17 (100 -> 200) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)
2017-08-08 17:18:42 Misbehaving: 174.4.126.223:8333 peer=17 (200 -> 300) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)
2017-08-08 17:18:43 Misbehaving: 174.4.126.223:8333 peer=17 (300 -> 400) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)
2017-08-08 17:18:53 Misbehaving: 174.4.126.223:8333 peer=17 (400 -> 500) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)
2017-08-08 17:18:57 Misbehaving: 174.4.126.223:8333 peer=17 (500 -> 600) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)
2017-08-08 17:18:57 Misbehaving: 174.4.126.223:8333 peer=17 (600 -> 700) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)
2017-08-08 17:18:57 Misbehaving: 174.4.126.223:8333 peer=17 (700 -> 800) reason: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID)

@CCulianu Good, that's non cash node which forwards you transaction that are invalid on the cash chain. We should ban them.

A ban is a big thing. Why not be tolerant for a month or two more to avoid risking a network split?

In D442#7735, @thezerg wrote:

A ban is a big thing. Why not be tolerant for a month or two more to avoid risking a network split?

I agree with this sentiment. If anything it may look bad if our cash nodes keep banning BUCash -- even if it isn't our fault that they send us bad tx's. I can see the troll brigade FUDing that to death, even though they do the same thing now against SegWit2x...

Ok, after talking to deadalnix about it, he convinced me the netsplit risk isn't so large and that we want to be strict about tx format -- so rejecting the TX (which leads to a ban) is what we're going to do.

I will approve to merge this in now, but we will coordinate our release to come after BUCash, and we will be careful to inform users in forums etc to upgrade BUCash and/or to anticipate newer ABC nodes possibly banning early-version BUCash nodes (so they don't panic and about it).

This revision is now accepted and ready to land.Aug 9 2017, 18:17
This revision was automatically updated to reflect the committed changes.