Left Curve Software Stack
    Preparing search index...

    Implements

    • KeyPair
    Index

    Constructors

    • Parameters

      • privateKey: Uint8Array

      Returns Secp256k1

    Accessors

    • get privateKey(): Uint8Array<ArrayBufferLike>

      Returns Uint8Array<ArrayBufferLike>

    Methods

    • Sign a message hash with the private key.

      Parameters

      • messageHash: Uint8Array

        The hash of the message to sign.

      • Optionalrecovery: boolean

      Returns Uint8Array

      The signature of the message hash.

    • Parameters

      • Optionalcompressed: boolean

      Returns Uint8Array

    • Verify a signature of a message hash.

      Parameters

      • messageHash: Uint8Array

        The hash of the message that was signed.

      • signature: Uint8Array

        The signature to verify.

      Returns boolean

      True if the signature is valid, false otherwise.

    • Derive a secp256k1 key pair from a mnemonic.

      Parameters

      • mnemonic: string

        The English mnemonic to derive the key pair from.

      • OptionalcoinType: number

        The BIP-44 coin type to derive the key pair for.

      Returns Secp256k1

      A new secp256k1 key pair.

    • Generate a new secp256k1 key pair.

      Returns Secp256k1

      A new secp256k1 key pair.