diff --git a/Cargo.lock b/Cargo.lock index 14a81bc501..93c0449c55 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1132,7 +1132,7 @@ version = "3.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "faf9468729b8cbcea668e36183cb69d317348c2e08e994829fb56ebfdfbaac34" dependencies = [ - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -1550,7 +1550,7 @@ dependencies = [ [[package]] name = "dash-network" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "bincode", "bincode_derive", @@ -1561,7 +1561,7 @@ dependencies = [ [[package]] name = "dash-network-seeds" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "dash-network", ] @@ -1638,7 +1638,7 @@ dependencies = [ [[package]] name = "dash-spv" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "async-trait", "chrono", @@ -1667,7 +1667,7 @@ dependencies = [ [[package]] name = "dashcore" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "anyhow", "base64-compat", @@ -1693,12 +1693,12 @@ dependencies = [ [[package]] name = "dashcore-private" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" [[package]] name = "dashcore-rpc" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "dashcore-rpc-json", "hex", @@ -1711,7 +1711,7 @@ dependencies = [ [[package]] name = "dashcore-rpc-json" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "bincode", "dashcore", @@ -1726,7 +1726,7 @@ dependencies = [ [[package]] name = "dashcore_hashes" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "bincode", "dashcore-private", @@ -2261,7 +2261,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -2636,7 +2636,7 @@ dependencies = [ [[package]] name = "git-state" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" [[package]] name = "glob" @@ -3298,7 +3298,7 @@ dependencies = [ "libc", "percent-encoding", "pin-project-lite", - "socket2 0.6.3", + "socket2 0.5.10", "system-configuration", "tokio", "tower-service", @@ -3549,7 +3549,7 @@ checksum = "3640c1c38b8e4e43584d8df18be5fc6b0aa314ce6ebf51b53313d4306cca8e46" dependencies = [ "hermit-abi", "libc", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -3780,7 +3780,7 @@ dependencies = [ [[package]] name = "key-wallet" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "aes", "async-trait", @@ -3808,7 +3808,7 @@ dependencies = [ [[package]] name = "key-wallet-ffi" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "cbindgen 0.29.2", "dash-network", @@ -3824,7 +3824,7 @@ dependencies = [ [[package]] name = "key-wallet-manager" version = "0.43.0" -source = "git+https://github.com/dashpay/rust-dashcore?rev=f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc#f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" +source = "git+https://github.com/dashpay/rust-dashcore?rev=a4b3774758a065e228aee19cecb209356a2f507e#a4b3774758a065e228aee19cecb209356a2f507e" dependencies = [ "async-trait", "bincode", @@ -5101,7 +5101,7 @@ version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "343d3bd7056eda839b03204e68deff7d1b13aba7af2b2fd16890697274262ee7" dependencies = [ - "heck 0.5.0", + "heck 0.4.1", "itertools 0.14.0", "log", "multimap", @@ -5266,7 +5266,7 @@ dependencies = [ "quinn-udp", "rustc-hash 2.1.2", "rustls", - "socket2 0.6.3", + "socket2 0.5.10", "thiserror 2.0.18", "tokio", "tracing", @@ -5304,9 +5304,9 @@ dependencies = [ "cfg_aliases", "libc", "once_cell", - "socket2 0.6.3", + "socket2 0.5.10", "tracing", - "windows-sys 0.59.0", + "windows-sys 0.52.0", ] [[package]] @@ -6028,7 +6028,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys 0.4.15", - "windows-sys 0.59.0", + "windows-sys 0.52.0", ] [[package]] @@ -6041,7 +6041,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys 0.12.1", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -6100,7 +6100,7 @@ dependencies = [ "security-framework", "security-framework-sys", "webpki-root-certs", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -6940,7 +6940,7 @@ dependencies = [ "getrandom 0.4.2", "once_cell", "rustix 1.1.4", - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] @@ -8342,7 +8342,7 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" dependencies = [ - "windows-sys 0.61.2", + "windows-sys 0.52.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 58fbcf368b..05cdb042a6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -49,14 +49,14 @@ members = [ ] [workspace.dependencies] -dashcore = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -dash-network-seeds = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -dash-spv = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -key-wallet = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -key-wallet-ffi = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -dash-network = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } -dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", rev = "f569e7b7b99dfe589c41f9ba7d36fbbe6805acdc" } +dashcore = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +dash-network-seeds = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +dash-spv = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +key-wallet = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +key-wallet-ffi = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +dash-network = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } +dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", rev = "a4b3774758a065e228aee19cecb209356a2f507e" } # Optimize heavy crypto crates even in dev/test builds so that # Halo 2 proof generation and verification run at near-release speed. diff --git a/packages/rs-platform-wallet/src/manager/wallet_lifecycle.rs b/packages/rs-platform-wallet/src/manager/wallet_lifecycle.rs index 51335dcca6..6501901121 100644 --- a/packages/rs-platform-wallet/src/manager/wallet_lifecycle.rs +++ b/packages/rs-platform-wallet/src/manager/wallet_lifecycle.rs @@ -79,12 +79,13 @@ impl PlatformWalletManager

{ ) -> Result, PlatformWalletError> { let mnemonic = parse_mnemonic_any_language(mnemonic_phrase) .map_err(|e| PlatformWalletError::WalletCreation(format!("Invalid mnemonic: {}", e)))?; - let wallet = Wallet::from_mnemonic(mnemonic, network, accounts).map_err(|e| { + let mut wallet = Wallet::from_mnemonic(mnemonic, network, accounts).map_err(|e| { PlatformWalletError::WalletCreation(format!( "Failed to create wallet from mnemonic: {}", e )) })?; + wallet.downgrade_to_external_signable(); self.register_wallet(wallet, birth_height_override).await } @@ -104,12 +105,13 @@ impl PlatformWalletManager

{ accounts: WalletAccountCreationOptions, birth_height_override: Option, ) -> Result, PlatformWalletError> { - let wallet = Wallet::from_seed_bytes(seed_bytes, network, accounts).map_err(|e| { + let mut wallet = Wallet::from_seed_bytes(seed_bytes, network, accounts).map_err(|e| { PlatformWalletError::WalletCreation(format!( "Failed to create wallet from seed bytes: {}", e )) })?; + wallet.downgrade_to_external_signable(); self.register_wallet(wallet, birth_height_override).await }