Skip to content

Commit

Permalink
Merge a11e308 into 4c3d6db
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan X. Charles committed Jun 11, 2014
2 parents 4c3d6db + a11e308 commit 5c14a7c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions examples/HierarchicalKey.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,16 +57,16 @@ var run = function() {
console.log('6) Make a bunch of new addresses from known public key');
var knownPublicKey = 'xpub6CZei1p2zk68UwkcBDqzRonLHJWAiPZZ58sMgHJAn9fmpmnPayVEAvAs3XvTSUMZ1J8dNaxnv4wnt7YpRKr6BsqeWbW8msqeuuhiSzsQEC3';
var hkey = new HierarchicalKey(knownPublicKey);
console.log('m/0 address: ' + new Address(networks['livenet'].addressVersion, hkey.derive('m/0').eckey.public).toString());
console.log('m/0 address: ' + Address.fromPubKey(hkey.derive('m/0').eckey.public).toString());
//console.log('m/1 extended public key: ' + hkey.derive('m/1').extendedPublicKeyString());
console.log('m/1 address: ' + new Address(networks['livenet'].addressVersion, hkey.derive('m/1').eckey.public).toString());
console.log('m/1 address: ' + Address.fromPubKey(hkey.derive('m/1').eckey.public).toString());
//console.log('m/2 extended public key: ' + hkey.derive('m/2').extendedPublicKeyString());
console.log('m/2 address: ' + new Address(networks['livenet'].addressVersion, hkey.derive('m/2').eckey.public).toString());
console.log('m/2 address: ' + Address.fromPubKey(hkey.derive('m/2').eckey.public).toString());
//console.log('m/3 extended public key: ' + hkey.derive('m/3').extendedPublicKeyString());
console.log('m/3 address: ' + new Address(networks['livenet'].addressVersion, hkey.derive('m/3').eckey.public).toString());
console.log('m/3 address: ' + Address.fromPubKey(hkey.derive('m/3').eckey.public).toString());
console.log('...');
//console.log('m/100 extended public key: ' + hkey.derive('m/100').extendedPublicKeyString());
console.log('m/100 address: ' + new Address(networks['livenet'].addressVersion, hkey.derive('m/100').eckey.public).toString());
console.log('m/100 address: ' + Address.fromPubKey(hkey.derive('m/100').eckey.public).toString());
console.log();

};
Expand Down

0 comments on commit 5c14a7c

Please sign in to comment.