Compare commits
base: sneak:c951028837f62b99beec35b7f53662a0f7b6640e
sneak:main
sneak:issue-259-e2e-in-ci
sneak:issue-275-site-approval-race
sneak:issue-188-dod-assertions
sneak:issue-152-eslint
sneak:next
sneak:issue-271-concurrent-nonce
sneak:issue-280-handlerpc-catch
sneak:fix/issue-153-browser-api-compat
sneak:chore/token-list-enrichment
sneak:feat/issue-131-transaction-view-layout
sneak:fix/116-timestamps-include-timezone
sneak:feature/expanded-warnings
sneak:fix/cross-wallet-duplicate-detection
sneak:feature/copy-flash-feedback
sneak:feature/issue-82-new-address-warning
sneak:feature/82-warn-new-address
sneak:issue-99-block-number-external-link
sneak:issue-99-block-number-styling
sneak:feature/82-zero-history-warning
sneak:fix/issue-99-block-number-link-copy
sneak:fix/99-block-number-clickable
sneak:fix/87-consistent-error-display-v2
sneak:fix/87-consistent-error-display
sneak:fix/consistent-error-display
sneak:fix/77-confirm-tx-persist
sneak:fix/issue-72-address-token-tx-history
sneak:fix/70-confirm-tx-contract-display
sneak:fix/issue-58-receive-address-consistency
sneak:fix/59-transaction-view-ui-policies
sneak:fix/55-swap-show-own-address
sneak:feature/show-private-key
sneak:feat/message-signing
..
compare: sneak:ad34fa8699387d619e400cafbac38cedc1b86f71
sneak:issue-259-e2e-in-ci
sneak:issue-275-site-approval-race
sneak:issue-188-dod-assertions
sneak:issue-152-eslint
sneak:next
sneak:issue-271-concurrent-nonce
sneak:issue-280-handlerpc-catch
sneak:fix/issue-153-browser-api-compat
sneak:main
sneak:chore/token-list-enrichment
sneak:feat/issue-131-transaction-view-layout
sneak:fix/116-timestamps-include-timezone
sneak:feature/expanded-warnings
sneak:fix/cross-wallet-duplicate-detection
sneak:feature/copy-flash-feedback
sneak:feature/issue-82-new-address-warning
sneak:feature/82-warn-new-address
sneak:issue-99-block-number-external-link
sneak:issue-99-block-number-styling
sneak:feature/82-zero-history-warning
sneak:fix/issue-99-block-number-link-copy
sneak:fix/99-block-number-clickable
sneak:fix/87-consistent-error-display-v2
sneak:fix/87-consistent-error-display
sneak:fix/consistent-error-display
sneak:fix/77-confirm-tx-persist
sneak:fix/issue-72-address-token-tx-history
sneak:fix/70-confirm-tx-contract-display
sneak:fix/issue-58-receive-address-consistency
sneak:fix/59-transaction-view-ui-policies
sneak:fix/55-swap-show-own-address
sneak:feature/show-private-key
sneak:feat/message-signing
1 Commits
c951028837
...
ad34fa8699
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
ad34fa8699 |
feat: password-gated recovery phrase display for HD wallets (closes #161)
Some checks failed
check / check (push) Has been cancelled
A user who created a wallet in AutistMask and did not write the phrase
down had no way to retrieve it. Adds a "Show recovery phrase" action on
the wallet row in Settings, next to the per-wallet actions that already
live there, mirroring the per-address private key export in structure,
password gate and warning treatment.
The screen displays the secret that owns every address in the wallet, so:
- Only HD wallets are offered it. walletHasRecoveryPhrase() is an
allowlist on type "hd", so the key and xprv types — which have no
phrase at all — are excluded, as is any type added later.
- Nothing is decrypted and nothing enters the page until
decryptWithPassword accepts the password. A wrong password produces a
full-sentence error and leaves the value node empty.
- Leaving the screen wipes it by any route, not just "Back": views that
hold a secret register a cleanup with showView() via onViewLeave(),
which also covers the settings gear.
- The phrase is never assigned to state, so it cannot be persisted, and
the view is not in RESTORABLE_VIEWS — reopening the popup lands on
Home. That set moves to src/popup/restorableViews.js so the exclusion
can be asserted directly; the popup entry point cannot be required
outside a browser.
- The phrase cannot reach the logger: the view does not import
src/shared/log.js, and the failed-decrypt path reports a fixed
sentence rather than the caught error.
Tests: unit coverage for the type gate, the RESTORABLE_VIEWS exclusion
and the absence of any logger path; the DOM behaviour is driven against
the real popup in the e2e suite, which is where this repo tests views.
|