jose/src/runtime/generate.d.ts
2020-11-15 12:40:47 +01:00

14 lines
363 B
TypeScript

import type { KeyObject } from 'crypto'
import type { KeyLike } from '../types.d'
export declare function generateSecret(alg: string): Promise<KeyLike>
interface Options {
crv?: string
}
export declare function generateKeyPair(
alg: string,
options?: Options,
): Promise<{
privateKey: CryptoKey | KeyObject
publicKey: CryptoKey | KeyObject
}>
export {}