Creating a multisignature bitcoin address
A multisignature address is an address that is associated with more than one private key; therefore, we need to create three private keys.
Go through the following steps to create a multisignature bitcoin address:
- Create three private keys:
#!/usr/bin/env python ''' Title - Create multi-signature address This program demonstrates the creation of Multi-signature bitcoin address. ''' # import bitcoin from bitcoin import * # Create Private Keys my_private_key1 = random_key() my_private_key2 = random_key() my_private_key3 = random_key() print("Private Key1: %s" % my_private_key1) print("Private Key2: %s" % my_private_key2) print("Private Key3: %s" % my_private_key3) print('\n')
- Create three public keys from those private keys using the
privtopub
function:
# Create Public keys my_public_key1 = privtopub(my_private_key1) my_public_key2 = privtopub(my_private_key2) my_public_key3 = privtopub(my_private_key3) print("Public Key1: %s" % my_public_key1) print...