You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
andrewkozlik opened this issue
Mar 21, 2024
· 3 comments
· Fixed by #3710
Assignees
Labels
coreTrezor Core firmware. Runs on Trezor Model T and T2B1.featureProduct related issue visible for end userprotobufStructure of messages exchanged between Trezor and the host
The Shamir backup workflow in Trezor currently requires the user to select the number of shares and the threshold on Trezor. We want to make it possible for Suite to bypass this process and invoke 1-of-1 SLIP-39 backup on Trezor. I see a simple solution and a more generic solution.
Solution 1
Add a new backup type Slip39_Single:
enumBackupType {
Bip39=0; // also called "Single Backup", see BIP-0039Slip39_Basic=1; // also called "Shamir Backup", see SLIP-0039Slip39_Advanced=2; // also called "Super Shamir" or "Shamir with Groups", see SLIP-0039#two-level-schemeSlip39_Single=3; // also called "Single Shamir", see SLIP-0039
}
If Slip39_Single, then the message handlers for BackupDevice and ResetDevice with skip_backup==false will go directly to the seed backup:
Should we go with the three-field representation or the Slip39Group sub-message?
Should we also put the parameters in ResetDevice? I feel we shouldn't, because if skip_backup==true, then it doesn't really make sense or we'd have to store the parameters in storage. Suite defers backup anyway.
Should we be pedantic about not allowing multiple groups when backup type was selected as Slip39_Basic? I don't think we should.
Should there be a confirmation screen on Trezor repeating the numbers of shares and thresholds before backup commences? I think it's not needed.
Further notes
When the Shamir backup is 1-of-1, we shouldn't be showing the Recovery share #1 and Check share #1, just Recovery seed and Check seed like we do in BIP-39 backup. Ideally even if the user manually configures 1-of-1, i.e. special handling in slip39_basic_show_and_confirm_shares() when len(shares) == 1, just show_share_words(share) and await _share_words_confirmed(None, share_words).
The text was updated successfully, but these errors were encountered:
andrewkozlik
added
core
Trezor Core firmware. Runs on Trezor Model T and T2B1.
protobuf
Structure of messages exchanged between Trezor and the host
feature
Product related issue visible for end user
labels
Mar 21, 2024
We will go with solution 2, because we want to allow the user to be able to configure their Shamir backup in Suite. However, we will maintain the option of configuring the Shamir backup parameters in Trezor as well. Thus users who consider the parameters of their backup to be sensitive information will not have to expose them to Suite.
Should we go with the three-field representation or the Slip39Group sub-message?
The Slip39Group sub-message
Should we also put the parameters in ResetDevice?
No.
Should we be pedantic about not allowing multiple groups when backup type was selected as Slip39_Basic?
No. If backup type was set to Slip39_Basic and Suite sends an advanced Shamir backup configuration, then accept the advanced configuration.
Should there be a confirmation screen on Trezor repeating the numbers of shares and thresholds before backup commences?
Yes. We need to let the user know the selected threshold anyway. A confirmation screen for advanced backup should also be implemented, but doesn't need to be neatly designed, because Suite does not support it anyway at the moment.
When a host request this single-share SLIP-39 backup. The flow should be different then standard (multi-share) SLIP-39 backup. The flow should be the same as during BIP-39 backup. See here. So no shares, no groups, no thresholds, different copy, …
coreTrezor Core firmware. Runs on Trezor Model T and T2B1.featureProduct related issue visible for end userprotobufStructure of messages exchanged between Trezor and the host
The Shamir backup workflow in Trezor currently requires the user to select the number of shares and the threshold on Trezor. We want to make it possible for Suite to bypass this process and invoke 1-of-1 SLIP-39 backup on Trezor. I see a simple solution and a more generic solution.
Solution 1
Add a new backup type
Slip39_Single
:If
Slip39_Single
, then the message handlers forBackupDevice
andResetDevice
withskip_backup==false
will go directly to the seed backup:Solution 2
Make it possible for Suite to specify the exact parameters of the Shamir backup. Extend
BackupDevice
with the following parameters:The firmware will check that the following conditions are met:
Bip39
.member_thresholds
must be the same length asmember_counts
.There is no need to do other sanity checks like
group_threshold
being at most the number of groups etc., because that is done bysplit_ems()
.As an alternative:
Similar conditions as in the previous case need to be checked by the firmware.
The
BackupDevice
message handler goes directly to the backup process if the parameters are specified:Slip39Group
sub-message?ResetDevice
? I feel we shouldn't, because ifskip_backup==true
, then it doesn't really make sense or we'd have to store the parameters in storage. Suite defers backup anyway.Slip39_Basic
? I don't think we should.Further notes
Recovery share #1
andCheck share #1
, justRecovery seed
andCheck seed
like we do in BIP-39 backup. Ideally even if the user manually configures 1-of-1, i.e. special handling inslip39_basic_show_and_confirm_shares()
whenlen(shares) == 1
, justshow_share_words(share)
andawait _share_words_confirmed(None, share_words)
.The text was updated successfully, but these errors were encountered: