decrypt

inline suspend fun SubtleCrypto.decrypt(algorithm: Algorithm, key: CryptoKey, data: BufferSource): ArrayBuffer(source)

The decrypt() method of the SubtleCrypto interface decrypts some encrypted data. It takes as arguments a key to decrypt with, some optional extra parameters, and the data to decrypt (also known as "ciphertext"). It returns a Promise which will be fulfilled with the decrypted data (also known as "plaintext").

MDN Reference


inline suspend fun SubtleCrypto.decrypt(algorithm: String, key: CryptoKey, data: BufferSource): ArrayBuffer(source)
inline suspend fun SubtleCrypto.decrypt(algorithm: RsaOaepParams, key: CryptoKey, data: BufferSource): ArrayBuffer(source)
inline suspend fun SubtleCrypto.decrypt(algorithm: AesCtrParams, key: CryptoKey, data: BufferSource): ArrayBuffer(source)
inline suspend fun SubtleCrypto.decrypt(algorithm: AesCbcParams, key: CryptoKey, data: BufferSource): ArrayBuffer(source)
inline suspend fun SubtleCrypto.decrypt(algorithm: AesGcmParams, key: CryptoKey, data: BufferSource): ArrayBuffer(source)