Kris Nuttycombe
62e1f99eb0
Improve TransferType documentation.
2022-10-11 14:42:06 -06:00
Kris Nuttycombe
fd1640c242
Update CHANGELOGs
2022-10-11 13:08:15 -06:00
Kris Nuttycombe
3c837381db
Disallow invalid pool/address combinations with `Recipient`.
2022-10-11 12:52:44 -06:00
Kris Nuttycombe
56b2edd498
Simplify sqlite backend storage for sent notes & utxos.
...
The currently deprecated implementations of `insert_sent_utxo`,
`insert_sent_note`, `put_sent_utxo` and `put_sent_note` all store to the
same `sent_notes` table internally. Since there's no immediate plan to
change this arrangement, it's better to have a single pair of internal
`insert_sent_output` and `put_sent_output` methods instead.
2022-10-11 08:57:44 -06:00
Kris Nuttycombe
06e43a572a
Track inputs sent to wallet-internal recipients.
...
Ensure that we're attempting trial-decryption with the internal IVK
and correctly track internal vs. external recipients in the wallet
database.
2022-10-11 08:56:22 -06:00
str4d
1dc3cfe724
Merge pull request #657 from nuttycom/wallet/upsert_utxos
...
Use upsert functionality for transparent UTXOs, rather than delete/repopulate.
2022-10-11 04:17:49 +01:00
Kris Nuttycombe
bd8472535c
Add a test for unified address derivation.
2022-10-07 20:37:39 -06:00
Kris Nuttycombe
c7be8ef04a
Allow spent UTXOs to be absent in migrations when adding tx fee.
...
The previous approach to UTXO handling involved UTXO data being
deleted from the wallet after the relevant UTXOs had been spent.
However, this means that we can no longer accurately compute
transaction fees for the transactions spending those UTXOs.
The `net_value` of the resulting rows in v_transactions will be
null.
2022-10-06 17:13:27 -06:00
Kris Nuttycombe
c5b9219f00
Look up the account by the UFVK corresponding to the USK when spending.
2022-10-05 14:35:51 -06:00
Kris Nuttycombe
b7cc038050
Use unified spending keys for spends & shielding.
2022-10-05 14:35:51 -06:00
Kris Nuttycombe
e9406201d5
Merge pull request #663 from nuttycom/sapling_key_cleanup
...
Fix Sapling key organization.
2022-10-05 14:35:16 -06:00
Kris Nuttycombe
6df6fec860
Add utxo received_by_account data to WalletTransparentOutput
...
Also, this removes wallet::delete_utxos_above.
2022-10-04 13:34:52 -06:00
Kris Nuttycombe
14787f574f
Add a migration to add account ID to the utxos table.
2022-10-04 12:25:56 -06:00
Kris Nuttycombe
60785a1d7a
Fix Sapling key organization.
...
This change moves Sapling-specific key generation into a
submodule of `zip32`. Public reexports are used to keep the
existing API consistent.
2022-10-03 20:28:04 -06:00
Kris Nuttycombe
f7aa7b2c84
Upgrade rusqlite to version 0.25
2022-10-03 08:12:37 -06:00
Kris Nuttycombe
81e0d482d0
Merge pull request #656 from nuttycom/sqlite/migration_organization
...
Move wallet migrations into individual modules.
2022-10-03 08:10:08 -06:00
Jack Grigg
e54e3f21e8
zcash_client_sqlite: Remove direct ff dependency
2022-10-02 23:16:44 +01:00
Kris Nuttycombe
ccf9e00b00
Move wallet migrations into individual modules.
2022-10-02 14:20:17 -06:00
Kris Nuttycombe
2c16f78fee
zcash_client_sqlite: fix wallet::get_max_account_id
...
This had the same bug as was fixed in 5b8ec380a0
2022-09-26 16:48:58 -06:00
Kris Nuttycombe
6cb0d21219
Merge pull request #645 from nuttycom/fix_beta_lints
...
Fix problems identified by clippy's beta lints
2022-09-17 15:49:49 -06:00
Kris Nuttycombe
03c3370de8
Fix problems identified by clippy's beta lints
2022-09-17 08:57:37 -06:00
Jack Grigg
5b8ec380a0
zcash_client_sqlite: Fix `FsBlockDb::get_max_cached_height`
...
The `MAX` SQLite function returns `null` when the table is empty. The
code was expecting zero rows to be returned in this case, and was trying
to parse the `null` as an integer.
2022-09-17 02:40:19 +00:00
Kris Nuttycombe
f8fd27653c
Add a BlockSource implementation that reads blocks from files in the filesystem.
...
Also, this adds functionality to create and insert records into the
block metadata db that is used as the source for which blocks to read.
2022-09-15 08:27:26 -06:00
Kris Nuttycombe
d086c57f2f
Make init_accounts_table only permit sequential account identifiers.
...
Also, check to ensure that account creation does not exceed the
maximum account identifier value.
2022-09-14 13:55:31 -06:00
Kris Nuttycombe
75eb082203
Apply suggestions from code review
...
Co-authored-by: str4d <thestr4d@gmail.com>
2022-09-14 12:20:39 -06:00
Kris Nuttycombe
d0062a87d4
Add WalletWrite::create_account function
2022-09-13 18:58:28 -06:00
Kris Nuttycombe
b5908dc964
Merge pull request #632 from nuttycom/data_api/get_next_address
...
Replace `get_address` with `get_current_address` and `get_next_available_address`
2022-09-12 18:43:38 -06:00
Kris Nuttycombe
03b0ff7e0a
Replace `get_address` with `get_current_address` and `get_next_available_address`
...
This updates the data access API to provide diversified address
functionality. In order to support this change, the addresses table
is updated to store diversifier index information in big-endian order
to allow sorting by diversifier index, and account initialization
is updated to store the diversifier index accordingly. The currently
unreleased `addresses_table` migration is updated to reflect this
change.
2022-09-12 17:58:22 -06:00
Kris Nuttycombe
7d1e976d0a
Add missing `WalletMigrationError` to changelog.
2022-09-10 17:02:43 -06:00
Kris Nuttycombe
e14e44d6d7
Improve consistency of transaction views test.
2022-09-10 17:02:43 -06:00
Kris Nuttycombe
3120b304c7
Use `NULL` to represent the empty memo.
...
We don't need to store a bunch of copies of the empty memo, and code
should not be depending upon the presence or absence of a memo to
distinguish between different states of transaction retrieval.
2022-09-10 17:02:43 -06:00
Kris Nuttycombe
167bcd86ce
Update migration to handle the raw-tx-absent case.
...
The raw serialized transaction data for a transaction is not always
guaranteed to be present, and we cannot correctly calculate the fee
paid by a transaction if we don't have the raw data. For such rows
that contain only transaction metadata, the fee information will be
added at the same time the raw transaction data is added.
2022-09-10 17:02:43 -06:00
Kris Nuttycombe
7934e834d3
Add test for fee calculation in add_transaction_views migration.
2022-09-10 11:01:36 -06:00
Kris Nuttycombe
b327bf7073
Move WalletMigrationAddTxViews to a submodule.
2022-09-10 11:01:36 -06:00
Kris Nuttycombe
7842e6274f
Check against the standard empty memo for memo counts.
2022-09-09 16:32:37 -06:00
Kris Nuttycombe
95610f7b4f
Add fee to the transactions table & compute correct net_value in v_transactions.
2022-09-09 16:12:29 -06:00
Kris Nuttycombe
66c9f31e14
Add memo counts to transaction views.
2022-09-09 16:09:56 -06:00
Kris Nuttycombe
81c948a37e
Add views that join transactions & notes for Android SDK support.
...
Android does not provide a good way to perform outer joins in
its type-safe query builder API, so we expose views build using
those joins instead.
2022-09-09 16:09:04 -06:00
Jack Grigg
7112ed9da5
zcash_client_backend: Add `WalletReadTransparent::get_transparent_receivers`
...
Co-authored-by: Kris Nuttycombe <kris@nutty.land>
2022-09-08 20:24:42 +00:00
Jack Grigg
154ef077b4
zcash_client_sqlite: Move address data to an `addresses` table
...
Closes zcash/librustzcash#489 .
2022-09-08 18:50:18 +00:00
Jack Grigg
7d404d2747
zcash_client_sqlite: Fix `WalletRead::get_address` return value
...
Previously it would return an error if the account identifier did not
correspond to a known account.
2022-09-08 18:49:41 +00:00
Jack Grigg
a32714043b
zcash_client_backend: Change `WalletRead::get_address` to return UA
2022-09-08 18:49:13 +00:00
Kris Nuttycombe
a93f5945ab
Remove redundant TryFrom/TryInto imports.
2022-09-02 12:05:15 -06:00
Kris Nuttycombe
16a0e43f2d
Update to Rust 2021 and explicitly set MSRVs
2022-09-02 12:05:09 -06:00
Jack Grigg
4f5d757883
zcash_client_backend: Change to `WalletWrite::remove_unmined_tx`
...
This fixes a bug in the logic ported from the Android SDK: it was
possible to remove a transaction in the middle of a chain, which would
cause a long-spent note to become unspent and cause the wallet balance
to be over-counted. We now restrict transaction removal to unmined
transactions, which is sufficient for the Android SDK use cases.
2022-08-30 22:54:58 +00:00
Jack Grigg
586b7e5bb0
zcash_client_backend: Add `WalletWrite::remove_tx` method
...
This is to replace the database mutations in the Android SDK. It is
placed behind an `unstable` feature flag until we are satisfied that it
is suitable as a general-purpose API (or replace it).
2022-08-29 21:32:18 +00:00
Jack Grigg
04b1d505b2
zcash_client_sqlite: Move `DataConnStmtCache` into submodule
...
This removes direct access to the prepared statements, instead forcing
callers to use the type-safe methods added in the previous commit.
2022-08-29 19:25:36 +00:00
Jack Grigg
12e8c53310
zcash_client_sqlite: Add statement helper methods to `DataConnStmtCache`
...
These methods provide type-safe ways to interact with the prepared
statements.
2022-08-29 19:25:36 +00:00
Jack Grigg
439e8f2599
zcash_client_sqlite: Add `DataConnStmtCache::new` constructor
...
This is a move-only commit (other than the necessary variable renames).
2022-08-29 15:26:08 +00:00
Kris Nuttycombe
5dceb93ec8
Merge pull request #612 from nuttycom/wallet/set_fixed_user_version
...
Set a fixed `user_version` value for the sqlite schema in the initial migration.
2022-08-23 14:29:46 -06:00
Kris Nuttycombe
83c47b1a42
Set a fixed `user_version` value for the sqlite schema in the initial migration.
2022-08-23 12:23:47 -06:00
Kris Nuttycombe
6b73443f53
Add a test to check the result of database migrations against an expected schema.
2022-08-23 12:16:19 -06:00
Kris Nuttycombe
5d817f6120
Update to schemer 0.2
2022-08-19 09:55:55 -06:00
Kris Nuttycombe
913d572087
Allow the seed to be an optional argument to database init.
...
This adds a new `WalletMigrationError` type so that we have
a good place to report whether or not the seed is required.
2022-08-18 16:03:20 -06:00
Kris Nuttycombe
61fb732e7b
Ensure that we detect the correct pool type for sent notes.
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
e0c919cc68
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
880076b38f
Improve error reporting for address & viewing key decoding.
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
4930982d7e
Test migrations against possibly-previously-existing database states.
...
This adds tests that verifies that migrations can run successfully
against databases in the following states:
* created by release version 0.3.0
* created by the `autoshielding_poc` branch
* created by current `main` prior to addition of migrations
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
e9db8d5b01
Use `secrecy` when handling seed phrases in migrations code.
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
cdfaa57496
Add migrations to support using UFVKs instead of Sapling extfvks.
...
Fixes #594
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
7c5b320108
Introduce wallet database schema migrations.
...
This replaces the current wallet initialization code with a migration
that brings the database up to the state produced by release 0.3.0.
A subsequent commit will add migrations that correctly produce the
database state as of zcash/librustzcash@602270cb1f .
Fixes #369
2022-08-18 10:15:58 -06:00
Kris Nuttycombe
199c49760b
Use the new name rustdoc::broken_intra_doc_links
2022-07-29 15:56:44 -06:00
Kris Nuttycombe
f1c2da7b1d
Add sapling::NullifierDerivingKey newtype.
...
Nullifier computation only requires the nullifier deriving key,
not the entire Sapling viewing key. This separation of concerns
will be needed for batch decryption when wallet-internal keys
will need to be considered.
2022-07-28 15:23:21 -06:00
Daira Hopwood
09567fc280
Merge pull request #574 from nuttycom/fix_account_key_init
...
Fix account key init
2022-06-29 21:36:29 +01:00
Kris Nuttycombe
115d4b975e
Don't rely on alignment between account IDs and keys when initializing the accounts table.
2022-06-29 10:13:13 -06:00
Daira Hopwood
dae2e008e9
Merge pull request #577 from daira/bosl-notice
...
Projects that rely on BOSL exceptions should say that they do
2022-06-29 12:59:07 +01:00
Kris Nuttycombe
0142a3db1b
Merge pull request #570 from zcash/387-migrate-from-extfvk-to-ufvk
...
`zcash_client_*`: Migrate from `ExtendedFullViewingKey` to `UnifiedFullViewingKey`
2022-06-28 10:49:37 -06:00
Daira Hopwood
a9aa2929d2
Address feedback about the use of "permissive".
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-06-28 16:46:13 +01:00
Daira Hopwood
75ca854005
Projects that rely on BOSL exceptions should say that they do.
...
fixes #576
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-06-28 12:29:16 +01:00
Jack Grigg
6f4de16b97
zcash_proofs 0.7.0
2022-06-24 17:00:39 +00:00
Jack Grigg
e952ff637e
zcash_primitives 0.7.0
2022-06-24 17:00:39 +00:00
Jack Grigg
b52e949bd6
zcash_client_backend: Migrate to correct ZIP 316 UFVK encoding
...
We also add support for parsing Orchard full viewing keys from encoded
UFVKs (rather than treating them as unknown). `UnifiedSpendingKey` still
does not have Orchard support, so `UnifiedFullViewingKey`s will be
generated without Orchard components.
2022-06-17 10:03:17 +00:00
Jack Grigg
76d015ed11
zcash_client_backend: Fix `UnifiedFullViewingKey` Sapling item type
...
Per ZIP 316, the Sapling FVK Encoding only includes `(ak, nk, ovk, dk)`
which is a subset of the Sapling `ExtendedFullViewingKey`. We therefore
need to use `DiversifiableFullViewingKey` inside `UnifiedFullViewingKey`
in order to make it parseable from the UFVK string encoding.
`zcash_client_sqlite::wallet::get_extended_full_viewing_keys` has been
removed as a consequence of this change: we can no longer reconstruct
the correct `ExtendedFullViewingKey` from the `UnifiedFullViewingKey`.
2022-06-17 10:03:17 +00:00
Jack Grigg
d8b860207d
zcash_client_backend: Remove account from `UnifiedFullViewingKey`
...
The account number is not stored in the ZIP 316 UFVK encoding, and in
general won't necessarily be known (e.g. if a UFVK is being imported
into a wallet).
`zcash_client_sqlite::wallet::init::init_accounts_table` reverts to its
previous behaviour of requiring the provided `&[UnifiedFullViewingKey]`
to be indexed by account number.
2022-06-17 10:03:17 +00:00
Jack Grigg
c0e8ee0fa0
zcash_client_backend: Return UFVKs from `WalletRead` instead of ExtFVKs
2022-06-17 10:03:17 +00:00
Jack Grigg
0d0527dbf3
zcash_client_sqlite: Store UFVK/UA instead of Sapling ExtFVK/address
...
This is a breaking change to the database format. We don't have support
for migrations yet, so existing wallets won't work after this commit
until zcash/librustzcash#489 is done.
2022-06-14 02:18:25 +00:00
Jack Grigg
ed6016857e
zcash_client_backend: Add `RecipientAddress::Unified`
2022-06-10 17:16:59 +00:00
Jack Grigg
1161fc963f
zcash_proofs 0.6.0
2022-05-10 23:33:05 +00:00
Jack Grigg
3ecfd26d79
zcash_primitives 0.6.0
2022-05-10 23:33:05 +00:00
Jack Grigg
144512b547
Migrate to `ff 0.12`
2022-05-06 20:03:49 +00:00
Kris Nuttycombe
9416ab3a3e
Update to secp256k1 v0.21
2022-04-06 16:09:45 -06:00
Jack Grigg
91d9a42a08
Merge branch 'non-consensus-changes-on-branchid-37519621' into merge-non-consensus-changes-3
2022-02-28 23:22:40 +00:00
Kris Nuttycombe
600c06a408
Update MSRV to 1.56.1
2022-02-24 12:26:14 -07:00
str4d
efe63ad62b
Merge pull request #515 from str4d/update-compact-proto
...
zcash_client_backend: Bring in latest `compact_formats.proto`
2022-02-18 00:59:42 +00:00
Jack Grigg
cceae3ac34
zcash_client_backend: Address compact_formats.proto comments
2022-02-17 23:58:20 +00:00
Jack Grigg
18562c71dc
zcash_client_backend: Bring in latest `compact_formats.proto`
...
Source: 83bb19918f/walletrpc/compact_formats.proto
2022-02-17 02:44:20 +00:00
Jack Grigg
511ad71a05
Bump `protobuf` to `~2.27.1`
...
`protobuf 2.26` raised its MSRV to 1.52.1, which we are now above.
`protobuf 2.27.0` raised its MSRV to 1.55.0, but this was reverted in
`protobuf 2.27.1`. In any case, it's clear this dependency bumps MSRV in
minor releases, so we should use tilde requirements for it.
2022-02-15 23:37:52 +00:00
Jack Grigg
f822d7aabc
Bump MSRV to 1.54.0
...
This is the MSRV for the orchard crate version that contains the changes
to the Orchard circuit.
Closes zcash/librustzcash#513 .
2022-02-15 16:39:29 +00:00
Kris Nuttycombe
e20de50b84
Make AccountId internal representation private.
2022-02-10 11:30:02 -07:00
Kris Nuttycombe
a304c3953b
Fix Clippy beta linting complaints.
2022-02-02 16:02:45 -07:00
Kris Nuttycombe
3699a6df97
Fix typos.
2022-02-02 14:00:05 -07:00
Kris Nuttycombe
488d13fde3
Do not delete sent note data in rewind.
2022-02-02 12:48:22 -07:00
Kris Nuttycombe
9c2d485c80
Address comments from code review.
...
Co-authored-by: str4d <jack@electriccoin.co>
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-02-02 10:33:41 -07:00
Kris Nuttycombe
2dd0348792
Remove the `nullifiers` argument from `store_decrypted_tx`
...
This value can be obtained internally within the implementation
of `store_decrypted_tx` and does not need to be part of the
public API.
2022-02-02 10:32:35 -07:00
Kris Nuttycombe
41810e5be9
Merge remote-tracking branch 'upstream/non-consensus-changes-on-branchid-37519621' into autoshield-poc-daa
2022-02-02 10:32:35 -07:00
Kris Nuttycombe
3d51c53d68
Address comments from code review.
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-02-02 10:32:33 -07:00
Kris Nuttycombe
d0e1f98429
Use extension traits for transparent-related data api functionality.
2022-02-02 10:30:43 -07:00
Kris Nuttycombe
5a75c210f0
Fix order of note deletion relative to transactions being un-mined in rewind.
2022-02-02 10:30:07 -07:00
Kris Nuttycombe
e8e5d94ea6
Mark functions that will be made crate-private as deprecated
2022-02-02 10:29:19 -07:00
Jack Grigg
e9ecb19143
Restrict cargo to `protobuf >=2.20,<2.26`
...
`protobuf 2.26.0` bumped its MSRV to 1.52.1, which is incompatible with
our current MSRV.
2022-02-01 14:26:47 +00:00
Kris Nuttycombe
2f1d3da26d
Update changelogs.
2022-01-27 16:25:01 -07:00
Kris Nuttycombe
544c4ed6bb
Remove unused zcash_address dependency.
2022-01-27 16:08:04 -07:00
Kris Nuttycombe
3a20176092
Apply suggestions from code review
...
Co-authored-by: str4d <jack@electriccoin.co>
2022-01-27 15:00:37 -07:00
Kris Nuttycombe
6fcdfda69e
Derive OVKs from transparent account-level key, not child keys.
...
This also renames a number of legacy key types to better reflect
their intended use.
2022-01-26 13:36:27 -07:00
Kris Nuttycombe
47fc12704b
Fix doctest compilation.
2022-01-25 10:01:48 -07:00
Kris Nuttycombe
f58d191439
Move transparent account keys to zcash_primitives.
2022-01-25 08:53:51 -07:00
therealyingtong
6f776aacc3
zcash_primitives::zip316::transparent: Parse Ufvk from zcash_address.
2022-01-22 22:29:45 -07:00
Kris Nuttycombe
15eb5aab50
Fix a minor naming error in AccountPubKey
2022-01-21 19:08:26 -07:00
Kris Nuttycombe
7d873e9d79
Fix test compilation errors related to UFVK construction.
2022-01-21 19:01:32 -07:00
Kris Nuttycombe
8f408354b9
Remove cyclic dev dependency between zcash_client_backend and zcash_client_sqlite.
2022-01-20 21:50:26 -07:00
Kris Nuttycombe
f75ffb0eaf
Document wallet database initialization.
2022-01-20 20:20:58 -07:00
Kris Nuttycombe
79bd2f7733
Add missing documentation & rustfmt.
2022-01-20 20:14:44 -07:00
Kris Nuttycombe
ffc4d0cefb
Add newtypes for transparent keys at the account & external levels.
...
This updates UnifiedFullViewingKey to conform to ZIP 316, and
adds types that facilitate this support. These types should likely
be factored out from `zcash_client_backend` into `zcash_primitives`
along with the remainder of the existing unified address support.
2022-01-20 20:03:20 -07:00
Kris Nuttycombe
37e6d3a2bc
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
Co-authored-by: ying tong <yingtong@z.cash>
2022-01-20 16:43:57 -07:00
Kris Nuttycombe
fc0dd8e3eb
Merge remote-tracking branch 'upstream/master' into autoshield-poc-daa
2021-10-25 13:24:03 -06:00
Kris Nuttycombe
120cc70a6d
Fix type of default_address
2021-10-11 16:34:37 -06:00
Kris Nuttycombe
cc58a21ad7
Feature-flag transparent functionality in zcash_client_sqlite
...
This fixes the wasm32-wasi build issues by excluding the
hdwallet dependencies which are not wasm32-wasi compatible.
2021-10-04 16:53:55 -06:00
Kris Nuttycombe
da3c84ff31
Update hdwallet to depend upon secp256k1-v0.20
2021-10-01 12:52:19 -06:00
Kris Nuttycombe
d43a893c72
Apply suggestions from code review & update changelog
...
Co-authored-by: str4d <jack@electriccoin.co>
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2021-10-01 12:03:06 -06:00
Kris Nuttycombe
d49a20e6d2
Modify WalletTransparentOutput to wrap TxOut directly.
2021-10-01 11:42:04 -06:00
Kris Nuttycombe
6cf0749ac9
Merge remote-tracking branch 'upstream/master' into autoshield-poc-reorder
2021-10-01 11:03:41 -06:00
Kris Nuttycombe
db89569b90
Address documentation & naming requests from code review.
2021-10-01 11:03:09 -06:00
Kris Nuttycombe
2053d7f57b
Always take number of confirmations as a parameter.
2021-10-01 11:00:50 -06:00
Jack Grigg
65e1d32774
ff 0.11, group 0.11, etc.
2021-09-09 18:20:37 +01:00
Kris Nuttycombe
b783c4d0e7
Merge remote-tracking branch 'upstream/master' into autoshield-poc-daa
2021-08-12 11:21:30 -06:00
Jack Grigg
0f15743200
Disable default benchmark harness for all workspace crates
...
This is necessary in order to provide criterion-specific arguments to
`cargo bench`, such as `--profile-time`.
2021-08-05 22:39:36 +01:00
Kris Nuttycombe
1a5aad723b
Use generalized signature_hash for transaction builder.
2021-06-04 15:45:39 -06:00
Kris Nuttycombe
55d1090f70
Add v5 txid & signature hashing.
2021-06-04 15:45:39 -06:00
Jack Grigg
1222391dd7
Migrate to bitvec 0.22, ff 0.10, etc.
...
Requires patching three dependencies:
- bellman is pending a new release.
- nom is part of the funty breakage; we are blocking on a new release.
- orchard is in development.
2021-06-04 22:02:48 +01:00
Kris Nuttycombe
84e8952ec3
Move Sapling components to a bundle within TransactionData
2021-06-03 18:46:38 -06:00
Kris Nuttycombe
76999eb5c7
Make txid contents private & use txid for TzeOutPoint
2021-06-01 07:03:31 -06:00
Kris Nuttycombe
4efb21d1c7
Make amount addition and subtraction traits use checked operations.
2021-06-01 07:03:31 -06:00
Jack Grigg
5623e02a7c
Migrate to ff 0.9 et al.
2021-05-19 18:29:37 +01:00
Kris Nuttycombe
8e3e7de50c
Minor code cleanup.
2021-05-14 14:17:42 -06:00
Kevin Gorham
bd65b01eb3
Remove drop accounts function.
2021-05-07 04:18:45 -04:00
Kevin Gorham
3828a814b5
Relax fk constraints.
2021-05-04 17:37:17 -04:00
Kevin Gorham
5a5100395a
Drop accounts table instead.
...
We need to recreate the table each time it is cleared to handle any migrations. This is mostly a stop-gap measure until the migrations and table creations are handled by the same code.
2021-04-30 23:06:28 -04:00
Kevin Gorham
08a5cfa80b
Add clear function for the accounts table.
2021-04-30 22:45:01 -04:00
Kevin Gorham
74434f370c
Fix: get rewind height when there are no unspent notes.
...
Previously, this function was not properly returning an optional.
2021-04-22 16:26:57 -04:00
Kevin Gorham
7fc2d9725c
Placeholder commit: just get things working.
...
Clean up later but for now don't allow nullable accountIds and also delete more data, during a rewind.
2021-04-20 10:13:47 -04:00
Kevin Gorham
c1bc06964f
Add get_all_nullifiers.
2021-04-16 14:27:18 -06:00
Kevin Gorham
bb68744df1
Ensure that rewinds go far enough to properly restore incremental witness state.
2021-04-16 14:27:18 -06:00
Kris Nuttycombe
9b3025de4d
Add ZIP-321 request based sends to zcash_client_backend.
2021-04-16 14:26:53 -06:00
Kevin Gorham
8e16d93f94
Update accounts table create statement.
...
This PR makes the opinionated change that T-addrs are required
to be supported when using the zcash_client_sqlite backend.
2021-04-16 14:26:53 -06:00
Kevin Gorham
bdf56925e9
Insert into accounts table with taddrs.
2021-04-16 14:26:53 -06:00
Kris Nuttycombe
665c4c7aff
Figure out the account ID for z->t spends.
2021-04-16 14:26:53 -06:00
Kris Nuttycombe
13cd7498b7
Store vout as part of store_decrypted_tx
2021-04-16 14:26:53 -06:00
Kris Nuttycombe
8828276361
Query for unspent utxos checks to ensure that spending tx is mined.
...
Also make it an error to try to send a memo to a transparent address.
2021-04-16 14:26:51 -06:00
Kris Nuttycombe
a3bc1e3e63
Rename get_spendable -> get_unspent
2021-04-16 14:23:28 -06:00
Kris Nuttycombe
862e221a9b
Put transparent dependencies behind a feature flag.
2021-04-16 14:23:26 -06:00