Jack Grigg
5ccba3e1af
zcash_primitives: Introduce newtypes for `ask` and `ak`
...
The Sapling key components specification places more constraints on the
values of `ask` and `ak` than general RedJubjub signing and verification
keys.
2023-12-01 11:19:31 +00:00
Jack Grigg
de1ed21051
zcash_primitives: Replace `sapling::redjubjub` with `redjubjub` crate
...
As a side-effect, we remove the ability to verify individual
transactions with pre-ZIP 216 rules (which we already removed from
`zcashd` consensus nodes in zcash/zcash#6000 and zcash/zcash#6399 , as
all pre-ZIP 216 transactions on mainnet are also valid under ZIP 216).
2023-11-30 17:52:31 +00:00
Kris Nuttycombe
1e5d253c9c
Fix dependencies to repair `cargo -p` subproject builds.
2023-11-29 12:37:18 -07:00
Kris Nuttycombe
7f3d057a1b
zcash_primitives: Avoid passing duplicate diversifier information to Sapling builder.
...
The note provided to `add_sapling_spend` contains the recipient address,
and we can extract the diversifier from this address, so we should not
pass it separately.
2023-11-28 10:54:06 -07:00
Jack Grigg
0d06e561bb
Update Sapling imports to migrate off re-exports at old paths
2023-11-28 03:40:41 +00:00
Jack Grigg
54fa31e00c
zcash_primitives: Separate `GROTH_PROOF_SIZE` constant for `sapling` module
2023-11-28 03:25:14 +00:00
Jack Grigg
106f5a353a
Remove `MemoBytes` usage from `zcash_primitives::sapling`
2023-11-28 03:25:14 +00:00
Jack Grigg
7064efe697
zcash_primitives: Improve ZIP 32 comments
2023-11-28 01:38:53 +00:00
Jack Grigg
f7726141c3
zcash_primitives: Reject non-canonical ZIP 32 Sapling master key encodings
2023-11-28 01:38:53 +00:00
Jack Grigg
7badba29ea
zcash_primitives: Move `zip32::sapling` to `sapling::zip32`
2023-11-28 01:38:53 +00:00
Jack Grigg
45ef8b1604
zcash_primitives: Add constructor and getter to `zip32::ChainCode`
2023-11-28 01:38:53 +00:00
Jack Grigg
61bb18d97f
zcash_primitives: Refactor `zip32::ChildIndex` to be an opaque struct
2023-11-28 01:38:53 +00:00
Jack Grigg
a9310e3969
zcash_primitives: Remove non-hardened Sapling ZIP 32 derivation
2023-11-28 01:34:31 +00:00
Jack Grigg
cdd20e8583
zcash_primitives: Make `value_balance` generic in `sapling::Bundle`
...
This removes the dependency on `Amount`, and matches how we handle this
in the `orchard` crate.
Part of zcash/librustzcash#1044 .
2023-11-23 07:08:13 +00:00
Jack Grigg
eb0b5a1b24
zcash_primitives: Remove `consensus::Parameters` from `sapling` module
...
Part of zcash/librustzcash#1044 .
2023-11-22 04:29:36 +00:00
Kris Nuttycombe
236cd569ee
Merge pull request #891 from nuttycom/proposal-ffi
...
Add protobuf representation for transaction proposals
2023-11-15 15:47:46 -07:00
Daira Emma Hopwood
e32cf8b5ac
Use `{ENC,OUT}_CIPHERTEXT_SIZE` constants in `zcash_primitives::transaction::components::sapling`.
...
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-11-10 20:38:50 +00:00
Daira Emma Hopwood
e5bdc72b52
Use `{ENC,OUT}_CIPHERTEXT_SIZE` constants in `zcash_primitives::sapling::bundle`.
...
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-11-10 20:30:31 +00:00
Kris Nuttycombe
33169719ce
zcash_client_backend: Add serialization & parsing for protobuf Proposal representation.
2023-11-09 20:07:16 -07:00
Jack Grigg
c6dd9ad858
zcash_primitives: Expose Sapling bundle component parsers needed by zcashd
...
These can be removed after future zcashd refactors.
2023-11-10 02:09:22 +00:00
Jack Grigg
68ae453e5d
zcash_primitives: Move Sapling bundle parsing into `transaction::components::sapling`
2023-11-10 02:09:22 +00:00
Jack Grigg
e1a5539094
zcash_primitives: Rework Sapling parsers to be plain functions
...
Once `zcash_primitives::sapling` is extracted to `sapling-crypto`, these
would have become orphan impls.
2023-11-10 01:06:18 +00:00
Jack Grigg
54eb03e34e
zcash_primitives: Move Sapling bundle types into `sapling` module
2023-11-09 04:04:07 +00:00
Jack Grigg
f5595122f9
zcash_primitives: Move `builder` module to `zcash_primitives::sapling`
2023-11-09 04:02:19 +00:00
str4d
64d657ed31
Merge pull request #1033 from zcash/sapling-params-refactor
...
Introduce newtypes for Sapling circuit parameters
2023-11-08 21:01:30 +00:00
str4d
e4b9d73d0c
Merge pull request #1003 from nuttycom/wallet/reusable_input_selection
...
zcash_client_backend: Factor out `InputSource` from `WalletRead`
2023-11-08 20:20:03 +00:00
Kris Nuttycombe
aa063ae3fd
zcash_client_backend: Factor out input source traits from `WalletRead`
...
Prior to this change, it's necessary to implement the entirety of the
`WalletRead` trait in order to be able to use the input selection
functionality provided by `zcash_client_backend::data_api::input_selection`.
This change factors out the minimal operations required for transaction
proposal construction to better reflect the principle of least authority
and make the input selection code reusable in more contexts.
In order to minimize the operations of the newly-created `InputSource`
and `ShieldingSource` traits, this change also removes the
`min_confirmations` field from transaction proposals, in favor of
storing explicit target and anchor heights. This has the effect of
limiting the lifetime of transaction proposals to `PRUNING_DEPTH -
min_confirmations` blocks.
2023-11-08 12:41:49 -07:00
Jack Grigg
82535112c2
zcash_primitives: Add Sapling verification key newtypes
2023-11-07 03:11:15 +00:00
Jack Grigg
1b9f26c984
Move `{Spend,Output}Parameters` from `zcash_proofs` to `zcash_primitives`
2023-11-07 03:09:25 +00:00
Jack Grigg
8bb9c4e7ba
Move Sapling proof verifiers from `zcash_proofs` to `zcash_primitives`
2023-11-07 03:08:43 +00:00
Jack Grigg
3b8c932ab9
zcash_primitives: Implement `Clone` on bundle marker types
...
This enables unauthorized Sapling bundles to be cloned, for example when
loading them into a `TransactionData` for signature hashing.
2023-11-04 04:27:07 +00:00
Jack Grigg
b20641ae58
zcash_primitives: Remove `sapling::prover::TxProver`
...
Removed
-------
- `zcash_primitives::sapling`:
- `prover::TxProver` (use `SpendProver` and `OutputProver` instead).
- `prover::mock::MockTxProver` (use `MockSpendProver` and `MockOutputProver`
instead).
2023-11-03 21:08:37 +00:00
Jack Grigg
a77b6c631c
Add missing unreleased changelog entries
2023-11-03 00:56:56 +00:00
Jack Grigg
bed5bc6cf6
Clean up unreleased changelog entries
2023-11-03 00:56:26 +00:00
Jack Grigg
b2ff29db78
Refactor Sapling builder to separate out proof generation
...
Closes zcash/librustzcash#741 .
2023-10-31 22:01:34 +00:00
Kris Nuttycombe
570ea48588
Apply suggestions from code review
...
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-10-26 15:24:45 -06:00
Kris Nuttycombe
cc0cc2de84
zcash_primitives: add StandardFeeRule
...
`StandardFeeRule` is an enumeration of the standard fees that have
existed in the history of Zcash zips. It is provided to simplify
transition to new fee strategies; legacy elements of this enumeration
are introduced already-deprecated.
2023-10-25 08:08:49 -06:00
Kris Nuttycombe
caee90dce9
`zcash_primitives`: Use sapling::NoteValue instead of bare u64
2023-10-24 16:36:56 -06:00
Kris Nuttycombe
9cd60c536e
Apply suggestions from code review
...
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-10-24 13:11:35 -06:00
Kris Nuttycombe
f7527e14c9
Use `NonNegativeAmount` for note and utxo value fields
2023-10-23 12:59:26 -06:00
Kris Nuttycombe
a2b5c2c784
zcash_client_backend: Use `NonNegativeAmount` for fee and change amounts.
...
In order to use `uint64` for amounts that must be nonnegative in the
`proposal.proto` file, it is useful to update fee and change computation
to use `NonNegativeAmount` where possible.
2023-10-10 16:12:47 -06:00
Kris Nuttycombe
030c1825a8
Merge pull request #1011 from nuttycom/wallet/note_identifiers
...
Make `ReceivedSaplingNote` internals private, and use (TxId, output_index) for note identifiers.
2023-10-10 07:30:33 -06:00
zancas
4bd3259ad0
Add a MARGINAL_FEE constant for the ZIP 317 marginal fee
2023-10-09 15:23:55 -06:00
sasha
74840829c8
zcash_client_backend: Make `ReceivedSaplingNote` internals private.
...
This also adds the txid and index to `ReceivedSaplingNote` for use as a
globally identifier for the note.
2023-10-09 12:22:12 -06:00
Jack Grigg
e1a4238a71
zcash_primitives: Add helper impls of `{Try}MapAuth` for closures
2023-10-06 23:48:27 +00:00
Jack Grigg
65efee1a16
zcash_primitives: Add `sapling::Bundle::try_map_authorization`
2023-10-06 23:46:02 +00:00
Jack Grigg
b09b435135
zcash_primitives: Change `sapling::MapAuth` to take `&mut self`
2023-10-06 23:43:43 +00:00
Jack Grigg
241a1a3660
zcash_primitives: Add some more `Clone` and `Debug` impls
2023-10-06 22:05:49 +00:00
Jack Grigg
04aa5a044b
zcash_primitives: Add `MockSpendProver` and `MockOutputProver`
...
These are analogues of `MockTxProver` in that they implement the
corresponding Sapling prover traits.
2023-10-06 20:31:31 +00:00
Jack Grigg
296f75954b
Add `SpendProver::encode_proof` and `OutputProver::encode_proof`
2023-10-06 20:19:41 +00:00
Kris Nuttycombe
e6fa567332
Merge pull request #1000 from zingolabs/add_debugs_to_inputs
...
add Debug to transaction builder-reported types
2023-10-04 09:15:29 -06:00
Kris Nuttycombe
b73c51f974
Merge pull request #1004 from zingolabs/add_fee_getter
...
Add fee getter
2023-10-03 12:04:29 -06:00
zancas
b9f8ec8ed2
add pub getter to transaction builder
...
use getter in original context to DRY
add doc-comment
Minor cleanup & documentation fixes.
Co-Authored-By: Daira Emma Hopwood <daira@jacaranda.org>
2023-10-03 11:13:06 -06:00
Jack Grigg
0d46fe72cc
zcash_primitives: Introduce an `OutputProver` trait
2023-10-02 16:59:01 +00:00
Jack Grigg
290bfa8b31
zcash_primitives: Introduce a `SpendProver` trait
2023-10-02 16:59:01 +00:00
zancas
b5e24751d6
add Debug to transaction builder-reported types
2023-09-29 12:55:06 -06:00
Jack Grigg
db31105067
Move Sapling circuits from `zcash_proofs` to `zcash_primitives::sapling`
...
Closes zcash/librustzcash#737 .
2023-09-29 18:36:54 +00:00
Jack Grigg
0ddcccdbac
zcash_primitives: Move Sapling constants into `sapling` module
2023-09-29 17:39:43 +00:00
Jack Grigg
7e89300db9
Move common package and dependency configs into workspace config
...
The MSRV for the main crates is 1.65, which is higher than the Rust
version that stabilised workplace dependencies (1.64). The implicit MSRV
for the component crates is still lower than this, so we don't migrate
these crates.
2023-09-26 22:01:32 +00:00
Jack Grigg
d35d0961ab
zcash_primitives 0.13.0
2023-09-25 15:06:57 +00:00
Daira Emma Hopwood
401af23484
Improve wallet tests.
...
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-09-12 01:33:12 +01:00
Jack Grigg
67b84c25e0
zcash_primitives 0.13.0-rc.1
2023-09-08 19:45:54 +00:00
Kris Nuttycombe
46cc6666df
Address comments from code review.
...
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-09-08 13:03:53 -06:00
Jack Grigg
94c1f2413d
Migrate to `incrementalmerkletree 0.5`, `orchard 0.6`
2023-09-08 18:57:25 +00:00
Kris Nuttycombe
0ea2290670
zcash_primitives: update CHANGELOG.md in preparation for the 0.13.0 release
2023-09-08 08:54:39 -06:00
Kris Nuttycombe
7abd1324de
Apply suggestions from code review
...
Co-authored-by: Daira Emma Hopwood <daira@jacaranda.org>
Co-authored-by: Jack Grigg <jack@electriccoin.co>
2023-09-05 16:49:36 -06:00
Kris Nuttycombe
f53ea2d778
Add `get_wallet_summary` to `WalletRead`
...
The intent of this API is to provide a single API which returns in a
single call:
* per-account balances, including pending values
* wallet sync progress
Fixes #865
Fixes #900
2023-09-05 16:06:55 -06:00
Kris Nuttycombe
224e021558
Merge pull request #931 from nuttycom/remove_deprecated_default_fee
...
zcash_primitives: Remove the deprecated 1000-ZAT DEFAULT_FEE constant
2023-09-01 14:40:11 -06:00
Kris Nuttycombe
14d61a2e98
zcash_primitives: Remove the deprecated 1000-ZAT DEFAULT_FEE constant
2023-09-01 12:46:13 -06:00
Jack Grigg
f33c8ea418
zcash_primitives: Parse the full opcode set
...
This enhances the alternate `impl Debug for Script` to render unexpected
scripts correctly.
2023-08-30 20:41:27 +00:00
Jack Grigg
c8e2d81f58
Render byte slices as hex more often in `Debug` impls
...
This is more generally useful for debugging purposes than the default
`Debug` impl for `&[u8]`.
We also provide an alternate `Debug` impl for `legacy::Script` that
parses and renders known opcodes. Note that we only parse a subset of
the full opcode set.
2023-08-30 20:41:27 +00:00
Jack Grigg
57a3914e3a
zcash_primitives: Drop `byteorder::LittleEndian` usage in sighash
2023-08-30 19:46:38 +00:00
Jack Grigg
2a98f94f05
Add more debug and trace logging
...
The `Debug` impl for `sapling::Node` is updated to output hex-encoded
bytes for readability.
2023-07-18 17:23:57 +00:00
Kris Nuttycombe
6fa0b46d8e
Implement `suggest_scan_ranges` and `update_chain_tip`
...
This implements a priority queue backed by the wallet database for scan
range ordering. The scan queue is updated on each call to `put_blocks`
or to `update_chain_tip`.
2023-07-07 20:13:45 -06:00
Kris Nuttycombe
e3aafdad19
Move chain continuity checks into `scan_block_with_runner`
...
In preparation for out-of-order range-based scanning, it is necessary
to ensure that the size of the Sapling note commitment tree is carried
along through the scan process and that stored blocks are always
persisted with the updated note commitment tree size.
2023-07-03 10:49:03 -06:00
Kris Nuttycombe
d65b129b43
Apply changelog, documentation & style suggestions from code review
...
Co-authored-by: str4d <thestr4d@gmail.com>
2023-06-30 09:30:24 -06:00
Kris Nuttycombe
0a4236f725
zcash_client_sqlite: Add tests for sqlite-backed ShardTree & fix revealed issues.
2023-06-29 15:35:18 -06:00
Kris Nuttycombe
3e358bc1c9
zcash_client_backend: Use `shardtree` for note commitments in block scanning.
...
Also adds a skeleton `zcash_client_sqlite` implementation of
`shardtree::ShardStore` and a skeleton migration for related
database changes.
2023-06-29 15:35:18 -06:00
Kris Nuttycombe
7fe02f0606
Remove needless bound on `FeeRule` from builder `Error` type.
2023-06-23 15:24:38 -06:00
Kris Nuttycombe
1b4017e0d1
Apply suggestions from code review
...
Co-authored-by: str4d <thestr4d@gmail.com>
2023-06-23 15:16:10 -06:00
Kris Nuttycombe
95abfe5836
Improve documentation for `zcash_primitives::transaction::builder::Error::OrchardAnchorNotAvailable`
...
Co-authored-by: str4d <thestr4d@gmail.com>
2023-06-23 14:56:49 -06:00
Hazel OHearn
4fbdd64c89
Add Orchard support to `zcash_primitives::transaction::builder::Builder`
...
Co-authored-by: Jack Grigg <jack@electriccoin.co>
Co-authored-by: Kris Nuttycombe <kris@nutty.land>
2023-06-23 14:09:59 -06:00
Hazel OHearn
dce8676974
Remove impls of `{PartialEq, Eq}` for `zcash_primitives::transaction::builder::Error`
...
Co-authored-by: Jack Grigg <jack@electriccoin.co>
2023-06-23 14:07:15 -06:00
Kris Nuttycombe
f9cacc5b21
Release zcash_primitives 0.12.0
2023-06-06 15:56:28 -06:00
Kris Nuttycombe
60ac1070c5
Release zcash_address version 0.3.0
2023-06-06 15:53:16 -06:00
Kris Nuttycombe
3dd0c63095
Update to `incrementalmerkletree 0.4`, `orchard 0.5`
2023-06-06 14:27:39 -06:00
Kris Nuttycombe
ebcfae987d
Update the data access API in preparation for shardtree introduction.
2023-06-02 10:59:17 -06:00
Kris Nuttycombe
59eef51b9e
Merge pull request #851 from zcash/simplify_parse_note_plaintext_ovk_args
...
Remove esk and ephemeral_key arguments from `parse_note_plaintext_ovk`
2023-05-31 12:54:04 -06:00
Kris Nuttycombe
36d7222685
Merge pull request #844 from zcash/temporary-zcashd-parse-sapling
...
zcash_primitives: Changes needed for `zcashd` Sapling oxidation
2023-05-30 17:30:47 -06:00
Kris Nuttycombe
696a9be0a0
Update `zcash_primitives` to reflect argument changes to `parse_note_plaintext_without_memo_ovk`
2023-05-26 09:43:26 -06:00
Kris Nuttycombe
3ae90020c3
Merge pull request #848 from zcash/note-encryption-avoid-redundant-checks
...
Avoid redundant checks during note decryption
2023-05-26 09:10:52 -06:00
Kris Nuttycombe
980736806f
Upgrade `incrementalmerkletree` & `orchard` patch versions.
2023-05-25 12:33:25 -06:00
Jack Grigg
2ae4d87cbf
zcash_primitives: Remove redundant checks from Sapling note decryption
...
- The consistency check between `esk` and `ephemeral_key` is checked
inside `zcash_note_encryption::try_output_recovery_with_ock`.
- The `diversifier` validity check is necessarily performed when
deriving `pk_d` for the `ivk` pathway, so we keep it there for the
`ovk` pathway as well, and drop the check from the `PaymentAddress`
internal constructor.
2023-05-19 16:36:55 +00:00
Jack Grigg
8db7a071a0
zcash_primitives: `impl DynamicUsage for sapling::Bundle<Authorized>`
2023-05-17 03:44:24 +00:00
Jack Grigg
26d95b4a0e
zcash_primitives: Temporarily expose v5 Sapling bundle parsing
...
This is currently exposed via `Transaction` for usage in `zcashd`, but
may be removed in future (if `zcashd` moves transaction parsing entirely
into Rust), or renamed and stabilised.
2023-05-17 03:44:24 +00:00
Jack Grigg
a092da8d5d
Fix clippy lints for 1.65
2023-05-16 15:59:58 +00:00
Jack Grigg
6419e1e363
Remove `inferno` pin now that its MSRV is compatible with ours
2023-05-16 15:39:06 +00:00
Jack Grigg
8681b56d52
Bump MSRV for `zcash_primitives` and dependents to 1.65
2023-05-16 15:37:07 +00:00
Kris Nuttycombe
bc55893267
Merge pull request #838 from daira/update-fee-constants
...
Revert #830 and instead modify `zcash_primitives::transaction::fees::fixed::FeeRule::standard()`
2023-05-09 13:17:27 -06:00
Daira Emma Hopwood
32296e7327
Update `DEFAULT_TX_EXPIRY_DELTA` to 40 blocks, as specified in
...
<https://zips.z.cash/zip-0203#changes-for-blossom >. fixes #837 .
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-05-09 18:38:39 +01:00
Daira Emma Hopwood
3903935234
Deprecate `transaction::components::amount::DEFAULT_FEE` and
...
`zcash_primitives::transaction::fees::fixed::FeeRule::standard()`.
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-05-09 17:18:34 +01:00
Daira Emma Hopwood
736d11b45b
Change `transaction::fees::fixed::FeeRule::standard()` to use the ZIP 317
...
minimum fee (10000 zatoshis rather than 1000 zatoshis) as the fixed fee.
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-05-09 16:42:41 +01:00
Daira Emma Hopwood
043cc59c76
Add `transaction::fees::zip317::MINIMUM_FEE` constant and
...
`transaction::components::amount::Amount::const_from_i64`.
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-05-09 16:42:19 +01:00
Daira Emma Hopwood
4cf27126e5
Revert "Update DEFAULT_FEE to 10_000 from 1000"
...
This reverts commit 2a6dc59c5d
.
Signed-off-by: Daira Emma Hopwood <daira@jacaranda.org>
2023-05-09 13:15:52 +01:00
Kris Nuttycombe
d37e6adee5
Merge pull request #783 from nuttycom/upgrade_bridgetree
...
Upgrade `zcash_primitives` to use updated `incrementalmerkletree` types.
2023-05-08 12:00:00 -06:00
str4d
579ab92b93
Merge branch 'main' into 823-secp256k1-0.26
2023-05-08 18:53:33 +01:00
Kris Nuttycombe
ec29836df9
Remove `bridgetree` dependency from `zcash_primitives`.
...
This also now makes `zcash_extensions` use `incrementalmerkletree`
transitively via type aliases in `zcash_primitives`.
2023-05-04 15:42:39 -06:00
Kris Nuttycombe
c9f53ddde5
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2023-05-04 14:46:34 -06:00
Kris Nuttycombe
4d32a8ac20
Remove serialization version constants.
2023-05-04 12:46:15 -06:00
Kris Nuttycombe
71f74d4ac1
Remove the `merkle_tree::incremental` module.
...
This consolidates all the seralization code for frontiers and
incremental witnesses in the `merkle_tree` module.
2023-05-04 12:46:15 -06:00
Kris Nuttycombe
6aaa96d377
Remove zcashd-specific `bridgetree` serialization.
2023-05-04 12:46:15 -06:00
Kris Nuttycombe
1f9747e15f
Move merkle tree types to the `incrementalmerkletree` crate.
...
This removes the `CommitmentTree`, `IncrementalWitness`, and
`MerklePath` types in favor of equivalent versions available
from the `incrementalmerkletree` crate.
2023-05-04 12:30:56 -06:00
Kris Nuttycombe
667a7b841e
Move-only: restructure merkle tree source for extraction.
2023-05-04 12:21:50 -06:00
Kris Nuttycombe
6f2cbfc7de
Factor serialization out from merkle tree data structures.
2023-05-04 12:21:47 -06:00
Kris Nuttycombe
831a6cd396
Remove superfluous inner functions now that tree depth is a constant.
2023-05-04 12:16:09 -06:00
Kris Nuttycombe
ec57d23115
Use const generics to set commitment tree & incremental witness depths.
...
This is in preparation for extraction into the `incrementalmerkletree`
crate, which is not Sapling-specific and therefore cannot hard-code
the depths of these data structures.
2023-05-04 12:16:09 -06:00
Kris Nuttycombe
69430c3da2
Upgrade incrementalmerkletree and use bridgetree crate for `Bridgetree`.
2023-05-04 12:08:38 -06:00
Hazel OHearn
2a6dc59c5d
Update DEFAULT_FEE to 10_000 from 1000
2023-05-03 16:42:01 -03:00
Jack Grigg
ec1c1bcf21
Migrate to `secp256k1 0.26`, `hdwallet 0.4`
...
Closes zcash/librustzcash#823 .
2023-04-19 19:33:34 +00:00
Jack Grigg
a419b56e80
zcash_primitives 0.11.0
2023-04-14 23:56:16 +00:00
Jack Grigg
7be5d1bf7d
Update changelogs
2023-04-14 23:49:13 +00:00
Kris Nuttycombe
30dfcd79cc
Merge pull request #809 from nuttycom/test/merkle_tree_serialization
...
Add roundtrip and golden tests for v1 `MerkleBridge` serialization.
2023-04-12 13:40:49 -06:00
Jack Grigg
edb1941f19
zcash_primitives: Downgrade to `bip0039 0.10`
...
`bip0039 0.11` switched from language function arguments to a generic
parameter. We aren't ready to migrate to this yet.
2023-04-12 16:19:03 +00:00
Kris Nuttycombe
b2139c0b97
Add roundtrip and golden tests for v1 `MerkleBridge` serialization.
2023-04-11 16:45:09 -06:00
Kris Nuttycombe
3ff5fa5288
Merge pull request #793 from zcash/zip32_seed_signature
...
[#792 ] zcash_primitives: implement Seed Signature section of ZIP-32
2023-04-11 12:58:39 -06:00
Jack Grigg
878f3e9214
zcash_primitives: Migrate to `sha2 0.10`, `bip0039 0.11`
2023-04-11 15:48:44 +00:00
Jack Grigg
d2ccd1f017
zcash_primitives: Migrate to `fpe 0.6`
...
Part of zcash/librustzcash#757 .
2023-04-11 15:48:44 +00:00
Jack Grigg
2fcde5e047
Migrate to `orchard 0.4.0`
...
Closes zcash/librustzcash#766 .
2023-04-11 13:25:17 +00:00
Francisco Gindre
e3f09ba66a
[ #792 ] zcash_primitives: implement Seed Signature section of ZIP-32
...
Implements a type to enclose a Seed Fingerprint byte sequence
called `SeedFingerprint`
implements a public function to create a `SeedFingerprint` from
seed bytes
Closes #792
Credits for PR Suggestions by Daira and Kris
Edit: Added suggestions from Daira Emma and a test for returning `None`
Added test refactor suggestions as well
removed reference to test vectors
2023-03-30 18:41:57 -03:00
Kris Nuttycombe
d6fafa291b
Update Sapling note encryption for `zcash_note_encryption 0.3.0`
...
Fixes zcash/librustzcash#455
2023-03-21 11:09:38 -06:00
Kris Nuttycombe
c696069f93
Bump zcash_note_encryption to version 0.3.0 for release.
...
This removes the path-based dependencies on the `zcash_note_encryption`
crate in favor of using versioned dependencies locally. This better
reflects the future state in which `zcash_note_encryption` is factored
out of the workspace and maintained in a separate repository.
2023-03-20 16:16:34 -06:00
Kris Nuttycombe
cb1be45f22
Update CHANGELOGs to reflect the addition of the zcash_primitives/multicore feature.
2023-03-20 15:11:05 -06:00
Kris Nuttycombe
7c1a4c898d
Fix wasm32 CI runner.
...
The `halo2_proofs/multicore` flag must be disabled when running wasm
builds; this ensures that we do not accidentally include it as a
transitive dependency when building with `--no-default-features`.
2023-03-20 14:39:07 -06:00
Kris Nuttycombe
77fbd8cb4f
Update dependencies to reflect changes in ff 0.13
2023-03-20 14:35:45 -06:00
Jack Grigg
2530eb3a9d
Temporarily re-expose Sapling `NoteCommitment` derivation
2023-03-16 23:27:01 +00:00
Jack Grigg
a8003c8ff5
Temporarily re-expose ability to construct invalid Sapling bundles
...
Until zcash/zcash#6397 is closed, this ability is needed by `zcashd` for
crossing the FFI.
2023-03-08 03:45:01 +00:00
Kris Nuttycombe
9c56b21de7
Pin the `inferno` transitive dependency to avoid MSRV errors.
2023-02-16 11:06:24 -07:00
Jack Grigg
9852c31970
zcash_primitives 0.10.0
2023-02-01 02:10:42 +00:00
Jack Grigg
7f970bb82f
Use `EphemeralSecretKey, EphemeralPublicKey, SharedSecret` types in APIs
2023-01-24 15:02:49 +00:00
Jack Grigg
bc99cd2634
Move prepared key types into `sapling::keys`
...
We re-export them under `sapling::note_encryption` for now to make the
API changes smaller.
2023-01-24 15:02:43 +00:00
Jack Grigg
ded14adbb3
Add `sapling::keys::DiversifiedTransmissionKey`
2023-01-24 15:02:38 +00:00
Jack Grigg
06ba399d80
Clean up the `sapling::Note` API
2023-01-24 15:02:32 +00:00
Jack Grigg
87d0bd7db1
Refactor `sapling::Note`
...
Its internals are now private, and it stores a `PaymentAddress` (and by
extension the diversifier) instead of `g_d`.
2023-01-24 15:02:27 +00:00
Jack Grigg
dff21222fb
Require `PaymentAddress` to contain a valid diversifier
2023-01-24 14:51:13 +00:00
Jack Grigg
42c332a7a8
Use `sapling::note::ExtractedNoteCommitment` type in APIs
2023-01-24 14:37:11 +00:00
Jack Grigg
0a26c812e0
Split `sapling::Authorization::Proof` type into Spend and Output types
...
While the Groth16 proofs have identical encodings, they are technically
for different circuits, and we need the ability to differentiate them
during bundle building.
2023-01-20 11:12:49 +00:00
Kris Nuttycombe
79f3f10714
Merge pull request #760 from zcash/759-msrv-1.60
...
Bump MSRV for `zcash_primitives` and dependents to 1.60
2023-01-19 19:33:15 -07:00
Jack Grigg
809427f6bd
criterion 0.4
2023-01-20 00:03:10 +00:00
Jack Grigg
49b1cb3e69
Bump MSRV for `zcash_primitives` and dependents to 1.60
...
The MSRVs of the component crates are left as-is, partly because our
dependencies don't require us to bump them, and partly because those
crates have no pending changes and are relatively stable. We also plan
to split the component crates out into a separate repository, where it
will be easier to have a separate MSRV.
Closes zcash/librustzcash#759 .
2023-01-19 23:48:24 +00:00
Jack Grigg
19d8e2125e
Introduce `sapling::keys::{EphemeralSecretKey, EphemeralPublicKey}` types
2023-01-06 22:42:33 +00:00