Skip to content

Instantly share code, notes, and snippets.

@Anderson-Juhasc
Created September 4, 2015 01:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Anderson-Juhasc/26b297fc5d51e2b6b42c to your computer and use it in GitHub Desktop.
Save Anderson-Juhasc/26b297fc5d51e2b6b42c to your computer and use it in GitHub Desktop.
var Bitcore = require('bitcore');
var Address = Bitcore.Address;
var HDPrivateKey = Bitcore.HDPrivateKey;
var hdPrivateKey = new HDPrivateKey.fromSeed("bf8e06fd8c0dafbc831933422895ad68c0874439e177f136f8f756b360de94f8");
var hdPublicKey = hdPrivateKey.hdPublicKey;
var address = new Address(hdPublicKey.derive( Math.floor(Date.now() / 1000) ).publicKey);
var derivedAddress = new Address(hdPublicKey.derive( Math.floor(Date.now() / 1000) ).publicKey);
console.log(address);
console.log(derivedAddress);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment