29 Commits

Author SHA1 Message Date
r4bbit
a3983f5a89
fix(wallet): use cryptographically secure entropy for mnemonic generation
The mnemonic/wallet generation was using a constant zero-byte array for entropy ([0u8; 32]), making all wallets deterministic based
solely on the password. This commit introduces proper random entropy using OsRng and enables users to back up their recovery phrase.

Changes:

- SeedHolder::new_mnemonic() now uses OsRng for 256-bit random entropy and returns the generated mnemonic
- Added SeedHolder::from_mnemonic() to recover a wallet from an existing mnemonic phrase
- WalletChainStore::new_storage() returns the mnemonic for user backup
- Added WalletChainStore::restore_storage() for recovery from a mnemonic
- WalletCore::new_init_storage() now returns the mnemonic
- Renamed reset_storage to restore_storage, which accepts a mnemonic for recovery
- CLI displays the recovery phrase when a new wallet is created
- RestoreKeys command now prompts for the mnemonic phrase via read_mnemonic_from_stdin()

Note: The password parameter is retained for future storage encryption but is no longer used in seed derivation (empty passphrase is used
 instead). This means the mnemonic alone is sufficient to recover accounts.

Usage:

On first wallet initialization, users will see:
IMPORTANT: Write down your recovery phrase and store it securely.
This is the only way to recover your wallet if you lose access.

Recovery phrase:
  word1 word2 word3 ... word24

To restore keys:
wallet restore-keys --depth 5
Input recovery phrase: <24 words>
Input password: <password>
2026-02-17 13:06:38 +01:00
Daniil Polyakov
7296088005 feat: introduce parallel integration tests, wallet without global vars and etc 2025-12-31 04:30:22 +03:00
Sergio Chouhy
8c92a58bbc add program deployment examples 2025-12-11 20:59:37 -03:00
Daniil Polyakov
6b26811229 feat: implement multiple blocks polling 2025-12-04 14:55:45 +03:00
Daniil Polyakov
ea9c659fb1 refactor: rename Address to AccountId 2025-11-25 21:38:07 +03:00
Pravdyvy
e44c0a8250 Merge branch 'main' into Pravdyvy/wallet-personalization 2025-11-19 14:05:20 +02:00
Sergio Chouhy
343f8c4864 Merge branch 'main' into schouhy/add-sequencer-tps-test 2025-11-03 13:47:57 -03:00
Oleksandr Pravdyvyi
9d31b143ed
feat: config command added 2025-11-03 15:45:50 +02:00
Sergio Chouhy
c47693b9b0 add tps integration test 2025-10-24 16:17:00 -03:00
Oleksandr Pravdyvyi
0384efc38f
fix: base58 adoption fixes 2025-10-24 11:12:32 +03:00
Sergio Chouhy
ba20728f40 update version tags in domain separator 2025-10-16 16:19:03 -03:00
Sergio Chouhy
86f61e5ac9 fix impl 2025-10-02 08:40:52 -03:00
Sergio Chouhy
a00773d5aa wip 2025-09-30 17:14:09 -03:00
Oleksandr Pravdyvyi
0e5087ca8f
fix: tests run 1 2025-09-24 16:44:03 +03:00
Oleksandr Pravdyvyi
a7c60a56b7
fix: try unify program id 2025-09-24 14:29:56 +03:00
Oleksandr Pravdyvyi
76d374a453
fix: first integration test for privacy-preserving tx 2025-09-19 15:03:01 +03:00
Oleksandr Pravdyvyi
0e720dd9d3
fix: configs and tests updates 2025-09-18 15:59:17 +03:00
Oleksandr Pravdyvyi
f1de182ec6
fix: tests fix 2025-09-17 13:57:31 +03:00
Oleksandr Pravdyvyi
b4f21b2f09
fix: checks added 2025-09-03 10:29:51 +03:00
Oleksandr Pravdyvyi
41af90e2eb
fix: tests addded-fixed 2025-08-22 15:58:43 +03:00
Oleksandr Pravdyvyi
80620b6aac
fix: wallet fix 2025-08-19 14:14:09 +03:00
Oleksandr Pravdyvyi
939553cc85
fix: structural upgrades finalized 2025-08-13 13:42:00 +03:00
Sergio Chouhy
df78d5f162 fix integration tests 2025-08-13 02:25:19 -03:00
Sergio Chouhy
96b256bd4c Merge branch 'main' into schouhy/implement-nssa-v0.1-public-state-tmp 2025-08-11 09:08:06 -03:00
Oleksandr Pravdyvyi
c3b5d62ea6
fix: comments fix 2025-08-11 08:55:08 +03:00
Sergio Chouhy
20a7dad9a0 Merge branch 'Pravdyvy/node-wallet-rewrite' into schouhy/implement-nssa-v0.1-public-state-tmp 2025-08-09 18:00:58 -03:00
Oleksandr Pravdyvyi
c5097ab879
fix: cli added 2025-08-06 14:56:58 +03:00
Oleksandr Pravdyvyi
6df4a04f84
feat: first scenario implemented 2025-07-30 14:01:40 +03:00
Oleksandr Pravdyvyi
d181ce73e6
fix: node and sequencer startup 2025-07-28 16:31:43 +03:00