Getting error in identity-ledgerhq
alejo-acevedo-deel opened this issue · comments
Describe the bug
I am getting TypeError: secp256k1 public key must be 65 bytes long (is 23)
when try to use fromDer
method of Secp256k1PublicKey
from the @dfinity/identity-ledgerhq
package
To Reproduce
Steps to reproduce the behavior:
import { LedgerIdentity, Secp256k1PublicKey} from '@dfinity/identity-ledgerhq'
const ledgerIdentity = await LedgerIdentity.create(derivePath);
const public = ledgerIdentity.getPublicKey()
Secp256k1PublicKey.fromDer(public.toDer())
Expected behavior
Create a new Secp256k1PublicKey instance
Additional context
TypeError: secp256k1 public key must be 65 bytes long (is 23)
at Secp256k1PublicKey.derEncode (root.did.ts:51:11)
at Secp256k1PublicKey.derDecode (root.did.ts:1:8)
at Secp256k1PublicKey.fromDer (root.did.ts:44:54)
Identity-ledgerhq is deprecated. Please use @zondax/ledger-icp
, which is being actively maintained