mirror of
https://github.com/nodejs/node.git
synced 2026-10-14 10:26:26 -04:00
test: reduce length in crypto keygen tests
PR-URL: https://github.com/nodejs/node/pull/49221 Refs: https://github.com/nodejs/node/issues/49202 Refs: https://github.com/nodejs/node/issues/41206 Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
1 parent
b9a6ab5c48
commit
b781eaf430
4 files changed
+4
-4
No files matched your search
@@ -12,7 +12,7 @@ const {
|
||||
// Test async elliptic curve key generation with 'jwk' encoding and RSA.
|
||||
{
|
||||
generateKeyPair('rsa', {
|
||||
modulusLength: 4096,
|
||||
modulusLength: 1024,
|
||||
publicKeyEncoding: {
|
||||
format: 'jwk'
|
||||
},
|
||||
|
||||
@@ -12,7 +12,7 @@ const {
|
||||
// Test classic Diffie-Hellman key generation.
|
||||
{
|
||||
generateKeyPair('dh', {
|
||||
primeLength: 1024
|
||||
primeLength: 512
|
||||
}, common.mustSucceed((publicKey, privateKey) => {
|
||||
assert.strictEqual(publicKey.type, 'public');
|
||||
assert.strictEqual(publicKey.asymmetricKeyType, 'dh');
|
||||
|
||||
@@ -12,7 +12,7 @@ const {
|
||||
// Passing an empty passphrase string should not throw ERR_OSSL_CRYPTO_MALLOC_FAILURE even on OpenSSL 3.
|
||||
// Regression test for https://github.com/nodejs/node/issues/41428.
|
||||
generateKeyPair('rsa', {
|
||||
modulusLength: 4096,
|
||||
modulusLength: 1024,
|
||||
publicKeyEncoding: {
|
||||
type: 'spki',
|
||||
format: 'pem'
|
||||
|
||||
@@ -13,7 +13,7 @@ const {
|
||||
// Test invalid parameter encoding.
|
||||
{
|
||||
assert.throws(() => generateKeyPairSync('dsa', {
|
||||
modulusLength: 4096,
|
||||
modulusLength: 1024,
|
||||
publicKeyEncoding: {
|
||||
format: 'jwk'
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user