toSymmetricKey

open override fun toSymmetricKey(): KmmResult<SymmetricKey<*, *, *>>

Transforms this JsonWebKey into a SymmetricKey if an algorithm mapping exists. Note: for JweEncryption, see JweEncryption.symmetricKeyFromJsonWebKeyBytes. Supported algorithms are:

  • SymmetricEncryptionAlgorithm.AES.GCM

  • SymmetricEncryptionAlgorithm.AES.WRAP