getpubkeys command
This commit is contained in:
@@ -42,6 +42,8 @@ class Account(object):
|
||||
def get_address(self, for_change, n):
|
||||
pass
|
||||
|
||||
def get_pubkeys(self, sequence):
|
||||
return [ self.get_pubkey( *sequence )]
|
||||
|
||||
|
||||
|
||||
@@ -182,6 +184,8 @@ class BIP32_Account_2of2(BIP32_Account):
|
||||
address = hash_160_to_bc_address(hash_160(self.redeem_script((for_change, n)).decode('hex')), 5)
|
||||
return address
|
||||
|
||||
def get_pubkeys(self, sequence):
|
||||
return [ self.get_pubkey( *sequence ), self.get_pubkey2( *sequence )]
|
||||
|
||||
class BIP32_Account_2of3(BIP32_Account_2of2):
|
||||
|
||||
@@ -212,4 +216,8 @@ class BIP32_Account_2of3(BIP32_Account_2of2):
|
||||
pubkey3 = self.get_pubkey3(chain, i)
|
||||
return Transaction.multisig_script([pubkey1, pubkey2, pubkey3], 3)
|
||||
|
||||
def get_pubkeys(self, sequence):
|
||||
return [ self.get_pubkey( *sequence ), self.get_pubkey2( *sequence ), self.get_pubkey3( *sequence )]
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user