-
-
Notifications
You must be signed in to change notification settings - Fork 35.3k
Expand file tree
/
Copy pathWebCryptoAPI.cjs
More file actions
73 lines (64 loc) · 2.4 KB
/
WebCryptoAPI.cjs
File metadata and controls
73 lines (64 loc) · 2.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
'use strict';
const os = require('node:os');
const { hasOpenSSL } = require('../../common/crypto.js');
const s390x = os.arch() === 's390x';
const conditionalSkips = {};
function skip(...files) {
for (const file of files) {
conditionalSkips[file] = {
'skip': `Unsupported in OpenSSL ${process.versions.openssl}`,
};
}
}
if (!hasOpenSSL(3, 0)) {
skip(
'encrypt_decrypt/aes_ocb.tentative.https.any.js',
'generateKey/failures_AES-OCB.tentative.https.any.js',
'generateKey/failures_kmac.tentative.https.any.js',
'generateKey/successes_AES-OCB.tentative.https.any.js',
'generateKey/successes_kmac.tentative.https.any.js',
'import_export/AES-OCB_importKey.tentative.https.any.js',
'import_export/KMAC_importKey.tentative.https.any.js',
'sign_verify/kmac.tentative.https.any.js');
}
if (!hasOpenSSL(3, 2)) {
skip(
'derive_bits_keys/argon2.tentative.https.any.js',
'import_export/Argon2_importKey.tentative.https.any.js');
}
if (!hasOpenSSL(3, 5)) {
skip(
'encap_decap/encap_decap_bits.tentative.https.any.js',
'encap_decap/encap_decap_keys.tentative.https.any.js',
'generateKey/failures_ML-DSA.tentative.https.any.js',
'generateKey/failures_ML-KEM.tentative.https.any.js',
'generateKey/successes_ML-DSA.tentative.https.any.js',
'generateKey/successes_ML-KEM.tentative.https.any.js',
'import_export/ML-DSA_importKey.tentative.https.any.js',
'import_export/ML-KEM_importKey.tentative.https.any.js',
'sign_verify/mldsa.tentative.https.any.js');
}
module.exports = {
...conditionalSkips,
'algorithm-discards-context.https.window.js': {
'skip': 'Not relevant in Node.js context',
},
'historical.any.js': {
'skip': 'Not relevant in Node.js context',
},
'sign_verify/eddsa_small_order_points.https.any.js': {
'fail': {
'note': 'see https://github.com/nodejs/node/issues/54572',
'expected': [
'Ed25519 Verification checks with small-order key of order - Test 1',
'Ed25519 Verification checks with small-order key of order - Test 2',
'Ed25519 Verification checks with small-order key of order - Test 12',
'Ed25519 Verification checks with small-order key of order - Test 13',
...(s390x ? [] : [
'Ed25519 Verification checks with small-order key of order - Test 0',
'Ed25519 Verification checks with small-order key of order - Test 11',
]),
],
},
},
};