Namespace aes/shared. AesShared
source · [−]Functions
sourcedecrypt
decrypt
source<T>(algorithm: EnforcedAesGcmParams | EnforcedAesCtrParams | EnforcedAesCbcParams, key: T, data: BufferSource): Promise<ArrayBuffer>
<T>(algorithm: EnforcedAesGcmParams | EnforcedAesCtrParams | EnforcedAesCbcParams, key: T, data: BufferSource): Promise<ArrayBuffer>
Type Parameters
T extends CryptoKey
Parameters
algorithm: EnforcedAesGcmParams | EnforcedAesCtrParams | EnforcedAesCbcParams
key: T
data: BufferSource
Returns Promise<ArrayBuffer>
sourceencrypt
encrypt
source<T>(algorithm: EnforcedAesGcmParams | EnforcedAesCtrParams | EnforcedAesCbcParams, key: T, data: BufferSource): Promise<ArrayBuffer>
<T>(algorithm: EnforcedAesGcmParams | EnforcedAesCtrParams | EnforcedAesCbcParams, key: T, data: BufferSource): Promise<ArrayBuffer>
Type Parameters
T extends CryptoKey
Parameters
algorithm: EnforcedAesGcmParams | EnforcedAesCtrParams | EnforcedAesCbcParams
key: T
data: BufferSource
Returns Promise<ArrayBuffer>
sourcegenerateKey
generateKey
source<T>(algorithm: EnforcedAesKeyGenParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<T>
<T>(algorithm: EnforcedAesKeyGenParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<T>
Type Parameters
T extends CryptoKey
Parameters
algorithm: EnforcedAesKeyGenParams
extractable: boolean = true
Optional keyUsages: KeyUsage[]
Returns Promise<T>
sourceimportKey
importKey
source<T>(format: KeyFormat, key: BufferSource | JsonWebKey, algorithm: EnforcedAesKeyAlgorithms, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<T>
<T>(format: KeyFormat, key: BufferSource | JsonWebKey, algorithm: EnforcedAesKeyAlgorithms, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<T>
Type Parameters
T extends CryptoKey
Parameters
format: KeyFormat
key: BufferSource | JsonWebKey
algorithm: EnforcedAesKeyAlgorithms
extractable: boolean = true
Optional keyUsages: KeyUsage[]
Returns Promise<T>
sourceunwrapKey
unwrapKey
source<T>(format: KeyFormat, wrappedKey: BufferSource, wrappedKeyAlgorithm: EnforcedImportParams, unwrappingKey: T, unwrappingKeyAlgorithm: EnforcedAesParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<CryptoKey>
<T>(format: KeyFormat, wrappedKey: BufferSource, wrappedKeyAlgorithm: EnforcedImportParams, unwrappingKey: T, unwrappingKeyAlgorithm: EnforcedAesParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<CryptoKey>
Type Parameters
T extends CryptoKey
Parameters
format: KeyFormat
wrappedKey: BufferSource
wrappedKeyAlgorithm: EnforcedImportParams
unwrappingKey: T
unwrappingKeyAlgorithm: EnforcedAesParams
extractable: boolean = true
Optional keyUsages: KeyUsage[]
Returns Promise<CryptoKey>
sourcewrapKey
wrapKey
source<T>(format: KeyFormat, key: CryptoKey, wrappingkey: T, wrapAlgorithm: EnforcedAesParams): Promise<ArrayBuffer>
<T>(format: KeyFormat, key: CryptoKey, wrappingkey: T, wrapAlgorithm: EnforcedAesParams): Promise<ArrayBuffer>
Type Parameters
T extends CryptoKey
Parameters
format: KeyFormat
key: CryptoKey
wrappingkey: T
wrapAlgorithm: EnforcedAesParams