summaryrefslogtreecommitdiff
path: root/ext/crypto/00_crypto.js
diff options
context:
space:
mode:
authorDivy Srivastava <dj.srivastava23@gmail.com>2024-01-06 16:48:31 +0530
committerGitHub <noreply@github.com>2024-01-06 16:48:31 +0530
commitbfd5f1598cc462b460791fdfca9bb6c2c69fec9b (patch)
tree93dfa9f650d07351d76e2202b7a4f7930727271b /ext/crypto/00_crypto.js
parent1d46ee5129dc5c674a7a4b6ad3a40243de4de2a0 (diff)
feat(ext/crypto): initial support for p521 in `generateKey` and `importKey` (#21815)
Part 1 of a potential 3 part series. Ref #13449 The current implementation passes key material back and forth RustCrypto group of crates and ring. ring does not implement p521 yet. This PR adds support for P521 named curve in `generateKey` and `importKey` where we use RustCrypto. Other parts should be moved over to the RustGroup group of crates for consistency.
Diffstat (limited to 'ext/crypto/00_crypto.js')
-rw-r--r--ext/crypto/00_crypto.js3
1 files changed, 1 insertions, 2 deletions
diff --git a/ext/crypto/00_crypto.js b/ext/crypto/00_crypto.js
index 06dd0f41a..d2949eb62 100644
--- a/ext/crypto/00_crypto.js
+++ b/ext/crypto/00_crypto.js
@@ -63,8 +63,7 @@ const {
isDataView,
} = core;
-// P-521 is not yet supported.
-const supportedNamedCurves = ["P-256", "P-384"];
+const supportedNamedCurves = ["P-256", "P-384", "P-521"];
const recognisedUsages = [
"encrypt",
"decrypt",