str4d
0540d4156b
Merge pull request #325 from str4d/example-diversify-address
...
zcash_client_backend: Add example to generate diversified addresses
2021-01-10 07:42:26 +13:00
Jack Grigg
258e3d31ad
zcash_client_backend: Add example to generate diversified addresses
2021-01-08 16:08:03 +00:00
str4d
04a2bd4ad8
Merge pull request #309 from nuttycom/test_utils
...
Make transaction builder more useful for testing.
2020-12-17 14:41:25 +00:00
Kris Nuttycombe
472dac7a22
Revert intra_doc_link_resolution_failure flag change.
2020-12-17 07:36:18 -07:00
Kris Nuttycombe
cf0c3ea90f
Relax RngCore type constraints.
...
The intent of this change is to permit tests to use deterministic
random sources, rather than cryptographically strong ones.
2020-12-14 13:44:05 -07:00
str4d
c289cf9d4b
Merge pull request #304 from nuttycom/zip_tze-cargo-feature-flag
...
Use rust feature flagging to allow conditionally enabling TZE-related code.
2020-12-14 15:23:58 +00:00
Kris Nuttycombe
c24f663e40
Use methods on sigversion to gate ZIP-243 and TZE signature parts.
2020-12-14 14:54:29 +00:00
Kris Nuttycombe
790071953c
Use rust feature flagging to allow conditionally enabling TZE-related code.
...
This also uses the test-dependencies feature flag for conditional
inclusion of proptest-related modules which may be used by
dependent crates for generation of samples in testing.
2020-12-14 14:54:12 +00:00
str4d
debd5e6f5c
Merge pull request #314 from daira/txid-hashing
...
zcash_primitives: hash the transaction as it is read, rather than hashing a re-serialization
2020-12-05 00:19:26 +00:00
Daira Hopwood
62675f4b4f
Use the SHA-256d HashReader and HashWriter for transaction hashing.
...
This hashes the transaction as it is read, rather than hashing a re-serialization.
Co-authored-by: Jack Grigg <str4d@electriccoin.co>
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-12-03 21:22:58 +00:00
Daira Hopwood
1f18da239f
Add HashReader and HashWriter for SHA-256d.
...
Co-authored-by: Jack Grigg <str4d@electriccoin.co>
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2020-12-03 21:22:58 +00:00
str4d
7ced7f3c56
Merge pull request #315 from gmale/zip-313-impl
...
ZIP 313 Implementation
2020-11-24 02:10:17 +00:00
Jack Grigg
936b399599
Fix remaining tests after default fee change
2020-11-24 01:50:47 +00:00
Kris Nuttycombe
1285ab0af2
Fix tests to account for modified default fees.
2020-11-24 01:24:19 +00:00
Kevin Gorham
53ebc378cc
ZIP-313 change default fee amount.
2020-11-24 01:22:14 +00:00
str4d
97ef1592bb
Merge pull request #316 from nuttycom/sighash_components
...
Make the functions which produce the components of the sighash reusable.
2020-11-19 22:21:41 +00:00
Kris Nuttycombe
f40174464a
Use slices as parameters rather than &Vec references.
...
Co-authored-by: str4d <thestr4d@gmail.com>
2020-11-19 14:49:24 -07:00
Kris Nuttycombe
517170652d
Use github environment file instead of (deprecated) set-env
2020-11-19 14:48:12 -07:00
Kris Nuttycombe
726f02513d
Make the functions which produce the components of the sighash reusable.
...
When implementing transaction nonmalleability, it will be useful
to have this already done.
2020-11-19 11:25:24 -07:00
ebfull
baab9d3ca3
Merge pull request #313 from str4d/delint
...
Remove a bunch of lint
2020-11-02 13:48:08 -07:00
Jack Grigg
00307c8059
Fix various small lints
2020-10-30 14:10:35 +00:00
Jack Grigg
be8bae71be
Suppress clippy lints where we want the given behaviour
2020-10-30 14:10:35 +00:00
Jack Grigg
91796adcda
Remove wrapping closures around mapping functions
2020-10-30 14:10:35 +00:00
Jack Grigg
025deda712
impl Default for T on types with T::new()
2020-10-30 14:10:35 +00:00
Jack Grigg
44cbc6cc6d
Remove unnecessary references
2020-10-30 14:10:35 +00:00
Jack Grigg
88474c71c7
Simplify expressions
2020-10-30 13:51:40 +00:00
Jack Grigg
01f0d7dcda
Pass slices instead of &Vec
2020-10-30 13:51:40 +00:00
Jack Grigg
0cb51f963c
Remove unnecessary clones
2020-10-30 13:51:40 +00:00
Jack Grigg
bc9ca20d56
Make use of assignment operators
2020-10-30 13:26:36 +00:00
Jack Grigg
890648df4d
Use !x.is_empty() instead of x.len() > 0
2020-10-30 13:25:08 +00:00
Jack Grigg
0bbcd8c408
Remove unnecessary imports
2020-10-30 13:22:46 +00:00
str4d
2a6955102a
Merge pull request #312 from adityapk00/pubconstants
...
Export notesize constants
2020-10-29 20:23:29 +00:00
ebfull
6f039a3069
Merge pull request #310 from str4d/update-ci
...
Update Actions CI with improved workflow
2020-10-27 13:52:37 -06:00
Jack Grigg
8593a067ca
Force Clippy nightly lints to all warn, never error
2020-10-27 17:20:00 +00:00
Aditya Kulkarni
70ecd6b2d8
Export notesize constants
2020-10-26 11:31:22 -07:00
str4d
ee15eea3ee
Merge pull request #311 from str4d/zcash_client_sqlite-0.2.1
...
zcash_client_sqlite: Read rcm correctly from data DB after Canopy
2020-10-24 12:37:32 +01:00
str4d
7176ff077c
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2020-10-24 12:05:15 +01:00
Jack Grigg
450d68f073
Merge branch 'master' into zcash_client_sqlite-0.2.1
2020-10-24 00:44:37 +01:00
Jack Grigg
74bf85641c
zcash_client_sqlite 0.2.1
2020-10-24 00:42:24 +01:00
Jack Grigg
524cc2e979
zcash_client_sqlite: Read rcm correctly from data DB after Canopy
...
ZIP 212 alters the note plaintext to store a seed from which rcm is
derived, rather than storing rcm directly. In the mobile SDKs we only
need rcm, so for post-ZIP 212 notes, we derive rcm from the seed and
store rcm in the data DB.
However, when selecting notes to spend, `create_to_address` was using the
transaction's target height to determine if Canopy is active, and parsing
the rcm value as the seed if so. This effectively applied a seed->rcm
derivation to all selected notes' rcms once Canopy activated on the
chain. As a result, the note commitments were incorrect, and thus the
anchors derived from the witness paths were also incorrect. This caused
two kinds of observed failures:
- If more than one note was selected, the builder would fail with
"anchor mismatch", as the note commitments would be effectively
randomised, causing the derived anchors to also randomise.
- If a single note was selected, the transaction would be built using
the randomised anchor, and then rejected when sent to the network.
The fix is to "pretend" in `create_to_address` that all notes are
pre-ZIP 212 notes. This works fine because we never need to serialize
back to the note plaintext while spending a note.
2020-10-24 00:23:05 +01:00
Jack Grigg
e6c2230afa
equihash: Silence clippy mis-lint
2020-10-23 17:38:24 +01:00
Jack Grigg
14aba4f5d1
Update Actions CI with improved workflow
2020-10-23 17:26:03 +01:00
Kris Nuttycombe
7d47582bc4
Merge pull request #303 from adityapk00/bytes_params
...
Build prover with byte arrays of params
2020-10-20 13:17:26 -06:00
adityapk00
b8aa2d9169
Build prover with byte arrays of params
2020-10-20 11:49:42 -07:00
str4d
4c66a17b93
Merge pull request #306 from str4d/script-address-simplification
...
zcash_primitives: Small simplification to Script::address
2020-10-18 14:50:51 +01:00
Jack Grigg
d657ff906e
zcash_primitives: Small simplification to Script::address
2020-10-18 13:17:16 +01:00
Kris Nuttycombe
b1c3f9d3f0
ZIP 321 Reference Implementation ( #294 )
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
Co-authored-by: Jack Grigg <jack@electriccoin.co>
2020-10-15 14:03:40 +01:00
Kris Nuttycombe
72b6de39eb
Merge pull request #286 from nuttycom/zip-tzes
...
Implementation for ZIP-222 Transparent Zcash Extensions
2020-10-13 14:56:44 -06:00
Kris Nuttycombe
eeb0c2b08a
Update comment in zcash_primitives/src/transaction/builder.rs
2020-10-13 14:28:54 -06:00
Kris Nuttycombe
536c77bea7
Fix formatting.
2020-10-13 07:12:33 -06:00