tallow shorter than 24 word old 2fa seeds - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 00b2af41c9e434ab1b862b5efc2f5f4260228c15 DIR parent 864706574bacc3f3564f30a18b178066fbfde009 HTML Author: SomberNight <somber.night@protonmail.com> Date: Wed, 2 May 2018 14:52:32 +0200 allow shorter than 24 word old 2fa seeds related: #3611 Diffstat: M plugins/trustedcoin/trustedcoin.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) --- DIR diff --git a/plugins/trustedcoin/trustedcoin.py b/plugins/trustedcoin/trustedcoin.py t@@ -418,7 +418,10 @@ class TrustedCoinPlugin(BasePlugin): words = seed.split() n = len(words) # old version use long seed phrases - if n >= 24: + if n >= 20: + # note: pre-2.7 2fa seeds were typically 24-25 words, however they + # could probabilistically be arbitrarily shorter due to a bug. (see #3611) + # the probability of it being < 20 words is about 2^(-(256+12-19*11)) = 2^(-59) assert passphrase == '' xprv1, xpub1 = self.get_xkeys(' '.join(words[0:12]), '', "m/") xprv2, xpub2 = self.get_xkeys(' '.join(words[12:]), '', "m/")