Would you like to clone this notebook?

When you clone a notebook you are able to make changes without affecting the original notebook.


Mnemonic with ripple-keypairs, w/o ripplelib

node v8.17.0
version: 2.0.0
const bip39 = require("bip39"); const bip32 = require("ripple-bip32"); const ripple = require('ripple-keypairs') var mnemonic = 'novel matter final only nice cheese address cradle civil crash great flame struggle consider crowd surface purpose saddle mango endless mixed trial tape wrap' // Or generate: // mnemonic = bip39.generateMnemonic() console.log('mnemonic: ' + mnemonic) const seed = bip39.mnemonicToSeed(mnemonic) // add second argument for 25th word encrypted console.log('seed: ', seed) const m = bip32.fromSeedBuffer(seed) console.log('m: ', m) const keyPair = m.derivePath("m/44'/144'/0'/0/0").keyPair.getKeyPairs() const address = ripple.deriveAddress(keyPair.publicKey) console.log('privateKey: ' + keyPair.privateKey) console.log('publicKey: ' + keyPair.publicKey) console.log('address: ' + address)

1 comment

  • posted 2 years ago by phuong
    Hi, how to get the secrect? the ripple-lib use secrect to sign

sign in to comment