SubtleCrypto
This Web Crypto API interface provides a number of low-level cryptographic functions. It is accessed via the Crypto.subtle properties available in a window context (via Window.crypto).
interface SubtleCrypto {
decrypt(
)
: Promise<ArrayBuffer>;
deriveBits(
length: number,
)
: Promise<ArrayBuffer>;
deriveKey(
extractable: boolean,
)
: Promise<CryptoKey>;
encrypt(
)
: Promise<ArrayBuffer>;
generateKey(
extractable: boolean,
)
: Promise<CryptoKey>;
importKey(
format: "jwk",
extractable: boolean,
)
: Promise<CryptoKey>;
importKey(
extractable: boolean,
)
: Promise<CryptoKey>;
sign(
)
: Promise<ArrayBuffer>;
unwrapKey(
extractable: boolean,
)
: Promise<CryptoKey>;
verify(
)
: Promise<boolean>;
wrapKey(
)
: Promise<ArrayBuffer>;
}
Methods
decrypt(
)
: Promise<ArrayBuffer>
deriveBits(
length: number,
)
: Promise<ArrayBuffer>
deriveKey(
extractable: boolean,
)
: Promise<CryptoKey>
encrypt(
)
: Promise<ArrayBuffer>
generateKey(
extractable: boolean,
)
: Promise<CryptoKey>
importKey(
format: "jwk",
extractable: boolean,
)
: Promise<CryptoKey>
importKey(
extractable: boolean,
)
: Promise<CryptoKey>
sign(
)
: Promise<ArrayBuffer>
unwrapKey(
extractable: boolean,
)
: Promise<CryptoKey>
verify(
)
: Promise<boolean>
wrapKey(
)
: Promise<ArrayBuffer>