2

I am using conseiljs.TezosWalletUtil to generate key value pair.

const mnemonic = conseiljs.TezosWalletUtil.generateMnemonic();
  console.log(`mnemonic: ${mnemonic}`);
  const keystore = await conseiljs.TezosWalletUtil.unlockIdentityWithMnemonic(
    mnemonic,
    ""
  );
  console.log("keystore", keystore)

Output

mnemonic: occur cinnamon giraffe recycle volcano disease fan labor park casual water canal keen foil rival position screen pride uncover solve rent rather ticket expand
keystore {
  publicKey: 'edpkuEFWHq3MWMjaZo9aEiYPno2feDb745aYepH7DWDbzBFqbxt4wF',
  privateKey: 'edskRkGz8EzThsHTrtwpU2vL6XYa4o5XBHwuWQ6P3Z8vL9uhi2YvRMfrJFZcVFLwjN753UrorY62XAgAdTFoV2vPzm4vqDSXQQ',
  publicKeyHash: 'tz1hY4nt3WABWmCXyK46hH4i9eWX4f15fv3A',
  seed: '',
  storeType: 0
}

Is there any sign method in conseiljs, which accepts the message as bytes and private key as string or bytes and return the signature?

And similarly for verify method, accepts a message, sign and public key and return boolean?

Please remember the key-gen is generating private key of length 98.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.