Kris Nuttycombe
082c8de59c
Add kdf_personalized to OrchardDomain
2023-06-16 17:30:32 -06:00
Daira Hopwood
786d285987
Fix a clippy lint.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-10-18 19:17:15 +01:00
Daira Hopwood
b988d4c275
Fix comment that incorrectly referred to Sapling when Orchard was meant
2022-10-18 02:45:24 +01:00
Jack Grigg
050b2f231e
Add `memuse::DynamicUsage` impls for types used for batch scanning
2022-10-15 23:29:06 +00:00
Jack Grigg
0b4d7bc9c6
Migrate note encryption to use prepared w-NAF APIs
2022-10-15 23:27:57 +00:00
Hazel OHearn
0800d23fe7
Publicize diversifier method of Address, fix comments, etc
2022-09-15 14:40:21 -03:00
Hazel OHearn
45bcc16f80
Publicize necessary functionality for reading diversifiers and notes from data
2022-07-05 14:55:44 -03:00
Jack Grigg
6d6832f3f1
Fix clippy lints
2022-05-06 19:33:10 +00:00
Jack Grigg
30f9452743
Replace unnecessary usage of `std::io`
2022-04-28 20:45:05 +00:00
Jack Grigg
b1ce38405a
Use `core` instead of `std` where possible
2022-04-28 20:20:23 +00:00
Jack Grigg
4574d4793a
Migrate to 2021 edition
2022-04-28 17:23:30 +00:00
Daira Hopwood
3b52b2abec
Minor cleanup found while performing review for zcash/zcash#5024
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-04-14 08:29:00 -06:00
therealyingtong
eaa0cfdbf6
Check that the internal IVK can be derived from a spending key
...
Co-authored-by: Jack Grigg <jack@electriccoin.co>
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-03-30 20:49:38 +08:00
therealyingtong
e550c3d536
Check IVK derivations during FullViewingKey::from_bytes.
...
Closes zcash/orchard#303
Co-authored-by: Jack Grigg <jack@electriccoin.co>
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-03-30 20:49:38 +08:00
therealyingtong
a0424984c6
Add explicit scoping for viewing keys and addresses
...
Co-authored-by: Jack Grigg <jack@electriccoin.co>
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-03-30 20:49:37 +08:00
Jack Grigg
72b6febf7b
Move zero-handling from inside CommitIVK to outside it
...
This more closely matches the change to the protocol spec.
2022-03-17 18:51:33 +00:00
Jack Grigg
eb7a9668aa
Merge branch 'non-consensus-changes-on-branchid-c4cd541e' into merge-non-consensus-changes-2
2022-02-28 20:46:55 +00:00
Jack Grigg
65f3e6ec32
Add `FullViewingKey::derive_internal`
...
This is identical to the changes introduced in zcash/orchard#270 , except
that the output is non-optional (since the derivation is non-fallible).
2022-02-21 14:41:47 +00:00
Jack Grigg
17ad25ee35
Merge branch 'non-consensus-changes-on-branchid-c4cd541e' into merge-non-consensus-changes
2022-02-15 22:46:47 +00:00
Kris Nuttycombe
5d5e289197
Remove default_diversifier and default_address methods.
2022-02-15 14:39:32 -07:00
Kris Nuttycombe
4c7ab377fb
Make the DiversifierKey type crate-private
2022-02-14 17:04:38 -07:00
Kris Nuttycombe
ae3cc78a56
Add decryption of the diversifier index for an address to the IVK.
...
Also correct a spelling error.
2022-02-14 17:04:38 -07:00
str4d
4ae32ef98a
Merge pull request #282 from zcash/clone-unauthorized-bundle
...
Add `Clone` impls to various structs
2022-02-12 03:23:11 +00:00
Jack Grigg
c4cd541e6c
Add `Clone` impls to various structs
...
This enables `InProgress<Unproven, Unauthorized>: Clone`, which allows
the bundle returned by `Builder::build` to be cloned. In pure-Rust
wallets this should not be necessary, but it is required for `zcashd`
due to FFI-crossing.
2022-02-12 02:04:52 +00:00
Kris Nuttycombe
b7f66b48e6
Merge pull request #280 from nuttycom/decrypt_diversifier
...
Add diversifier index decryption to DiversifierKey
2022-02-11 14:51:54 -07:00
Kris Nuttycombe
8c96640826
Add diversifier index decryption to DiversifierKey.
2022-02-11 14:09:07 -07:00
Jack Grigg
c1447d6af2
Fix broken main branch
...
This was a non-code merge conflict between zcash/halo2#217 and main,
that caused CI to break after the PR merged.
2022-02-08 15:19:56 +00:00
str4d
40491385c6
Merge pull request #217 from zcash/update-halo2-gadgets
...
Delete gadgets and introduce halo2_gadgets dependency.
2022-02-03 21:23:42 +00:00
therealyingtong
91e22e4f92
Use internal keys test vectors.
2022-02-01 18:55:21 +08:00
therealyingtong
9cf4e10d4f
Remove InternalSpendingKey, introduce FullViewingKey::rivk_internal.
2022-02-01 18:55:21 +08:00
therealyingtong
99119f04fa
Derive internal full viewing key.
2022-02-01 18:55:21 +08:00
therealyingtong
2412e83400
Derive internal spending key.
2022-02-01 18:55:21 +08:00
Jack Grigg
f300cea2c8
Fix clippy lints
...
These became stable lints between 1.51 and 1.54.
2022-01-28 23:00:00 +08:00
Jack Grigg
0e1220acc9
Merge branch 'main' into orchard-mainnet-circuit
2021-12-20 15:20:33 +00:00
Jack Grigg
369b99ee3f
Add `doc_cfg` annotations
2021-12-17 22:08:58 +00:00
Jack Grigg
044844c0a0
Reject the identity in `SpendValidatingKey::from_bytes`
...
`ak_P` is not allowed to be the identity in the Orchard protocol. We
were enforcing this by construction in most places, except for the
parsing of an Orchard full viewing key.
Closes zcash/orchard#261 .
2021-12-15 13:48:59 +00:00
Jack Grigg
0378898289
Replace `FieldExt::{from, to}_bytes` with `PrimeField::{from, to}_repr`
2021-12-09 15:39:37 +00:00
Jack Grigg
37f1bba998
Remove `PartialEq, PartialOrd` impls from `{Extended}SpendingKey`
2021-11-30 23:25:35 +00:00
Jack Grigg
674ceb54c8
`impl ConstantTimeEq for {Extended}SpendingKey`
2021-11-30 23:24:50 +00:00
Kris Nuttycombe
14c4b40dfc
Add construction of DiversifierIndex directly from bytes.
2021-11-24 18:09:25 -07:00
Jack Grigg
235cd791b4
Fix `IncomingViewingKey::to_bytes`
...
`slice::copy_from_slice` panics if the source and destination slices are
not the same length.
Closes zcash/orchard#228 .
2021-11-17 12:12:20 +00:00
Jack Grigg
8c82ceecbf
ff 0.11, group 0.11, pasta_curves 0.2 etc.
2021-09-06 20:39:43 +01:00
Kris Nuttycombe
e4a54cdf61
Improve error handling in zip32 APIs.
2021-08-31 16:49:58 -06:00
therealyingtong
c3e24794f0
zip32.rs: master and child key derivation for ExtendedSpendingKey
2021-08-31 15:49:32 -06:00
Kris Nuttycombe
77be355912
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
Co-authored-by: ying tong <yingtong@z.cash>
2021-08-23 11:29:07 -06:00
Kris Nuttycombe
0449edd5b8
Validate the sign of the y-coordinate for ak when deserializing.
2021-08-23 11:29:07 -06:00
Kris Nuttycombe
872f337811
Expose SpendingKey byte representation.
2021-08-23 11:29:07 -06:00
Kris Nuttycombe
5d78ab3508
Add Eq and Ord implementations for Orchard keys.
2021-08-23 11:29:06 -06:00
Kris Nuttycombe
52f0f158ef
Add serialization and parsing of full viewing keys.
2021-08-23 11:28:27 -06:00
Kris Nuttycombe
1fd00e6236
Add raw address serialization and parsing.
2021-08-23 11:28:27 -06:00