Steven Smith
9993d948ef
Load previously persisted sent transaction recipient metadata back into the wallet.
...
This completes some unfinished work from #5549
2022-03-18 08:03:12 -06:00
Kris Nuttycombe
cf84e1e79d
Merge pull request #5699 from nuttycom/feature/wallet_orchard-merge_master
...
Merge master branch back to feature/wallet_orchard
2022-03-17 18:25:28 -06:00
Kris Nuttycombe
80324bc653
Merge remote-tracking branch 'upstream/master' into feature/wallet_orchard-merge_master
2022-03-17 16:52:49 -06:00
Kris Nuttycombe
7cd4462b20
Merge pull request #5695 from str4d/5694-gitian-fix
...
build: Fix `zcash/address/orchard.hpp` filename in `src/Makefile.am`
2022-03-17 16:30:33 -06:00
Kris Nuttycombe
b708b8ef60
Merge pull request #5692 from nuttycom/feature/wallet_orchard-limited_ua_inputs
...
Add UnifiedAddress variant to ZTXOSelector
2022-03-17 13:42:41 -06:00
Jack Grigg
22c6bf88a3
build: Fix `zcash/address/orchard.hpp` filename in `src/Makefile.am`
...
The incorrect extension caused `make distdir-am` to fail due to a
missing rule for the header file.
Closes zcash/zcash#5694 .
2022-03-17 19:38:10 +00:00
Kris Nuttycombe
a783de43e3
Simplify retrieval of unified account by address.
...
Co-authored-by: ying tong <yingtong@z.cash>
2022-03-17 11:38:44 -06:00
Kris Nuttycombe
9582a2c1f1
Eliminate redundancy between the wallet and the keystore.
...
The methods `FindUnifiedFullViewingKey` and `FindUFVKByReceiver`
are implementable with only the information that'a available from
the keystore, so it's better to use the methods that are defined
there in the previous commit.
2022-03-17 11:38:44 -06:00
Kris Nuttycombe
9d8c20ed78
Add UnifiedAddress variant to ZTXOSelector
...
When a user supplies a unified address as the source of funds
for z_sendmany, the previous behavior could have risked user
privacy by spending transparent UTXOs belonging to different
diversified addresses in the same transaction, thereby linking
those addresses, and consequently any diversified shielded
receivers of unified addresses containing those transparent
receivers.
This change limits selection of transparent UTXOs to only those
explicitly associated with the unified receivers of the provided
source UA. Also, if a UA is provided as the source, the behavior
is maintained that only shielded notes in pools corresponding to
the receivers of that UA will be selected.
2022-03-17 11:38:44 -06:00
str4d
12b37d5a11
Merge pull request #5665 from str4d/5657-z_sendmany-orchard-spends
...
Add support for sending Orchard funds in `z_sendmany`
2022-03-16 18:12:56 +00:00
str4d
454e7640f0
Merge pull request #5680 from nuttycom/saplingmigration_explicit_change
...
Explicitly specify the change address in the Sapling migration.
2022-03-16 13:11:02 +00:00
Kris Nuttycombe
b9b471bfa6
Merge pull request #5684 from nuttycom/feature/wallet_orchard-rpc_doc_cleanup
...
Address minor issues from #5605
2022-03-15 21:43:47 -06:00
Kris Nuttycombe
5c9b7ec4df
Merge pull request #5671 from therealyingtong/ua-z_getbalance
...
z_getbalance: Handle Unified Address case.
2022-03-15 19:29:37 -06:00
Kris Nuttycombe
860fc8886a
Update documentation of z_importviewingkey and z_exportviewingkey to address unified keys.
2022-03-15 16:39:26 -06:00
Kris Nuttycombe
482f0e7e44
Return the correct error for `z_getbalance` if a UA does not correspond to an account in the wallet..
...
Also, update the help text for z_getbalance to suggest that the user
prefer z_getbalanceforviewingkey.
Co-authored-by: str4d <thestr4d@gmail.com>
2022-03-15 16:22:05 -06:00
ying tong
1cd92e579c
Style improvements in RPC tests.
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-03-15 16:22:05 -06:00
therealyingtong
c1cd8a7e2d
Adapt RPC tests to use z_getbalance for UAs.
2022-03-15 16:22:05 -06:00
therealyingtong
6caec7aef1
z_getbalance: Handle Unified Address case.
2022-03-15 16:22:05 -06:00
Kris Nuttycombe
235767ba6e
Document that Orchard keys are not supported in z_importkey help
2022-03-15 16:07:37 -06:00
Kris Nuttycombe
24ce54f3ed
Add orchard support to z_getnotescount
2022-03-15 15:49:01 -06:00
Kris Nuttycombe
5d65952f54
Document that z_getnewaccount and z_getaddressforaccount replace z_getnewaddress.
2022-03-15 15:32:06 -06:00
Kris Nuttycombe
1b1495b7d7
Add TODO for Orchard z_listunspent integration.
2022-03-15 15:31:40 -06:00
sasha
2dcaac5fcb
Merge pull request #5574 from daira/zcashd-wallet-tool
...
Make a zcashd-wallet-tool executable
2022-03-15 13:41:55 -07:00
Jack Grigg
381b626a78
Set default Orchard anchor confirmations to 1
...
Currently we cannot use anything greater than 1, because the Orchard
witness tree cannot provide authentication paths to anything but the
current tree root. Once zcash/incrementalmerkletree#22 is implemented,
we can revert this change as part of zcash/zcash#5644 .
2022-03-15 19:53:30 +00:00
Jack Grigg
c2220f4eb9
Add support for sending Orchard funds in `z_sendmany`
...
Closes zcash/zcash#5665 .
2022-03-15 19:53:30 +00:00
Kris Nuttycombe
7ba239e605
Explicitly specify the change address in the Sapling migration.
2022-03-15 10:57:19 -06:00
Jack Grigg
d49c8a2865
Add Orchard to change address generation
2022-03-15 16:41:09 +00:00
Jack Grigg
d4eee99060
Add Orchard cases to note selection logic
2022-03-15 16:41:09 +00:00
Jack Grigg
f2ae807891
Implement opportunistic shielding in `SpendableInputs::LimitToAmount`
...
We now use the total funds in each available pool to figure out whether
a particular desired selection order can provide the requested amount,
and can alter the selection order each time we add another pool.
2022-03-15 16:41:09 +00:00
Jack Grigg
920de99c85
Select spendable inputs based on recipient and change pool types
...
This information enables us to select notes and coins in a way that
minimizes information leakage while moving funds into the shielded pool
where possible.
2022-03-15 16:41:09 +00:00
Jack Grigg
959b068468
Fix bug in `SpendableInputs::LimitToAmount`
...
This method selects inputs by iterating through available notes and
coins until sufficient value is found, and then dropping the remaining
notes and coins. However, the processing of each pool type was gated on
having not selected sufficient funds. This meant that if an earlier pool
had sufficient funds to fill a transaction, later pools would not be
processed at all and their notes would be left as selectable.
2022-03-15 16:41:09 +00:00
Jack Grigg
63437e4c18
Add unit tests for `SpendableInputs::LimitToAmount`
2022-03-15 16:41:09 +00:00
Jack Grigg
f56a04ded2
Refactor `CWallet::GenerateChangeAddressForAccount`
...
There are no functional changes in this commit, but the refactor
separates the legacy account handling, and makes it easier to integrate
new pool types.
We also rename `libzcash::ChangeType` to `OutputPool`, in anticipation
of using it to track transaction recipient pools.
2022-03-15 16:41:09 +00:00
Kris Nuttycombe
c3c5236cee
Merge pull request #5656 from nuttycom/feature/wallet_orchard-note_commitment_tree_ser
...
Add Orchard note commitment tree serialization & restore.
2022-03-14 23:16:44 -06:00
sasha
3a957618b6
Merge pull request #5662 from nuttycom/legacy_seed_to_mnemonic
...
Derive the mnemonic seed from the legacy HD seed, if one is available.
2022-03-14 20:32:09 -07:00
sasha
7071b41c55
Merge pull request #5578 from superbaud/powlimit-document
...
comment explaining the 0x0f0f[..]0f0f powLimit constant for regtest
2022-03-14 18:47:04 -07:00
Kris Nuttycombe
5a98080677
Apply suggestions from code review
...
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-03-14 19:13:25 -06:00
sasha
f37d186e7e
Merge pull request #5600 from superbaud/use-debian-libtinfo
...
remove superfluous space at end of native_packages that i introduced in #5576
2022-03-14 17:06:53 -07:00
ying tong
4d7892bdde
Merge pull request #5649 from therealyingtong/conflicted-orchard-spends
...
Report conflicted Orchard spends
2022-03-15 07:46:02 +08:00
Kris Nuttycombe
e335ff2325
Fix indentation.
2022-03-14 17:40:10 -06:00
Kris Nuttycombe
d420e2efab
Derive the new mnemonic seed from the legacy HD seed, if one is available.
...
Fixes #5572
Co-authored-by: Daira Hopwood <daira@jacaranda.org>
2022-03-14 17:40:04 -06:00
Daira Hopwood
4611493c9d
Merge pull request #5663 from nuttycom/check_master_key_validity
...
Return std::optional<CExtKey> from CExtKey::Master
2022-03-14 17:10:24 +00:00
Daira Hopwood
340840894a
Tweaks to message text.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-03-14 08:24:25 +00:00
Daira Hopwood
6ee6692c83
qa/zcash/full_test_suite.py: enable `test_rpath_runpath` for Rust binaries, and
...
reenable `test_fortify_source` for C++ binaries.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-03-14 08:05:59 +00:00
Daira Hopwood
1d31d4bc7c
Include $(bin_SCRIPTS) in `check-symbols`, `check-security`, and `clean` targets.
...
Checking for stack canaries in `check-security` is disabled for Rust executables
(Rust does support `-Z stack-protector=all` but only for the nightly compiler).
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-03-13 22:53:29 +00:00
Daira Hopwood
55d14faebf
Correct the fallback instruction for how to clear the terminal on macOS: pressing Command + K
...
also clears scrollback.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-03-13 18:25:40 +00:00
Kris Nuttycombe
19bce27321
Merge pull request #5641 from nuttycom/feature/wallet_orchard-restore_orchard_spends
...
Restore Orchard spentness cache in LoadCaches
2022-03-12 14:21:38 -07:00
Kris Nuttycombe
c9938d0348
Update orchard_wallet_add_notes_from_bundle documentation.
2022-03-12 11:46:48 -07:00
Daira Hopwood
ccada66324
Simplify debug tracing.
...
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2022-03-12 12:56:32 +00:00
Kris Nuttycombe
4eda33f184
Serialize the Orchard note commitment tree to the wallet.
...
This adds serialization of Orchard note commitment trees
to `SetBestChain` and deserialization and loading of those
trees to wallet load.
2022-03-11 22:47:37 -07:00