Commit Graph

8758 Commits

Author SHA1 Message Date
zkbot
87485d5ff3 Auto merge of #907 - DoNotUseThisCodeJUSTFORKS:t844-rename-bitcoin-conf, r=defuse
Rename bitcoin.conf and bitcoind.pid

This leaves the mentions of those files in `doc/` and `contrib/` unchanged.

**FORCE PUSHED**
2016-05-04 00:55:10 +00:00
Nathan Wilcox
b6aa043d1f Add googlemock 1.7.0 dependency. 2016-05-03 13:46:09 -07:00
Taylor Hornby
aaf6495948 Rename bitcoin.conf and bitcoind.pid to zcash.conf and zcashd.pid in qa/ and src/ 2016-05-03 14:01:01 -06:00
zkbot
92f3c6082a Auto merge of #889 - ebfull:new-imt-redux, r=ebfull
Implement and integrate new Incremental Merkle Tree

This supersedes #823.

----

This is an implementation of a new incremental merkle tree with

* no memory safety issues
* a more sensible internal design
* better space efficiency (tree representation, witnessing)
* simpler API

It is intended that this tracks the behavior of the previous tree, which it does, as verified by tests. I even wrote a little circuit for testing that all the paths work.

This PR also integrates the tree into the codebase and deprecates the old tree in almost all of our code. (I left it alone in `zerocashTest` but everything else has been changed.)

This change is compatible with the testnet but you will need to clear your *local* blockchain data out since the serialized representation of the merkle tree is now different.

Closes #517, Closes #519, Closes #591, Closes #460, Closes #473
2016-05-03 17:33:27 +00:00
Sean Bowe
26007222e8 Distinguish the failure cases of wfcheck in tree. 2016-05-03 11:23:54 -06:00
Sean Bowe
6f1b70300d Small nit fixes 2016-04-30 11:59:39 -06:00
Sean Bowe
4b2c67d212 Check exception has specific string message. 2016-04-28 19:35:22 -06:00
Sean Bowe
70ac6ce2ee Clarify the usage of decryption API. 2016-04-28 17:06:08 -06:00
Sean Bowe
984bdd88f1 Add additional tests for ephemeral key behavior. 2016-04-28 16:52:22 -06:00
Sean Bowe
57f118176f Move NoteEncryption tests to gtest suite. 2016-04-28 16:25:14 -06:00
Sean Bowe
6c36a9fe03 NoteEncryption implementation and integration, removal of ECIES and crypto++ dependencies. 2016-04-28 16:25:12 -06:00
Sean Bowe
6850b45e4d Move incremental merkle tree tests to zcash-gtest. 2016-04-28 16:10:21 -06:00
Sean Bowe
9b92a9d5fb Make appending algorithm more succinct. 2016-04-28 16:07:52 -06:00
Sean Bowe
d0c4b0e850 Add more well-formedness checks/tests to tree. 2016-04-28 16:07:52 -06:00
Sean Bowe
01e4ff0f74 Improve well-formedness checks and add additional serialization/deserialization tests. 2016-04-28 16:07:52 -06:00
Sean Bowe
6d71658673 Initialize curve/field parameters in case another test hasn't done so. 2016-04-28 16:07:52 -06:00
Sean Bowe
1760b3cd88 Deprecate the old tree and remove old tree tests from the test suite. 2016-04-28 16:07:52 -06:00
Sean Bowe
482aefbd0d Test old tree along with new tree as much as possible. 2016-04-28 16:07:52 -06:00
Sean Bowe
434f328446 Integrate new incremental merkle tree implementation into consensus. 2016-04-28 16:07:52 -06:00
Sean Bowe
e1ff849d8d New implementation of incremental merkle tree
This is a new implementation of the incremental merkle tree used by our
scheme to witness commitments to spendable value. It serves as a fixed-sized
accumulator.

This new construction has a much simpler API surface area, avoids memory
safety issues, remains pruned at all times, avoids serialization edge cases,
has more efficient insertion, and is abstract over the depth and hash
function used at the type level.

Further, it lays the groundwork for efficient "fast-forwarding" of witnesses
into the tree as the treestate is updated.
2016-04-28 16:07:52 -06:00
Sean Bowe
291b191bd7 Add serialization for primitive boost::optional<T>. 2016-04-28 16:07:52 -06:00
Taylor Hornby
b2cf9ba300 Fix RPC tests 2016-04-28 13:35:47 -06:00
Taylor Hornby
0000d23121 Add empty merkle/noteencryption tests so Sean can rebase. 2016-04-28 10:10:40 -06:00
Taylor Hornby
3098bab6d6 Fix sighash tests 2016-04-28 09:44:12 -06:00
Taylor Hornby
6ad4db2253 Add check that vpubs are not both nonzero and test it. 2016-04-27 14:12:30 -06:00
Nathan Wilcox
d16d5ef832 Add coverage support scoped to only the zcash-gtest run; invoke with make zcash-cov; make cov is a superset. 2016-04-18 11:15:34 -07:00
Nathan Wilcox
3ab0c1a790 Add a zcash-gtest binary to our build with a single tautological test. 2016-04-18 11:14:30 -07:00
Nathan Wilcox
0ee1d5d133 Add a depends description for googletest. 2016-04-18 11:13:05 -07:00
zkbot
94f0dcddb4 Auto merge of #873 - nathan-at-least:t832-zc2-release, r=nathan-at-least
Update release process docs; release notes; clean up ./docs directory a bit.

