summaryrefslogtreecommitdiff
path: root/ext/crypto/00_crypto.js
diff options
context:
space:
mode:
authorLuca Casonato <hello@lcas.dev>2021-12-13 18:45:08 +0100
committerGitHub <noreply@github.com>2021-12-13 18:45:08 +0100
commit8fdade79daffaa4b5b42c90b80df3b8604e97b32 (patch)
treeff0b38cbb922bdebebf1a58b9ef567dd38afba41 /ext/crypto/00_crypto.js
parent308813ae29763512a8be1044b31b8d5dad36c38c (diff)
refactor(ext/crypto): generateKey rust cleanup (#13069)
Diffstat (limited to 'ext/crypto/00_crypto.js')
-rw-r--r--ext/crypto/00_crypto.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/ext/crypto/00_crypto.js b/ext/crypto/00_crypto.js
index 818061387..258363586 100644
--- a/ext/crypto/00_crypto.js
+++ b/ext/crypto/00_crypto.js
@@ -1468,7 +1468,7 @@
const keyData = await core.opAsync(
"op_crypto_generate_key",
{
- name: algorithmName,
+ algorithm: "RSA",
modulusLength: normalizedAlgorithm.modulusLength,
publicExponent: normalizedAlgorithm.publicExponent,
},
@@ -1528,7 +1528,7 @@
const keyData = await core.opAsync(
"op_crypto_generate_key",
{
- name: algorithmName,
+ algorithm: "RSA",
modulusLength: normalizedAlgorithm.modulusLength,
publicExponent: normalizedAlgorithm.publicExponent,
},
@@ -1590,7 +1590,7 @@
)
) {
const keyData = await core.opAsync("op_crypto_generate_key", {
- name: algorithmName,
+ algorithm: "EC",
namedCurve,
});
WeakMapPrototypeSet(KEY_STORE, handle, {
@@ -1650,7 +1650,7 @@
)
) {
const keyData = await core.opAsync("op_crypto_generate_key", {
- name: algorithmName,
+ algorithm: "EC",
namedCurve,
});
WeakMapPrototypeSet(KEY_STORE, handle, {
@@ -1745,7 +1745,7 @@
// 3-4.
const keyData = await core.opAsync("op_crypto_generate_key", {
- name: algorithmName,
+ algorithm: "HMAC",
hash: normalizedAlgorithm.hash.name,
length,
});
@@ -2586,7 +2586,7 @@
// 3.
const keyData = await core.opAsync("op_crypto_generate_key", {
- name: algorithmName,
+ algorithm: "AES",
length: normalizedAlgorithm.length,
});
const handle = {};