therealyingtong
119d721ecd
Use ArrayVec
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2021-05-03 23:58:41 +08:00
ying tong
1ee5392163
Documentation fixes
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2021-05-03 22:28:22 +08:00
Kris Nuttycombe
4afdeeeb76
Add mapping over bundle value balance.
2021-04-30 09:43:51 -06:00
Kris Nuttycombe
b1ac90b77a
Fix incorrect generator comments.
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2021-04-30 08:02:09 -06:00
Kris Nuttycombe
a119a27ee7
Clean up value balance generation.
2021-04-30 07:59:46 -06:00
Kris Nuttycombe
25c90dda4b
Add fast generation for not-consensus-valid authorized bundles and actions.
2021-04-29 16:14:16 -06:00
Kris Nuttycombe
3c12877f87
Use a deterministic PRNG seeded from arb data for proptests.
2021-04-29 09:55:11 -06:00
Kris Nuttycombe
f91088d35b
Use builder to generate "valid" bundles via proptest.
2021-04-28 18:21:12 -06:00
Kris Nuttycombe
4d89d45332
Add proptest generators for action and bundle types.
2021-04-28 18:04:17 -06:00
Kris Nuttycombe
75573d331a
Add canonical byte conversions for value commitments.
2021-04-28 18:03:50 -06:00
Kris Nuttycombe
fc0f55d82b
Make ValueSum correctly respect the proper specified range.
2021-04-28 18:03:50 -06:00
Kris Nuttycombe
a5c9fb953b
Add accessors necessary for zip-225 write.
2021-04-28 18:02:36 -06:00
Kris Nuttycombe
e743198a50
Expose constructors required for ZIP-225 parsing.
2021-04-28 18:02:36 -06:00
str4d
e8f65a2158
Merge pull request #49 from zcash/builder
...
Bundle builder
2021-04-29 00:03:26 +01:00
Jack Grigg
d383ff5054
Fix clippy lints
2021-04-29 10:57:53 +12:00
Jack Grigg
223b7ac533
Replace signing metadata tuple with struct
...
This enables the dummy-only first field to be properly documented.
2021-04-29 10:40:23 +12:00
therealyingtong
de75c9538b
Update constants after hash_to_field fix ( zcash/pasta_curves@a119467 )
2021-04-28 20:53:14 +08:00
therealyingtong
13d7da3c45
Replace OrchardFixedBases enum with newtypes
...
Co-authored-by: Kris Nuttycombe <kris@electriccoin.co>
2021-04-28 20:53:14 +08:00
therealyingtong
e26b6c6123
Test every row in test_lagrange_coeffs() instead of using random scalar
2021-04-28 20:53:14 +08:00
therealyingtong
ce6e59bdb8
Address review comments
2021-04-28 20:53:14 +08:00
therealyingtong
17b66e1c6a
Remember u-values
2021-04-28 20:53:14 +08:00
therealyingtong
69d4c4c35a
Round up division for NUM_WINDOWS
2021-04-28 20:53:14 +08:00
therealyingtong
70ce1ca53f
Impl PartialOrd and Ord for OrchardFixedBases
2021-04-28 20:53:14 +08:00
therealyingtong
21060393fe
Remove redundant imports
2021-04-28 20:53:14 +08:00
therealyingtong
6cc957e998
Add constants for short signed scalar mul
2021-04-28 20:53:14 +08:00
therealyingtong
137ebf4a5a
Add rand crate to dependencies
2021-04-28 20:53:14 +08:00
therealyingtong
e4d6af620f
Add l_value to constants
2021-04-28 20:53:14 +08:00
therealyingtong
3381b15cd9
Use fixed-size array for windows in tables
...
Co-authored-by: Jack Grigg <jack@electriccoin.co>
2021-04-28 20:53:14 +08:00
therealyingtong
d915097407
Implement Hash, PartialEq, Eq for OrchardFixedBases
2021-04-28 20:53:14 +08:00
therealyingtong
2c11f3a048
Add Orchard fixed bases and tests
2021-04-28 20:53:14 +08:00
therealyingtong
4f1f32dab0
Add Sinsemilla constants
2021-04-28 20:53:14 +08:00
therealyingtong
91fd290ffc
Add SWU hash-to-curve personalizations
2021-04-28 20:53:14 +08:00
Jack Grigg
374391b217
Bring in reddsa fix that re-enables tests in debug mode
2021-04-28 14:19:58 +12:00
Jack Grigg
186914166a
Use `zero` instead of `default` for empty values
2021-04-28 09:06:33 +12:00
Kris Nuttycombe
575f882b40
Merge pull request #72 from zcash/builder-prep
...
Builder preparations
2021-04-27 07:51:04 -06:00
Jack Grigg
6d4ceb989f
Fix CI to run builder tests successfully
...
Now that the tests include real prover logic, we need to run them in
release mode.
2021-04-27 14:31:21 +12:00
Jack Grigg
30f01d122c
Bundle builder
2021-04-27 14:31:21 +12:00
Jack Grigg
497f7e0b86
Remove bundle::Unauthorized type
...
It is being replaced by context-specific unauthorized or
partially-authorized types. The only general type we need is Authorized
which is used in transactions.
2021-04-27 12:30:16 +12:00
Jack Grigg
316729302d
cargo fmt
2021-04-27 12:28:42 +12:00
Jack Grigg
a60051c8a2
Add from_raw constructors to NoteValue and ValueSum
...
These might be replaced later with APIs that can provide more useful
bounds checks, but we do need some way to construct these types.
2021-04-27 12:27:23 +12:00
Jack Grigg
52d87e257c
Return SpendingKey from Note::dummy
...
We need the spending keys to create valid spendAuth signatures for
Actions containing dummy spent notes.
2021-04-27 12:26:24 +12:00
Jack Grigg
5ec65c5d2a
Add a mutable context to Bundle::{try_}authorize
...
This enables us to work around lifetime restrictions on e.g. the
randomness source at signing time, where it is needed for both
per-Action and Bundle-level signatures.
2021-04-27 12:24:33 +12:00
Steven
5f4a56dc92
Merge pull request #61 from steven-ecc/change-tgppl-to-bosl
...
Adding BOSL and changing TGPPL references to BOSL
2021-04-26 16:42:00 -07:00
Steven
43d1bac11d
Update Cargo.toml
...
Co-authored-by: ebfull <ewillbefull@gmail.com>
2021-04-26 16:41:14 -07:00
Jack Grigg
29b3071c67
Fix doc comments for bundle flags
2021-04-27 09:10:32 +12:00
Kris Nuttycombe
36529629bc
Expose Flags constructor & accessors.
2021-04-27 09:04:03 +12:00
str4d
3dbebbe08b
Merge pull request #58 from zcash/proof-placeholder
...
Proving and verifying keys, and placeholder proof logic
2021-04-26 19:11:56 +01:00
str4d
0f6794f291
Merge pull request #70 from zcash/bundle-apis
...
Bundle APIs
2021-04-22 21:23:14 +01:00
Kris Nuttycombe
7d243ae60a
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2021-04-22 07:32:20 -06:00
Jack Grigg
4c4400cb63
Proving and verifying keys, and placeholder proof logic
2021-04-23 01:08:43 +12:00