Function: generateKeyPair()

August 29, 2025 ยท View on GitHub

๐Ÿ’— Help the project

Support from the community to continue maintaining and improving this module is welcome. If you find the module useful, please consider supporting the project by becoming a sponsor.


โ–ธ generateKeyPair(alg, options?): Promise<CryptoKeyPair>

Generates a CryptoKeyPair for a given JWS alg Algorithm identifier.

Parameters

ParameterTypeDescription
algstringSupported JWS alg Algorithm identifier. Must be a supported JWS Algorithm.
options?GenerateKeyPairOptions-

Returns

Promise<CryptoKeyPair>