Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Keypair

Index

Constructors

  • new Keypair(privkey?: string): Keypair

Properties

encryptionKey: string
privkey: string
pubkey: BigNumber

Methods

  • address(): string
  • decrypt(data: string): Buffer
  • encrypt(bytes: Buffer): string
  • sign(commitment: string | number | BigNumber, merklePath: string | number | BigNumber): BigNumber
  • Sign a message using keypair private key

    Parameters

    • commitment: string | number | BigNumber

      a hex string with commitment

    • merklePath: string | number | BigNumber

      a hex string with merkle path

    Returns BigNumber

    a hex string with signature

  • toString(): string
  • fromString(str: string): Keypair & { encryptionKey: string; privkey: any; pubkey: BigNumber }

Generated using TypeDoc