sui icon indicating copy to clipboard operation
sui copied to clipboard

Ed25519 Keypair generates wrong address.

Open rocalex opened this issue 2 years ago • 0 comments

I'm trying to get keypair using Ed25519Keypair.deriveKeypair of @mysten/sui.js experimental version.

const keypair = Ed25519Keypair.deriveKeypair(process.env.SIGNER_MNEMONIC!)
const signer = new RawSigner(keypair, provider)
console.log(await signer.getAddress())

The address I got is 008b7d6ac55835878535dc2c2e8e606f86be2fe0, but the address which is imported in Sui wallet is 0xe31b70fbb4ed9cd51aa2626f0d7fecafcfb4b065. Why are they different?

rocalex avatar Oct 06 '22 05:10 rocalex