...
Hm, that's a good opportunity to actually look up the details:
https://github.com/satoshilabs/slips/blob/master/slip-0039.mdA 128-bit entropy is encoded in multiple 200-bit (Shamir Secret Sharing) shards. The individual shards contain a lot more information, making it possible to easily spot if shards belong together and also use a significantly more sophisticated checksum (the last three words of every shard). See
https://github.com/satoshilabs/slips/blob/master/slip-0039.md#format-of-the-share-mnemonic for more details.
Also the
wordlist of SLIP39 is half the size of BIP39, more carefully chosen (first four letters identify each word uniquely), therefore every word encodes only 10 bits instead of 11 bits in BIP39.
So, sort of naturally SLIP39 is therefore quite more verbose. Regarding what SLIP39 tries to achieve, I don't mind it.
The last three words of the mnemonic form a checksum and contain no information.
...
This implements a Reed-Solomon code over GF(1024) that guarantees detection of any error affecting at most 3 words and has less than a 1 in 10
9 chance of failing to detect more errors. More details about the properties can be found in the Checksum Design appendix
5. The customization string is processed by feeding each character's US-ASCII value into the checksum calculation prior to the data.
Regarding your claim that SLIP39 uses less PBKDF2 computational work, I think you're wrong if I understand the SLIP-0039 part correctly about
Encryption of the master secret:
The master secret is encrypted using a wide-blocksize pseudorandom permutation
7 based on the Luby-Rackoff construction. It consists of a four-round Feistel network with the key derivation function PBKDF2
6 as the round function. This scheme is invertible, which means that the creator of the shares can choose the master secret, making it possible to migrate a BIP-32 wallet from BIP-39 mnemonics to the new secret sharing scheme. The master secret is first split into two equally long parts, where
L is the first
n/2 bytes of the master secret and
R is the last
n/2 bytes of the master secret, and processed as follows:
L = MS[:len(S)/2]
R = MS[len(S)/2:]
for i in [0,1,2,3]:
(L, R) = (R, L xor F(i, R))
The encrypted master secret is then
EMS = R || L.
The
i-th round function
F(i, R) is defined as follows:
F(i, R) = PBKDF2(PRF = HMAC-SHA256, Password = (i || passphrase), Salt = (salt_prefix || R), iterations = 2500 << e, dkLen = n/2 bytes)
Because there are four iterations of the Feistel thing, I understand it that SLIP39 actually uses 4x2500=10,000 rounds of PBKDF2.
In above PBKDF2 footnote
6 link this is clearly stated:
...
The total number of iterations in PBKDF2 was chosen to be at least 10000, i.e. 2500 iterations in each of the four rounds of the Feistel-based encryption function. A larger number of iterations in PBKDF2 would currently impact the user experience in hardware wallets. The creator of the shares is free to choose a larger number of iterations, theoretically as high as 327 million, making the format more future-proof and more suitable for a wider range of environments.
SLIP39 skips PBKDF completely and uses the entropy itself as the BIP32 seed!
From my understanding after briefly looking at SLIP-0039, I think you're wrong on both parts.
It seems to me, that a 20-word SLIP39 is much weaker than a 12-word BIP39, because, even though they are both 128-bits of real entropy, BIP39 would be ~2048 times harder to brute-force.
Nope!
Any single 20-word shard doesn't reveal anything of the encrypted secret therein. And you're wrong on the amount of PBKDF2 rounds that are actually used by SLIP39 massaging the master secret to get an encrypted master secret which is packed into SSS.
Hm, is it possible that you deduced your critisism based on this?
SLIP-0039 can be used to back up any master secret S which satisfies the length constraints described above. However, any application implementing SLIP-0039 for backing up a
BIP-0032 Hierarchical Deterministic Wallet MUST use the
BIP-0032 master seed as the SLIP-0039 master secret S. To clarify, this is the initial generated seed byte sequence of 128-512 bits, which is used as the input to
HMAC-SHA512 for deriving the BIP-0032 master node.
This specification is required to ensure that SLIP-0039 backups created in one wallet can be restored in any other wallet that implements SLIP-0039.
I would say this is a special case, but to understand the consequences in more depth I would need more time and look at the actual steps taken. There's really more to look into and not possible by my "brief glance" at SLIP-0039.
Also SSS needs to be very carefully implemented to not fuck up badly. And that's not easy to spot and judge for non-cryptographers.
I'm happy to be corrected if I'm wrong.