tremove deterministic derivation for testing - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit d789f1189838749b3cc1099bb50539258de7db05 DIR parent e6d680ec1bec8d6d091403dd48780957cece7987 HTML Author: ThomasV <thomasv@electrum.org> Date: Sat, 26 Jan 2019 18:15:51 +0100 remove deterministic derivation for testing Diffstat: M electrum/lnworker.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) --- DIR diff --git a/electrum/lnworker.py b/electrum/lnworker.py t@@ -211,13 +211,9 @@ class LNWorker(PrintError): def _read_ln_keystore(self) -> BIP32_KeyStore: xprv = self.wallet.storage.get('lightning_privkey2') if xprv is None: - if not self.config.debug_lightning: - # TODO derive this deterministically from wallet.keystore at keystore generation time - # probably along a hardened path ( lnd-equivalent would be m/1017'/coinType'/ ) - seed = os.urandom(32) - else: - # dangerous deterministic secret for testing - seed = sha256(self.config.electrum_path()) + # TODO derive this deterministically from wallet.keystore at keystore generation time + # probably along a hardened path ( lnd-equivalent would be m/1017'/coinType'/ ) + seed = os.urandom(32) xprv, xpub = bip32_root(seed, xtype='standard') self.wallet.storage.put('lightning_privkey2', xprv) self.wallet.storage.write()