summaryrefslogtreecommitdiff
path: root/ext/crypto/lib.deno_crypto.d.ts
diff options
context:
space:
mode:
Diffstat (limited to 'ext/crypto/lib.deno_crypto.d.ts')
-rw-r--r--ext/crypto/lib.deno_crypto.d.ts8
1 files changed, 6 insertions, 2 deletions
diff --git a/ext/crypto/lib.deno_crypto.d.ts b/ext/crypto/lib.deno_crypto.d.ts
index 5a554015a..55b94c24d 100644
--- a/ext/crypto/lib.deno_crypto.d.ts
+++ b/ext/crypto/lib.deno_crypto.d.ts
@@ -69,6 +69,10 @@ interface EcdsaParams extends Algorithm {
hash: HashAlgorithmIdentifier;
}
+interface RsaHashedImportParams extends Algorithm {
+ hash: HashAlgorithmIdentifier;
+}
+
interface RsaHashedKeyGenParams extends RsaKeyGenParams {
hash: HashAlgorithmIdentifier;
}
@@ -170,9 +174,9 @@ interface SubtleCrypto {
keyUsages: KeyUsage[],
): Promise<CryptoKey>;
importKey(
- format: "raw",
+ format: Exclude<KeyFormat, "jwk">,
keyData: BufferSource,
- algorithm: AlgorithmIdentifier | HmacImportParams,
+ algorithm: AlgorithmIdentifier | HmacImportParams | RsaHashedImportParams,
extractable: boolean,
keyUsages: KeyUsage[],
): Promise<CryptoKey>;