Namespace rsa/shared. RsaShared
source · [−]Functions
sourceexportKey
exportKey
source<T>(format: KeyFormat, key: T): Promise<JsonWebKey | ArrayBuffer>
<T>(format: KeyFormat, key: T): Promise<JsonWebKey | ArrayBuffer>
Type Parameters
T extends RsaCryptoKeys
Parameters
format: KeyFormat
key: T
Returns Promise<JsonWebKey | ArrayBuffer>
sourcegenerateKey
generateKey
source(algorithm: EnforcedRsaHashedKeyGenParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<RsaCryptoKeys | RsaCryptoKeyPairs>
(algorithm: EnforcedRsaHashedKeyGenParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<RsaCryptoKeys | RsaCryptoKeyPairs>
Parameters
algorithm: EnforcedRsaHashedKeyGenParams
extractable: boolean = true
Optional keyUsages: KeyUsage[]
Returns Promise<RsaCryptoKeys | RsaCryptoKeyPairs>
sourceimportKey
importKey
source<T>(format: KeyFormat, key: BufferSource | JsonWebKey, algorithm: EnforcedRsaHashedImportParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<T>
<T>(format: KeyFormat, key: BufferSource | JsonWebKey, algorithm: EnforcedRsaHashedImportParams, extractable?: boolean, keyUsages?: KeyUsage[]): Promise<T>
Type Parameters
T extends RsaCryptoKeys
Parameters
format: KeyFormat
key: BufferSource | JsonWebKey
algorithm: EnforcedRsaHashedImportParams
extractable: boolean = true
Optional keyUsages: KeyUsage[]
Returns Promise<T>
sourcesign
sign
source(algorithm: EnforcedRsaPssParams | EnforcedRsassaPkcs1v15Params, key: RsaPssPrivCryptoKey | RsassaPkcs1V15PrivCryptoKey, data: BufferSource): Promise<ArrayBuffer>
(algorithm: EnforcedRsaPssParams | EnforcedRsassaPkcs1v15Params, key: RsaPssPrivCryptoKey | RsassaPkcs1V15PrivCryptoKey, data: BufferSource): Promise<ArrayBuffer>
Parameters
algorithm: EnforcedRsaPssParams | EnforcedRsassaPkcs1v15Params
key: RsaPssPrivCryptoKey | RsassaPkcs1V15PrivCryptoKey
data: BufferSource
Returns Promise<ArrayBuffer>
sourceverify
verify
source(algorithm: EnforcedRsaPssParams | EnforcedRsassaPkcs1v15Params, key: RsaPssPubCryptoKey | RsassaPkcs1V15PubCryptoKey, signature: BufferSource, data: BufferSource): Promise<boolean>
(algorithm: EnforcedRsaPssParams | EnforcedRsassaPkcs1v15Params, key: RsaPssPubCryptoKey | RsassaPkcs1V15PubCryptoKey, signature: BufferSource, data: BufferSource): Promise<boolean>
Parameters
algorithm: EnforcedRsaPssParams | EnforcedRsassaPkcs1v15Params
key: RsaPssPubCryptoKey | RsassaPkcs1V15PubCryptoKey
signature: BufferSource
data: BufferSource