Gregory Sanders
ecdefc5cb0
Remove script/standard dependence of ContextualCheckDynaFedHeader
2019-09-05 10:51:09 -04:00
Gregory Sanders
6000752a92
Enforce PAK checks on dynafed proposals
2019-09-05 10:51:09 -04:00
Gregory Sanders
a3cf151de1
fixup proposal checks
2019-09-05 10:51:09 -04:00
Gregory Sanders
d7faffdca6
Add dynafed proposal restrictions
2019-09-05 10:51:09 -04:00
Gregory Sanders
d9387cb5d5
Remove misleading comment for ContextualCheckDynaFedHeader use
2019-09-05 10:51:09 -04:00
Gregory Sanders
bd11097cec
Add fedpeg_program field in dynafed header
2019-09-05 10:51:09 -04:00
Gregory Sanders
dddc040aa0
s/m_dyna_params/m_dynafed_params/
2019-09-05 10:51:09 -04:00
Gregory Sanders
15996384d4
s/ConsensusParamEntry/DynaFedParamEntry/
2019-09-05 10:51:09 -04:00
Gregory Sanders
0fd39edf54
s/d_params/dynafed_params/
2019-09-05 10:51:09 -04:00
Gregory Sanders
055514b688
Have removeForBlock boot transactions when required
2019-09-03 10:55:29 -04:00
Gregory Sanders
525b24cf5c
Expose fedpeg fetching to consensus and mempool internals
2019-09-03 10:55:29 -04:00
Gregory Sanders
5d281e7e68
ContextualCheckBlockHeader: dynafed doesn't call CheckChallenge
2019-09-03 10:55:06 -04:00
Gregory Sanders
9fe43cdf86
Introduce contextual block checks for dynafed
2019-09-03 10:55:06 -04:00
Gregory Sanders
3605505c94
Enable pak enforcement at mempool/block level when appropriate
2019-09-03 10:55:06 -04:00
Gregory Sanders
804cd9f75f
Update PAK internals, helper functions
2019-09-03 10:55:06 -04:00
Gregory Sanders
918896d6ff
Add inactive versionbits dynafed deployment
2019-09-03 10:55:06 -04:00
Gregory Sanders
0a8565bbf8
ReadBlockFromDisk: do genesis block check before block proof check
2019-09-03 10:55:06 -04:00
Gregory Sanders
8838e76753
Do non-depth check for peg-in witness where possible
2019-06-13 10:56:54 -04:00
Steven Roose
619b438dab
Merge branch 'master' into catchup
2019-05-29 14:17:08 +01:00
Steven Roose
de81c0d97e
MERGE-FIX: Fix linter (mostly RPC help)
...
I also moved some RPC methods that were not at the end of the file with
the other ELEMENTS RPC methods. This makes the diff on my machine look
crazy. Let's hope GitHub has more intelligent diffs..
2019-05-27 17:40:16 +01:00
Gregory Sanders
8591de929e
kill useless mapPeginsSpentToTxid
2019-05-20 13:57:56 -04:00
Steven Roose
f4889a5253
UPSTREAM MERGE BROKEN: Merge upstream commit ' 519b0bc5dc' into master
2019-05-17 16:17:09 +01:00
Steven Roose
dc900eb7d7
Merge branch 'master' into catchup
2019-05-14 16:49:18 +01:00
Gregory Sanders
63bc3e3f02
Merge #614 : Improve double pegin claim behavior
...
52ef283 Improve the fedpeg test with extra double claim tests (Steven Roose)
48a82fa Make claimpegin fail in the case of a double claim (Steven Roose)
af22646 Prevent pegin double spends from entering the mempool (Steven Roose)
50c5570 Report IsValidPeginWitness error message (Steven Roose)
Pull request description:
Fixes #612 and #613 .
- prevents a double claim from entering mempool
- makes `claimpegin` throw an exception when trying to double claim a pegin
- check the last commit message on all the extra cases that are tested.
Tree-SHA512: dd9602cd4bc78a3e8f7a6b566f881ede09dba54900425348c1eb528268a3e869416e3c9ca97c1a8da4d120875ef59c4e21a857256312ce77e06b7b6ae04abf92
2019-05-08 11:10:58 -04:00
Steven Roose
af2264665e
Prevent pegin double spends from entering the mempool
...
This bug got introduced with the 0.17 rebase. In 0.14.1 the double pegin
claim check was done in the beginning of the validation logic, where the
coins view was the actual UTXO set. In 0.17, Core moved several checks
because the intermediate method CheckInputs was removed and some logic
moved to tx_verify.cpp, where we also put the pegin check. In the
mempool acceptance check, however (as opposed to the ConnectBlock
check), CheckTxInputs is called with only a partial UTXO view for
optimization reasons. This commit adds an extra pegin check in the
beginning of the mempool code where we have a full UTXO view.
2019-05-08 15:34:55 +01:00
Gregory Sanders
ad43f9c60f
Only spin-wait MainchainRPCCheck on initial loading with warmup code
2019-05-06 09:39:29 -04:00
Steven Roose
7f894ae00b
UPSTREAM MERGE BROKEN: Merge commit ' f617e05c38' into master
2019-05-01 19:18:18 +01:00
Gregory Sanders
789d4b97f7
Disallow output witness data in coinbase transactions
2019-04-12 11:50:01 -04:00
Gregory Sanders
8140a87dec
Reject unneeded pegin witness by policy
2019-04-12 11:50:01 -04:00
Steven Roose
ade539cbb4
Don't assume mainchain is Bitcoin
2019-03-21 19:30:52 +00:00
Steven Roose
aba54b3f92
Make validatepegin default to true if has parent chain
2019-03-21 17:55:02 +00:00
Gregory Sanders
4ea4401e93
Merge #516 : [0.17] Fix progress reporting issue
...
5b8c79a Fix progress reporting issue (Steven Roose)
Pull request description:
Based on https://github.com/ElementsProject/elements/pull/515
Reimplementation of https://github.com/Blockstream/liquid/pull/6
Tree-SHA512: 292be614802d0ca74bc9a19080bce46812bc4d5c386ed01f87e74898830946276359100d404868dda8fd4b4087699a9be804370a8ad387c7d92f4a3f5572d0b0
2019-03-21 08:09:25 -04:00
Steven Roose
5b8c79ac9d
Fix progress reporting issue
...
Reimplementation of https://github.com/Blockstream/liquid/pull/6
2019-03-21 11:01:16 +00:00
Sjors Provoost
a657da02a7
Validation: stop logging fake pow data
2019-03-20 23:05:15 +00:00
Steven Roose
0b5066143d
[BROKEN] Add CA validation
2019-03-20 12:05:46 +00:00
Pieter Wuille
519b0bc5dc
Make last disconnected block BLOCK_FAILED_VALID, even when aborted
2019-03-03 13:01:26 -08:00
Pieter Wuille
8d220417cd
Optimization: don't add txn back to mempool after 10 invalidates
2019-02-28 14:12:26 -08:00
Pieter Wuille
9ce9c37004
Prevent callback overruns in InvalidateBlock and RewindBlockIndex
2019-02-28 14:12:26 -08:00
Pieter Wuille
9bb32eb571
Release cs_main during InvalidateBlock iterations
2019-02-28 14:12:22 -08:00
Pieter Wuille
9b1ff5c742
Call InvalidateBlock without cs_main held
2019-02-24 18:55:21 -08:00
Pieter Wuille
241b2c74ac
Make RewindBlockIndex interruptible
2019-02-24 18:55:21 -08:00
Pieter Wuille
436f7d735f
Release cs_main during RewindBlockIndex operation
2019-02-24 18:55:17 -08:00
Pieter Wuille
1d342875c2
Merge the disconnection and erasing loops in RewindBlockIndex
2019-02-24 18:41:13 -08:00
Pieter Wuille
32b2696ab4
Move erasure of non-active blocks to a separate loop in RewindBlockIndex
...
This lets us simplify the iteration to just walking back in the chain,
rather than looping over all of mapBlockIndex.
2019-02-24 12:45:48 -08:00
Pieter Wuille
9d6dcc52c6
Abstract EraseBlockData out of RewindBlockIndex
...
Note that the former 'else' branch in RewindBlockIndex is now
dealt with more naturally inside the EraseBlockData call (by
checking whether the parent needs to be re-added as candidate
after deleting a child).
2019-02-24 12:38:23 -08:00
Steven Roose
fb72ee8fc8
Add Elements-style witness serialization
2019-02-13 11:42:38 +00:00
Julian Fleischer
5039e4b61b
Remove unnecessary const_cast
...
Signed-off-by: Julian Fleischer <julian@thirdhash.com>
2019-02-12 22:25:47 +01:00
practicalswift
fa2a69fcb9
doc: Add cs_main lock annotations for mapBlockIndex
2019-02-01 15:32:16 -05:00
Gregory Sanders
a36ee6c0ed
MERGE FIX: Augment IsValidPeginWitness with err string return
2019-01-31 10:55:34 +00:00
Gregory Sanders
4f4fe8f6c7
MERGE FIX: ConnectTip: ub fix for bench
2019-01-31 10:55:16 +00:00