function multikeyToJWK
multikeyToJWK(keys: Multikey): JWKKeyPair

Convert a multikey pair to JWK. This function decodes the multikey data into a binary buffer, checks the preambles and invokes the crypto specific converter functions (depending on the preamble values) that do the final conversion from the binary data to JWK.

Works for ecdsa (both P-384 and P-256), and eddsa.

Parameters

Return Type

Throws

  • exceptions if something is incorrect in the incoming data
multikeyToJWK(keys: Multibase): JsonWebKey

Parameters

Return Type

Usage

import { multikeyToJWK } from ".";