Import key material and bind it to algorithm. The returned
LacewingKey can only ever be used with that algorithm.
algorithm is a name from the default set ("EdDSA", "ES256",
"PS256", "HS256", ...) or a legacy descriptor from
lacewing/legacy/rsa: importKey(pem, LEGACY_RS256).
Throws KEY_TYPE_MISMATCH when material and algorithm disagree,
ENTROPY_CHECK_FAILED for weak HMAC secrets, and
KEY_IMPORT_FAILED for anything else that goes wrong.
Import key material and bind it to
algorithm. The returned LacewingKey can only ever be used with that algorithm.algorithmis a name from the default set ("EdDSA","ES256","PS256","HS256", ...) or a legacy descriptor fromlacewing/legacy/rsa:importKey(pem, LEGACY_RS256).Throws
KEY_TYPE_MISMATCHwhen material and algorithm disagree,ENTROPY_CHECK_FAILEDfor weak HMAC secrets, andKEY_IMPORT_FAILEDfor anything else that goes wrong.