closes #834
2016-04-13 00:12:35 +00:00
Nathan Wilcox
525a3b9223 Rewrite release-process.md and follow the example to generate a changelog-style release-notes file. 2016-04-12 16:54:43 -07:00
Nathan Wilcox
fb537854ff Update a bunch of docs by adding a banner, delete a bunch of known bitrot docs; does not update release-process.md. 2016-04-12 16:40:30 -07:00
Jack Grigg
7213c0b158 Fix Equihash state initialisation in miner
After a new block is found or after a few nonces have been tried (currently
after every nonce), the miner checks for global changes. If any of these are
triggered, a new block is built from scratch, which re-initialises the Equihash
input. But if none of the checks are triggered, the miner just updates nTime and
continues mining - without updating the Equihash input to account for the new
block header. This bugfix corrects the behaviour by regenerating the Equihash
input in both situations.
2016-04-12 15:23:44 +12:00
zkbot
f2e157ab25 Auto merge of #846 - DoNotUseThisCodeJUSTFORKS:automated-performance-measurement-zcash-cli-method, r=ebfull
Automated performance measurement

Supersedes #843 because that one would have merged into the wrong branch. (Oh yeah and I rebased).

**REBASED AND FORCE PUSHED**
2016-04-11 21:56:12 +00:00
zkbot
4d322a4497 Auto merge of #831 - ebfull:foundersreward, r=nathan-at-least
Implement Founders' Reward

More info:  https://z.cash/blog/funding.html

The consensus rule is as follows:

```
All blocks before the first subsidy halving block, with the exception of
the genesis block, must contain an output which sends 20% of the block
subsidy value to a scriptPubKey `FOUNDERS_REWARD_SCRIPT`.
```

Right now, `FOUNDERS_REWARD_SCRIPT` is a 2-of-3 multisig P2SH.

Closes #125
2016-04-11 19:21:41 +00:00
Sean Bowe
62fdd8d094 Change pchMessageStart for new testnet. 2016-04-11 12:46:46 -06:00
Sean Bowe
6ca317e1cc Fix remaining RPC tests. 2016-04-11 12:46:46 -06:00
Taylor Hornby
722b0117d0 Benchmark a random equihash input. 2016-04-11 11:51:12 -06:00
Taylor Hornby
36b1269bc3 Make benchmark specified by command-line arguments 2016-04-11 10:54:55 -06:00
Taylor Hornby
51c8c56b4a Use a separate datadir for the benchmarks 2016-04-11 10:20:42 -06:00
Taylor Hornby
a0be8e262a Don't leave massif.out lying around after the benchmarks 2016-04-11 10:05:16 -06:00
Taylor Hornby
a1cd1a27ac Add verify equihash benchmark 2016-04-11 10:03:31 -06:00
Taylor Hornby
d44feea44c Add JoinSplit verification benchmarks 2016-04-11 10:03:17 -06:00
Taylor Hornby
bf8def9749 Add equihash solving benchmarks 2016-04-11 10:02:59 -06:00
Taylor Hornby
6962bb3df0 Add automated performance measurement system. 2016-04-11 08:15:25 -06:00
Daira Hopwood
c34d662f10 Specify Sean as the second contact for conduct issues.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-04-10 21:48:06 +01:00
Daira Hopwood
680550f883 Merge pull request #817 from daira/zc.v0.11.2.ticket802.code-of-conduct.0
Add Code of Conduct. fixes #802
2016-04-10 21:31:00 +01:00
Nathan Wilcox
ad56edf7d4 Fix (most) rpc tests by updating balances. zcpour, zcpourdoublespend, and txn_doublespend currently fail. 2016-04-08 18:05:51 -07:00
Nathan Wilcox
349a7b3714 Apply a patch from Sean to update wallet to use our new founders-reward aware balances. 2016-04-08 16:27:27 -07:00
Nathan Wilcox
4259e1e3dd Log all failing rpc tests concisely. 2016-04-08 14:50:52 -07:00
Sean Bowe
f3ffa3d27f Implementation of Founders' Reward.
All blocks before the first subsidy halving block, with the exception of
the genesis block, must contain an output which sends 20% of the block
subsidy value to a scriptPubKey `FOUNDERS_REWARD_SCRIPT`.
2016-04-08 14:40:28 -06:00