Michael Toutonghi
c1e7194760
fix coinbase spend after 10080 & seg fault
2018-05-25 21:52:53 -07:00
Michael Toutonghi
b0e452de2a
fix build for update
2018-05-25 20:15:38 -07:00
Michael Toutonghi
6c8e1cdfb7
Restore zcash coinbase rule and launch fix at 10080
2018-05-25 15:10:07 -07:00
jl777
de8834fb9b
Merge branch 'beta' into dev
2018-05-23 15:18:21 +03:00
Michael Toutonghi
ec872d3a55
Do not resurrect staking transactions and lose stake age when no block won
2018-05-22 15:53:56 -07:00
Michael Toutonghi
dbe656fe39
Significant mining optimization and POS DAA modification
2018-05-19 18:34:46 -07:00
Michael Toutonghi
f6608b5a0d
cleanup
2018-05-17 22:58:30 -07:00
Michael Toutonghi
c2923066b2
new CNetworkBlockHeader for robust compat
2018-05-17 00:04:10 -07:00
Michael Toutonghi
e96e4e61aa
checking properly typed header transfer
2018-05-16 16:29:39 -07:00
Michael Toutonghi
10a01059e5
Attempt to match types in socket communication to prevent misalinged send/receive
2018-05-16 15:06:10 -07:00
Michael Toutonghi
fbe86cecfa
more debugging checks
2018-05-16 14:39:00 -07:00
Homu
f62fff80d5
Auto merge of #3255 - str4d:sapling-value-pool, r=ebfull
...
Track net value entering and exiting the Sapling circuit
2018-05-16 10:46:32 -07:00
Eirik Ogilvie-Wigley
3182b4abc3
Add tests for sapling anchors
2018-05-16 10:31:53 -06:00
Michael Toutonghi
cdcebd3618
more cast
2018-05-16 07:24:19 -07:00
Michael Toutonghi
e5a4e868bf
cast
2018-05-16 07:21:28 -07:00
Michael Toutonghi
01ff13ceb7
printf for testing on server
2018-05-16 07:18:54 -07:00
Michael Toutonghi
d942c58d4a
revert testing changes back to original
2018-05-16 06:10:45 -07:00
Michael Toutonghi
cc19c3b08d
finish testing change
2018-05-16 05:56:54 -07:00
Michael Toutonghi
351bbd2eae
more testing
2018-05-16 05:50:57 -07:00
Michael Toutonghi
c132b91a01
More testing for header transfers
2018-05-16 05:29:49 -07:00
Michael Toutonghi
004e332290
Additional tests
2018-05-16 01:59:23 -07:00
Michael Toutonghi
52670b7205
going back to the original type mismatch - still debugging forking issue, checkin to try on other machines
2018-05-16 00:23:55 -07:00
Michael Toutonghi
3da69a3138
Trying to fix the forking issue, which is now clearly a bug in sending and receiving headers. This checkin will enable debugging and may be a fix.
2018-05-15 22:19:07 -07:00
Michael Toutonghi
3d3a117bde
Fix forking potential at startup
2018-05-15 05:00:00 -07:00
Alex Morcos
bbff8631f5
Output line to debug.log when IsInitialBlockDownload latches to false
2018-05-15 22:18:11 +12:00
Gregory Maxwell
f04a90afb2
IsInitialBlockDownload no longer uses header-only timestamps.
...
This avoids a corner case (mostly visible on testnet) where bogus
headers can keep nodes in IsInitialBlockDownload.
2018-05-15 22:18:04 +12:00
Gregory Maxwell
e41632c9fb
IBD check uses minimumchain work instead of checkpoints.
...
This introduces a 'minimum chain work' chainparam which is intended
to be the known amount of work in the chain for the network at the
time of software release. If you don't have this much work, you're
not yet caught up.
This is used instead of the count of blocks test from checkpoints.
This criteria is trivial to keep updated as there is no element of
subjectivity, trust, or position dependence to it. It is also a more
reliable metric of sync status than a block count.
2018-05-15 21:25:19 +12:00
Kaz Wesley
02eedeeb69
IsInitialBlockDownload: usually avoid locking
...
Optimistically test the latch bool before taking the lock.
For all IsInitialBlockDownload calls after the first to return false,
this avoids the need to lock cs_main.
2018-05-15 21:25:19 +12:00
Wladimir J. van der Laan
29aaf13b0a
Make max tip age an option instead of chainparam
...
After discussion in #7164 I think this is better.
Max tip age was introduced in #5987 to make it possible to run
testnet-in-a-box. But associating this behavior with the testnet chain
is wrong conceptually, as it is not needed in normal usage.
Should aim to make testnet test the software as-is.
Replace it with a (debug) option `-maxtipage`, which can be
specified only in the specific case.
2018-05-15 21:24:58 +12:00
Michael Toutonghi
7702587db8
Fix too aggressive check for coinbase amount
2018-05-13 23:34:34 -07:00
Michael Toutonghi
1f722359c1
Verus Proof of Stake Compete with Additional ant-fork protection on block 1
2018-05-13 18:59:06 -07:00
Homu
ae6c2587d3
Auto merge of #3232 - ebfull:3207-sapling-validation, r=str4d
...
Sapling validation
**Also review https://github.com/zcash/librustzcash/pull/7 **
This is an attempt to tackle much of https://github.com/zcash/zcash/issues/3065
2018-05-10 10:21:15 -07:00
Jack Grigg
ae97177c86
Track net value entering and exiting the Sapling circuit
2018-05-09 16:02:23 -04:00
Scott Sadler
20c3ac51c2
wip
2018-05-09 16:17:28 -03:00
Jack Grigg
97b46f00cc
Add valueBalance to value balances, and enforce its consensus rules
2018-05-09 11:34:41 +01:00
miketout
fb99540b9d
Merge pull request #6 from jl777/dev
...
Merge jl777 changes
2018-05-09 00:53:49 -07:00
jl777
b9b415654f
Restore possibility of negative timestamps for PoS
2018-05-09 09:36:27 +03:00
miketout
32d8c6d015
Merge latest from Komodo, including POS
2018-05-08 17:57:03 -07:00
Sean Bowe
b4db32f53c
Check Sapling Spend/Output proofs and signatures.
2018-05-08 14:30:26 -06:00
Sean Bowe
55fabd8272
Refactor so that dataToBeSigned can be used later in the function for other purposes.
2018-05-08 14:28:01 -06:00
Sean Bowe
6eea48bf96
Remove unnecessary IsCoinbase() check. Coinbases are guaranteed to have empty vjoinsplit.
2018-05-08 14:23:09 -06:00
Homu
333b9a0d0b
Auto merge of #3170 - ebfull:sapling-merkle-tree, r=ebfull
...
Sapling merkle tree implementation
Closes #3056 .
Please also review https://github.com/zcash/librustzcash/pull/8
This PR:
1. Introduces ZCSaplingIncrementalMerkleTree using Pedersen hashes.
2. Adds support for Sapling anchors into consensus rules. (Adds commitments, checks anchors are correct, handles block (dis)connects, etc.)
3. Handles mempool eviction for obsolete anchors.
4. Enforces correctness of block's Sapling root field
5. Changes miner to correctly apply the Sapling root to the block header
6. Handles mempool consistency checks for anchors
2018-05-07 20:37:46 -07:00
Sean Bowe
98d2f090ca
Evict transactions with obsolete anchors from the mempool
2018-05-07 14:37:46 -06:00
Sean Bowe
1f8be05b63
Add consensus support for Sapling merkle trees.
2018-05-07 14:37:46 -06:00
Sean Bowe
c643ff0b51
Add support for PopAnchor(.., SPROUT/SAPLING)
2018-05-07 14:37:46 -06:00
Sean Bowe
e814be60fe
Rename hashSproutAnchorEnd to hashFinalSproutRoot to be consistent.
2018-05-07 14:37:46 -06:00
Sean Bowe
18322f074c
Introduce support for GetBestAnchor(SAPLING).
2018-05-07 13:46:06 -06:00
Sean Bowe
2bd59e1473
Rename PushAnchor to PushSproutAnchor.
2018-05-07 13:46:06 -06:00
Sean Bowe
008f4ee8e7
Rename GetAnchorAt to GetSproutAnchorAt.
2018-05-07 13:46:06 -06:00
Sean Bowe
08f0728884
Rename hashAnchor to hashSproutAnchor.
2018-05-07 13:46:06 -06:00