|
|
@ -37,9 +37,28 @@ if mode=="new": |
|
|
|
|
|
|
|
elif mode=="seed": |
|
|
|
|
|
|
|
print("err='TODO: implement creating from seed'") |
|
|
|
if len(sys.argv)>2: |
|
|
|
walletpassword=sys.argv[2] |
|
|
|
if len(walletpassword)<8: |
|
|
|
print("err='wallet password is too short'") |
|
|
|
sys.exit(1) |
|
|
|
else: |
|
|
|
print("err='not correct amount of parameter'") |
|
|
|
sys.exit(1) |
|
|
|
|
|
|
|
if len(sys.argv)>3: |
|
|
|
seedwordString=sys.argv[3] |
|
|
|
seedwords=seedwordString.split(",") |
|
|
|
if len(seedwords)<24: |
|
|
|
print("err='not 24 seed words seperated by just commas'") |
|
|
|
sys.exit(1) |
|
|
|
else: |
|
|
|
print("err='not correct amount of parameter'") |
|
|
|
sys.exit(1) |
|
|
|
|
|
|
|
if len(sys.argv)>4: |
|
|
|
seedpassword=sys.argv[4] |
|
|
|
|
|
|
|
elif mode=="scb": |
|
|
|
|
|
|
|
print("err='TODO: implement creating from seed/scb'") |
|
|
@ -99,28 +118,6 @@ if mode=="new": |
|
|
|
|
|
|
|
elif mode=="seed": |
|
|
|
|
|
|
|
if len(sys.argv)>2: |
|
|
|
walletpassword=sys.argv[2] |
|
|
|
if len(walletpassword)<8: |
|
|
|
print("err='wallet password is too short'") |
|
|
|
sys.exit(1) |
|
|
|
else: |
|
|
|
print("err='not correct amount of parameter'") |
|
|
|
sys.exit(1) |
|
|
|
|
|
|
|
if len(sys.argv)>3: |
|
|
|
seedwordString=sys.argv[3] |
|
|
|
seedwords=seedwordString.split(",") |
|
|
|
if len(seedwords)<24: |
|
|
|
print("err='not 24 seed words seperated by just commas'") |
|
|
|
sys.exit(1) |
|
|
|
else: |
|
|
|
print("err='not correct amount of parameter'") |
|
|
|
sys.exit(1) |
|
|
|
|
|
|
|
if len(sys.argv)>4: |
|
|
|
seedpassword=sys.argv[4] |
|
|
|
|
|
|
|
request = ln.InitWalletRequest( |
|
|
|
wallet_password=walletpassword, |
|
|
|
cipher_seed_mnemonic=seedwords, |
|
|
|