UNPKG

di-wings

Version:

Aviary Tech's common library for decentralized identity

35 lines 1.27 kB
import { Multikey } from './Multikey'; import type { JsonWebKey2020 } from './JsonWebKey2020'; export declare class Secp256k1KeyPair { multikey: Multikey; constructor(id: string, controller: string, publicKeyBase58: string, privateKeyBase58?: string); get id(): string; get type(): string; get controller(): string; get publicKey(): Uint8Array; get privateKey(): Uint8Array | undefined; get publicKeyBase58(): string; get privateKeyBase58(): string | undefined; static generate(): Promise<Secp256k1KeyPair>; static from(options: { id?: string; controller?: string; publicKeyBase58: string; privateKeyBase58?: string; }): Secp256k1KeyPair; static fromJWK(k: JsonWebKey2020): Promise<Secp256k1KeyPair>; static fromXpub(xpub: string): Promise<Secp256k1KeyPair | null>; sign(data: Uint8Array): Promise<Uint8Array>; verify(data: Uint8Array, signature: Uint8Array): Promise<boolean>; export(options?: { privateKey?: boolean; type: 'JsonWebKey2020'; }): Promise<JsonWebKey2020>; toJSON(): { id: string; type: string; controller: string; publicKeyBase58: string; }; } //# sourceMappingURL=Secp256k1KeyPair.d.ts.map