add Auth Encrypted WIF feature
Created by: Tortue95
Merge request reports
Activity
Filter activity
70 75 71 76 72 77 def auth_by_wif(): 73 wif = input("Please enter your WIF address: ") 74 seed = get_seed_from_wif(wif) 75 return seed 78 wif = input("Please enter your WIF or Encrypted WIF address: ") 79 80 regex = re.compile('^[1-9A-HJ-NP-Za-km-z]*$') 81 if not re.search(regex, wif): 82 print("Error: the format of WIF is invalid") 83 exit(1) 84 Created by: Tortue95
For testing: https://duniter.tednet.fr/paperwallet/address_tools.html
70 75 71 76 72 77 def auth_by_wif(): 73 wif = input("Please enter your WIF address: ") 74 seed = get_seed_from_wif(wif) 75 return seed 78 wif = input("Please enter your WIF or Encrypted WIF address: ") 79 80 regex = re.compile('^[1-9A-HJ-NP-Za-km-z]*$') 81 if not re.search(regex, wif): 82 print("Error: the format of WIF is invalid") 83 exit(1) 84 86 88 fi = wif_bytes[0:1] 87 89 88 90 if fi == b'\x01': 89 return get_seed_from_wif(wif) 91 return get_seed_from_wifv1(wif) 90 92 elif fi == b'\x02': 91 password = getpass.getpass("Please enter the password of WIF (masked): ") 92 return get_seed_from_ewif(wif,password) 93 password = getpass.getpass("Please enter the " + 173 182 for c in s: 174 183 n *= 58 175 184 if c not in b58_digits: 176 raise InvalidBase58Error('Character %r is not a valid base58 character' % c) 185 raise InvalidBase58Error('Character %r is not a ' + 173 182 for c in s: 174 183 n *= 58 175 184 if c not in b58_digits: 176 raise InvalidBase58Error('Character %r is not a valid base58 character' % c) 185 raise InvalidBase58Error('Character %r is not a ' + 173 182 for c in s: 174 183 n *= 58 175 184 if c not in b58_digits: 176 raise InvalidBase58Error('Character %r is not a valid base58 character' % c) 185 raise InvalidBase58Error('Character %r is not a ' + 173 182 for c in s: 174 183 n *= 58 175 184 if c not in b58_digits: 176 raise InvalidBase58Error('Character %r is not a valid base58 character' % c) 185 raise InvalidBase58Error('Character %r is not a ' + added Feature label
Please register or sign in to reply