Safe 5 Question

Hi there, quick question, is generating a bip39 seed phrase 100% safe using the safe 5? I noticed it was sorta tucked away in the UI under “Legacy backup types”

Still uses TRNG from the device and host etc, properly tested?

I get it’s somewhat offensive to assume that it might not be working properly but that whole situation with the CC dice issue has me weary that insecure entropy is being used to generate the seed if the TRNG isn’t working properly.

Nothing in the world is “100% safe”.
That said, the BIP-39 generation process is exactly as good as the SLIP-39 one. (There would be no reason to break what’s been working fine for years.)

I was not aware of any CC dice issue before this post – do you mean that thing where users were allowed to generate a seed with not nearly enough dice rolls? That seems very unrelated to what happens when the users don’t try to mess with the process ;)

Yeah basically the user only used 1 dice roll for the seed generation so the random.seed function produced a predictable mnemonic. Also are you the CEO of Trezor? Your names are similar, would be pretty cool if you’re the active on the forum.

Thanks for the quick reply.

I’m not the CEO, but you’re not the first to get confused :slight_smile:

Final question, how does Trezor secure their singing key for the firmware? Are there multisignature requirements for signing? I would hope this done via physical devices as well.

1 Like

Firmware is signed by a 2-of-3 scheme by two people with two separate physical Trezors. We do eat our own dog food here.

3 Likes

Do you mind linking the code of how Trezor gathers entropy for seed generation? Can’t seem to find it on the github.

Specifically the code that converts entropy to mnemonic on the Safe 5

nvm tested via trezor ctl with this command
trezorctl -v device setup --show-entropy -b bip39

this is the raw entropy correct? not some digested hash?

this is how a mnemonic is generated from the entropy:

it’s a pretty straightforward implementation of the BIP-39 spec

as for how the entropy is gathered, here’s some code:

and here’s some accompanying explanation I typed up earlier: What library does Trezor use?

You’ll see the “external” entropy in the verbose output (as a content of EntropyAck message), and the “internal” entropy shown on the Trezor screen.
Then you can use the following script to check that the seed comes out right: trezor-firmware/python/tools/mnemonic_check.py at main · trezor/trezor-firmware · GitHub

Awesome, exactly what I wanted to hear.

If you don’t trust the seed generation process,
you could create a seed by yourself with a printed out BIP39 or SLIP39 list and 5 dices

How to generate checksum of the seed with dices?

You can dice 23 words, put them in the Trezor and trust the Trezor only for the checksum.