Repository navigation
fix(seed_views): prevent crash when exporting multisig xpub with taproot (fixes #982) - #1068
Open
muskan-creates352 wants to merge 1 commit into
Open
muskan-creates352 wants to merge 1 commit into
muskan-creates352 wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #982
###Description
In 0.8.7, attempting to export a Multisig extended public key (Export Xpub -> Multisig) allows users to select Taproot as a script type if Taproot is enabled in Settings. However, Taproot multisig standard derivation is not yet implemented in SeedSigner (BIP-48 only defines script types 1' for nested segwit and 2' for native segwit).
When selected, SeedSigner proceeds through the QR format and privacy warning screens, and then fatally crashes on SeedExportXpubDetailsView with a Red Screen System Error:
Exception: embit_utils.py, 53, in get_standard_derivation_path Taproot multisig not yet supported
Changes Made
SeedExportXpubScriptTypeView:SettingsConstants.TAPROOTfrom available standard script types whenself.sig_type == SettingsConstants.MULTISIG.NotYetImplementedViewrather than presenting an empty list or crashing.SeedExportXpubDetailsView:embit_utils.get_standard_derivation_path()in defensive exception handling to redirect toNotYetImplementedViewrather than bubbling up an unhandled exception to the main controller loop.tests/test_flows_seed.py):test_export_xpub_multisig_excludes_taproot: verified that selecting Taproot for multisig raisesFlowTestInvalidButtonDataSelectionExceptionbecause Taproot is omitted from the button options.test_export_xpub_multisig_when_only_taproot_enabled: verified graceful redirection toNotYetImplementedView.test_export_xpub_details_unsupported_path_handling: verified graceful handling of unsupported paths inSeedExportXpubDetailsView.