1
0

Extend Wallet Import Format with txin type. Extend class Imported_Wallet.

This commit is contained in:
ThomasV
2017-09-25 21:35:14 +02:00
parent 4864c802dd
commit e8b564c0e7
10 changed files with 243 additions and 161 deletions

View File

@@ -137,11 +137,19 @@ def run_non_RPC(config):
wallet = Imported_Wallet(storage)
for x in text.split():
wallet.import_address(x)
elif keystore.is_private_key_list(text):
k = keystore.Imported_KeyStore({})
storage.put('keystore', k.dump())
storage.put('use_encryption', bool(password))
wallet = Imported_Wallet(storage)
for x in text.split():
wallet.import_private_key(x, password)
storage.write()
else:
if keystore.is_seed(text):
k = keystore.from_seed(text, passphrase)
elif keystore.is_any_key(text):
k = keystore.from_keys(text)
elif keystore.is_master_key(text):
k = keystore.from_master_key(text)
else:
sys.exit("Error: Seed or key not recognized")
if password: