summaryrefslogtreecommitdiff
path: root/ext/node
diff options
context:
space:
mode:
Diffstat (limited to 'ext/node')
-rw-r--r--ext/node/ops/crypto/mod.rs8
1 files changed, 6 insertions, 2 deletions
diff --git a/ext/node/ops/crypto/mod.rs b/ext/node/ops/crypto/mod.rs
index 39d6b8bd5..8db562eef 100644
--- a/ext/node/ops/crypto/mod.rs
+++ b/ext/node/ops/crypto/mod.rs
@@ -707,8 +707,12 @@ fn ec_generate(
use ring::signature::KeyPair;
let curve = match named_curve {
- "P-256" => &ring::signature::ECDSA_P256_SHA256_FIXED_SIGNING,
- "P-384" => &ring::signature::ECDSA_P384_SHA384_FIXED_SIGNING,
+ "P-256" | "prime256v1" | "secp256r1" => {
+ &ring::signature::ECDSA_P256_SHA256_FIXED_SIGNING
+ }
+ "P-384" | "prime384v1" | "secp384r1" => {
+ &ring::signature::ECDSA_P384_SHA384_FIXED_SIGNING
+ }
_ => return Err(type_error("Unsupported named curve")),
};