Crypto-View

panva/node-oidc-provider

Cryptographic posture

1053 cryptographic locations: 543 quantum-vulnerable, 134 reduced-margin, 70 undetermined, 306 quantum-safe

145 establish keys, so traffic protected by them and recorded today becomes readable once the algorithm falls. 1 imported cryptographic library is listed separately. 447 files analysed.

Quantum-vulnerable 543 Reduced margin 134 Could not be determined 70 Quantum-safe 306
To address546
Key establishment145
Inventory only1
Total findings1054
What was analysed
Branch Not at a branch head The commit was given directly and is not the tip of any branch in the repository.
Commit 78474ace5fb25b691433451d33cd088efa4e2f54 test: add coverage for async keyObject ExternalSigningKey
Committed 2026-08-06 17:30 UTC
Scanned 2026-10-21 15:55 UTC 29 days ago
Coverage 447 files, 416 javascript

Earlier scans of this repository

4 scans · compare any two
0 to 1000 locations Quantum-vulnerable 543 → 146 (down 397) Reduced margin 134 → 62 (down 72) Could not be determined 70 → 42 (down 28) Quantum-safe 306 → 75 (down 231) The filled point is the scan you are reading.
Scanned Commit To address Key establishment
27 days ago 14e76834f1a0 main 163 47 Compare
28 days ago 8e13e7d05b59 main 156 47 Compare
28 days ago 8e13e7d05b59 main 123 30 Compare
29 days ago this scan 78474ace5fb2 546 145

A repository is scanned again when someone asks: Run a fresh scan.

List of cryptographic assets

ECDSA Quantum-vulnerable Renamed import 114 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/jwa.js:5 'ES256', 'ES384', 'ES512',
  2. lib/helpers/defaults.js:3430 'ES256',
  3. lib/helpers/defaults.js:3453 idTokenSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  4. lib/helpers/defaults.js:3477 'ES256',
  5. lib/helpers/defaults.js:3500 userinfoSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  6. lib/helpers/defaults.js:3523 'ES256',
  7. lib/helpers/defaults.js:3549 'ES256',
  8. lib/helpers/defaults.js:3818 dPoPSigningAlgValues: ['ES256', 'Ed25519', 'EdDSA'],
  9. lib/helpers/defaults.js:3837 attestSigningAlgValues: ['ES256', 'Ed25519', 'EdDSA'],
  10. lib/helpers/initialize_keystore.js:61 available = ['ES256'];
  11. lib/helpers/initialize_keystore.js:64 available = ['ES384'];
  12. lib/helpers/initialize_keystore.js:67 available = ['ES512'];
  13. lib/helpers/keystore.js:113 case 'ES256': return 'P-256';
  14. lib/helpers/keystore.js:114 case 'ES384': return 'P-384';
  15. lib/helpers/keystore.js:115 case 'ES512': return 'P-521';
  16. lib/models/id_token.js:17 case 'ES256':
  17. lib/models/id_token.js:22 case 'ES384':
  18. lib/models/id_token.js:27 case 'ES512':
  19. test/ciba/ciba.config.js:105 test path backchannel_authentication_request_signing_alg: 'ES256',
  20. test/ciba/ciba.test.js:906 test path const { privateKey, publicKey } = await generateKeyPair('ES256');
  21. test/ciba/ciba.test.js:921 test path }).setProtectedHeader({ alg: 'ES256' })
  22. test/ciba/ciba.test.js:938 test path const { privateKey } = await generateKeyPair('ES256');
  23. test/ciba/ciba.test.js:947 test path }).setProtectedHeader({ alg: 'ES256' })
  24. test/ciba/ciba.test.js:972 test path const { privateKey } = await generateKeyPair('ES256');
  25. test/ciba/ciba.test.js:981 test path }).setProtectedHeader({ alg: 'ES256' })
  26. test/ciba/ciba.test.js:1006 test path const { privateKey } = await generateKeyPair('ES256');
  27. test/ciba/ciba.test.js:1015 test path }).setProtectedHeader({ alg: 'ES256' })
  28. test/ciba/ciba.test.js:1040 test path const { privateKey } = await generateKeyPair('ES256');
  29. test/ciba/ciba.test.js:1049 test path }).setProtectedHeader({ alg: 'ES256' })
  30. test/client_auth/client_auth.test.js:190 test path 'ES256',
  31. test/client_auth/client_auth.test.js:191 test path 'ES384',
  32. test/client_auth/client_auth.test.js:192 test path 'ES512',
  33. test/client_auth/client_auth.test.js:223 test path 'ES256',
  34. test/client_auth/client_auth.test.js:224 test path 'ES384',
  35. test/client_auth/client_auth.test.js:225 test path 'ES512',
  36. test/configuration/client_metadata.test.js:642 test path 'ES256',
  37. test/configuration/client_metadata.test.js:643 test path 'ES384',
  38. test/configuration/client_metadata.test.js:644 test path 'ES512',
  39. test/configuration/client_metadata.test.js:1605 test path 'ES256',
  40. test/configuration/client_metadata.test.js:1606 test path 'ES384',
  41. test/configuration/client_metadata.test.js:1607 test path 'ES512',
  42. test/configuration/client_metadata.test.js:1828 test path for (const alg of ['RS256', 'PS384', 'ES512', 'Ed25519', 'EdDSA', ...pqc]) {
  43. test/configuration/client_metadata.test.js:2107 test path const supported = ['PS256', 'ES256', 'RS256'];
  44. test/configuration/client_metadata.test.js:2111 test path id_token_signing_alg_values_supported: ['PS256', 'RS256', 'ES256'],
  45. test/configuration/client_metadata.test.js:2117 test path rejects(this.title, ['ES256'], `${this.title} must include the value of provided id_token_signed_response_alg`, {
  46. test/configuration/client_metadata.test.js:2121 test path rejects(this.title, ['ES256'], `${this.title} includes no supported values`, undefined, {
  47. test/configuration/keystore_configuration.test.js:66 test path generateKeyPair('ES256', { extractable: true }),
  48. test/dpop/dpop.config.js:7 test path config.enabledJWA.dPoPSigningAlgValues = ['ES256', 'PS256'];
  49. test/dpop/dpop.test.js:27 test path }).setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: await exportJWK(keypair.publicKey) })
  50. test/dpop/dpop.test.js:38 test path this.keypair = await generateKeyPair('ES256', { extractable: true });
  51. test/dpop/dpop.test.js:47 test path expect(response.body).to.have.deep.property('dpop_signing_alg_values_supported', ['ES256', 'PS256']);
  52. test/dpop/dpop.test.js:123 test path alg: 'ES256',
  53. test/dpop/dpop.test.js:173 test path alg: 'ES256',
  54. test/dpop/dpop.test.js:197 test path alg: 'ES256',
  55. test/dpop/dpop.test.js:216 test path alg: 'ES256',
  56. test/dpop/dpop.test.js:232 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  57. test/dpop/dpop.test.js:246 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  58. test/dpop/dpop.test.js:261 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  59. test/dpop/dpop.test.js:292 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  60. test/dpop/dpop.test.js:377 test path .set('DPoP', await DPoP(await generateKeyPair('ES256', { extractable: true }), `${this.provider.issuer}${this.suitePath('/me')}`, 'GET', undefined, token))
  61. test/dpop/dpop.test.js:386 test path .set('DPoP', await DPoP(await generateKeyPair('ES256', { extractable: true }), `${this.provider.issuer}${this.suitePath('/me')}`, 'GET', undefined, dpop))
  62. test/dpop/dpop.test.js:797 test path .set('DPoP', await DPoP(await generateKeyPair('ES256', { extractable: true }), `${this.provider.issuer}${this.suitePath('/token')}`, 'POST'))
  63. test/dpop/dpop.test.js:971 test path .set('DPoP', await DPoP(await generateKeyPair('ES256', { extractable: true }), `${this.provider.issuer}${this.suitePath('/token')}`, 'POST'))
  64. test/dpop/dpop.test.js:982 test path await generateKeyPair('ES256', { extractable: true }),
  65. test/external_signing/external_signing.config.js:103 test path id_token_signed_response_alg: 'ES256',
  66. test/external_signing/external_signing.config.js:119 test path id_token_signed_response_alg: 'ES384',
  67. test/external_signing/external_signing.test.js:40 test path expect(body.id_token_signing_alg_values_supported).to.include('ES384');
  68. test/fapi/fapi2.config.js:10 test path export const keypair = await generateKeyPair('ES256');
  69. test/fapi/fapi2.config.js:26 test path requestObjectSigningAlgValues: ['ES256'],
  70. test/fapi/fapi2.test.js:88 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey),
  71. test/fapi/fapi2.test.js:164 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  72. test/fapi/fapi2.test.js:195 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  73. test/fapi/fapi2.test.js:228 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  74. test/fapi/fapi2.test.js:261 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  75. test/fapi/fapi-final.config.js:10 test path export const keypair = await generateKeyPair('ES256');
  76. test/fapi/fapi-final.config.js:27 test path requestObjectSigningAlgValues: ['ES256'],
  77. test/fapi/fapi-final.test.js:115 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  78. test/fapi/fapi-final.test.js:151 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  79. test/fapi/fapi-final.test.js:184 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  80. test/fapi/fapi-final.test.js:218 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  81. test/fapi/fapi-final.test.js:252 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  82. test/formats/jwt.test.js:535 test path alg: 'ES512',
  83. test/jwks/jwks_uri.test.js:105 test path alg: 'ES256',
  84. test/jwt/jsonwebtoken.test.js:94 test path const { privateKey, publicKey } = await generateKeyPair('ES256');
  85. test/jwt/jsonwebtoken.test.js:96 test path return JWT.sign({ data: true }, privateKey, 'ES256')
  86. test/jwt/jsonwebtoken.test.js:99 test path expect(decoded.header).to.have.property('alg', 'ES256');
  87. test/keys.js:14 test path generate('ES256'),
  88. test/openid4vci/openid4vci.config.js:6 test path export const attesterKeypair = await generateKeyPair('ES256', { extractable: true });
  89. test/openid4vci/openid4vci.config.js:11 test path config.enabledJWA.dPoPSigningAlgValues = ['ES256'];
  90. test/openid4vci/openid4vci.config.js:78 test path proof_signing_alg_values_supported: ['ES256'],
  91. test/openid4vci/openid4vci.config.js:89 test path proof_signing_alg_values_supported: ['ES256'],
  92. test/openid4vci/openid4vci.config.js:113 test path proof_signing_alg_values_supported: ['ES256'],
  93. test/openid4vci/openid4vci.config.js:124 test path proof_signing_alg_values_supported: ['ES256'],
  94. test/openid4vci/openid4vci.test.js:25 test path alg = 'ES256',
  95. test/openid4vci/openid4vci.test.js:56 test path alg = 'ES256',
  96. test/openid4vci/openid4vci.test.js:93 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: await exportJWK(keypair.publicKey) })
  97. test/openid4vci/openid4vci.test.js:112 test path proof_signing_alg_values_supported: ['ES256'],
  98. test/openid4vci/openid4vci.test.js:160 test path proof_signing_alg_values_supported: ['ES256'],
  99. test/openid4vci/openid4vci.test.js:255 test path proof_signing_alg_values_supported: ['ES256'],
  100. test/openid4vci/openid4vci.test.js:281 test path proof_signing_alg_values_supported: ['ES256'],
  101. test/openid4vci/openid4vci.test.js:309 test path proof_signing_alg_values_supported: ['ES256'],
  102. test/openid4vci/openid4vci.test.js:337 test path proof_signing_alg_values_supported: ['ES256'],
  103. test/openid4vci/openid4vci.test.js:432 test path this.keypair = await generateKeyPair('ES256', { extractable: true });
  104. test/openid4vci/openid4vci.test.js:434 test path this.otherKeypair = await generateKeyPair('ES256', { extractable: true });
  105. test/openid4vci/openid4vci.test.js:666 test path .expect('WWW-Authenticate', /algs="ES256"/);
  106. test/openid4vci/openid4vci.test.js:1349 test path const thirdKeypair = await generateKeyPair('ES256', { extractable: true });
  107. test/openid4vci/openid4vci.test.js:1460 test path const p384 = await generateKeyPair('ES384', { extractable: true });
  108. test/openid4vci/openid4vci.test.js:1462 test path alg: 'ES384',
  109. test/openid4vci/openid4vci.test.js:1563 test path const wrongKey = await generateKeyPair('ES256', { extractable: true });
  110. test/openid4vci/openid4vci.test.js:2002 test path const wrongKey = await generateKeyPair('ES256', { extractable: true });
  111. test/openid4vci/openid4vci.test.js:2026 test path const p384 = await generateKeyPair('ES384', { extractable: true });
  112. test/openid4vci/openid4vci.test.js:2030 test path alg: 'ES384',
  113. test/openid4vci/pre_authorized_code.test.js:164 test path const keypair = await generateKeyPair('ES256', { extractable: true });
  114. test/openid4vci/pre_authorized_code.test.js:167 test path alg: 'ES256',
jose.algorithm · CWE-327
RSASSA-PKCS1v15 Quantum-vulnerable Renamed import 95 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer. The v1.5 signature scheme of RFC 8017 section 8.2 has no classical break of its own; RSA-PSS is preferred for new work, but the quantum exposure is the same for both.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/client_attributes.js:32 authorization_signed_response_alg: 'RS256',
  2. lib/consts/client_attributes.js:36 id_token_signed_response_alg: 'RS256',
  3. lib/consts/client_attributes.js:37 introspection_signed_response_alg: 'RS256',
  4. lib/consts/dev_keystore.js:4 alg: 'RS256',
  5. lib/consts/jwa.js:3 'RS256', 'RS384', 'RS512',
  6. lib/helpers/defaults.js:841 id_token_signed_response_alg: 'RS256',
  7. lib/helpers/defaults.js:3428 'RS256',
  8. lib/helpers/defaults.js:3453 idTokenSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  9. lib/helpers/defaults.js:3475 'RS256',
  10. lib/helpers/defaults.js:3500 userinfoSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  11. lib/helpers/defaults.js:3521 'RS256',
  12. lib/helpers/defaults.js:3547 'RS256',
  13. lib/helpers/initialize_keystore.js:56 available = ['PS256', 'PS384', 'PS512', 'RS256', 'RS384', 'RS512'];
  14. lib/models/id_token.js:15 case 'RS256':
  15. lib/models/id_token.js:20 case 'RS384':
  16. lib/models/id_token.js:25 case 'RS512':
  17. test/client_auth/client_auth.config.js:55 test path if (header.alg === 'RS256') {
  18. test/client_auth/client_auth.test.js:64 test path alg: 'RS256',
  19. test/client_auth/client_auth.test.js:184 test path 'RS256',
  20. test/client_auth/client_auth.test.js:185 test path 'RS384',
  21. test/client_auth/client_auth.test.js:186 test path 'RS512',
  22. test/client_auth/client_auth.test.js:217 test path 'RS256',
  23. test/client_auth/client_auth.test.js:218 test path 'RS384',
  24. test/client_auth/client_auth.test.js:219 test path 'RS512',
  25. test/client_auth/client_auth.test.js:1205 test path }, privateKey, 'RS256', {
  26. test/client_auth/client_auth.test.js:1225 test path }, privateKey, 'RS256', {
  27. test/client_auth/client_auth.test.js:1411 test path alg: 'RS256',
  28. test/client_auth/client_auth.test.js:1459 test path alg: 'RS256',
  29. test/client_auth/client_auth.test.js:1471 test path alg: 'RS256',
  30. test/client_auth/client_auth.test.js:1483 test path alg: 'RS256',
  31. test/client_auth/client_auth.test.js:1495 test path alg: 'RS256',
  32. test/client_auth/client_auth.test.js:1507 test path alg: 'RS256',
  33. test/client_auth/client_auth.test.js:1519 test path alg: 'RS256',
  34. test/client_auth/client_auth.test.js:1531 test path alg: 'RS256',
  35. test/client_auth/client_auth.test.js:1543 test path alg: 'RS256',
  36. test/client_auth/client_auth.test.js:1570 test path alg: 'RS256',
  37. test/configuration/client_metadata.test.js:401 test path defaultsTo(this.title, 'RS256');
  38. test/configuration/client_metadata.test.js:636 test path 'RS256',
  39. test/configuration/client_metadata.test.js:637 test path 'RS384',
  40. test/configuration/client_metadata.test.js:638 test path 'RS512',
  41. test/configuration/client_metadata.test.js:964 test path defaultsTo(this.title, 'RS256', undefined, configuration);
  42. test/configuration/client_metadata.test.js:973 test path defaultsTo(this.title, 'RS256', undefined, configuration);
  43. test/configuration/client_metadata.test.js:1103 test path userinfo_signed_response_alg: 'RS256',
  44. test/configuration/client_metadata.test.js:1154 test path [this.title.replace('encrypted', 'signed').replace('_enc', '_alg')]: 'RS256',
  45. test/configuration/client_metadata.test.js:1164 test path [this.title.replace('encrypted', 'signed').replace('_enc', '_alg')]: 'RS256',
  46. test/configuration/client_metadata.test.js:1176 test path [this.title.replace('encrypted', 'signed').replace('_enc', '_alg')]: 'RS256',
  47. test/configuration/client_metadata.test.js:1186 test path [this.title.replace('encrypted', 'signed').replace('_enc', '_alg')]: 'RS256',
  48. test/configuration/client_metadata.test.js:1198 test path [this.title.replace('encrypted', 'signed').replace('_enc', '_alg')]: 'RS256',
  49. test/configuration/client_metadata.test.js:1208 test path introspection_signed_response_alg: 'RS256',
  50. test/configuration/client_metadata.test.js:1308 test path authorization_signed_response_alg: 'RS256',
  51. test/configuration/client_metadata.test.js:1599 test path 'RS256',
  52. test/configuration/client_metadata.test.js:1600 test path 'RS384',
  53. test/configuration/client_metadata.test.js:1601 test path 'RS512',
  54. test/configuration/client_metadata.test.js:1828 test path for (const alg of ['RS256', 'PS384', 'ES512', 'Ed25519', 'EdDSA', ...pqc]) {
  55. test/configuration/client_metadata.test.js:1854 test path [prop.replace('encrypted', 'signed')]: 'RS256',
  56. test/configuration/client_metadata.test.js:2107 test path const supported = ['PS256', 'ES256', 'RS256'];
  57. test/configuration/client_metadata.test.js:2111 test path id_token_signing_alg_values_supported: ['PS256', 'RS256', 'ES256'],
  58. test/configuration/client_metadata.test.js:2118 test path id_token_signed_response_alg: 'RS256',
  59. test/configuration/client_metadata.test.js:2124 test path idTokenSigningAlgValues: ['RS256'],
  60. test/configuration/configuration.test.js:13 test path clientAuthSigningAlgValues: ['HS256', 'RS256'],
  61. test/configuration/configuration.test.js:41 test path expect(configuration.clientAuthSigningAlgValues).to.eql(['RS256']);
  62. test/configuration/configuration.test.js:44 test path expect(input.enabledJWA.clientAuthSigningAlgValues).to.eql(['HS256', 'RS256']);
  63. test/configuration/keystore_configuration.test.js:65 test path generateKeyPair('RS256', { extractable: true }),
  64. test/configuration/omit_algs.test.js:11 test path invalidProperty: ['HS256', 'RS256'],
  65. test/configuration/omit_algs.test.js:21 test path idTokenSigningAlgValues: new Set(['HS256', 'RS256']),
  66. test/configuration/omit_algs.test.js:38 test path const { privateKey } = await generateKeyPair('RS256', { extractable: true });
  67. test/configuration/omit_algs.test.js:41 test path idTokenSigningAlgValues: ['HS256', 'RS256'],
  68. test/configuration/omit_algs.test.js:48 test path expect(i(provider).configuration.idTokenSigningAlgValues).to.eql(['HS256', 'RS256']);
  69. test/core/implicit/implicit.config.js:24 test path id_token_signed_response_alg: 'RS256',
  70. test/dynamic_registration/dynamic_registration.test.js:24 test path expect(response.body).to.have.property('id_token_signed_response_alg', 'RS256');
  71. test/dynamic_registration/dynamic_registration.test.js:522 test path expect(response.body).to.have.property('id_token_signed_response_alg', 'RS256');
  72. test/encryption/encryption.config.js:37 test path userinfo_signed_response_alg: 'RS256',
  73. test/encryption/encryption.test.js:129 test path client.userinfoSignedResponseAlg = 'RS256';
  74. test/external_signing/external_signing.config.js:111 test path id_token_signed_response_alg: 'RS256',
  75. test/formats/jwt.test.js:99 test path expect(header).to.have.property('alg', 'RS256');
  76. test/formats/jwt.test.js:100 test path expect(header).to.have.property('kid', i(this.provider).keystore.selectForSign({ alg: 'RS256' })[0].kid);
  77. test/formats/jwt.test.js:115 test path expect(header).to.have.property('alg', 'RS256');
  78. test/formats/jwt.test.js:116 test path expect(header).to.have.property('kid', i(this.provider).keystore.selectForSign({ alg: 'RS256' })[0].kid);
  79. test/formats/jwt.test.js:122 test path const [source] = keystore.selectForSign({ alg: 'RS256' });
  80. test/formats/jwt.test.js:133 test path sign: { alg: 'RS256', kid: jwk.kid },
  81. test/jwks/jwks-enc.config.js:30 test path alg: 'RS256',
  82. test/jwks/jwks-noenc.config.js:30 test path alg: 'RS256',
  83. test/jwks/jwks_uri.test.js:30 test path alg: 'RS256',
  84. test/jwks/jwks_uri.test.js:95 test path alg: 'RS256',
  85. test/jwt_introspection/jwt_introspection.config.js:18 test path introspection_signed_response_alg: 'RS256',
  86. test/jwt/jsonwebtoken.test.js:83 test path const { privateKey, publicKey } = await generateKeyPair('RS256');
  87. test/jwt/jsonwebtoken.test.js:85 test path return JWT.sign({ data: true }, privateKey, 'RS256')
  88. test/jwt/jsonwebtoken.test.js:88 test path expect(decoded.header).to.have.property('alg', 'RS256');
  89. test/keys.js:13 test path generate('RS256'),
  90. test/registration_management/registration_management.test.js:87 test path const client = await setup.call(this, { userinfo_signed_response_alg: 'RS256' });
  91. test/registration_management/registration_management.test.js:115 test path const client = await setup.call(this, { userinfo_signed_response_alg: 'RS256' });
  92. test/signatures/signatures.test.js:73 test path this.client.idTokenSignedResponseAlg = 'RS256';
  93. test/signatures/signatures.test.js:122 test path this.client.idTokenSignedResponseAlg = 'RS512';
  94. test/signatures/signatures.test.js:141 test path this.client.idTokenSignedResponseAlg = 'RS384';
  95. test/signatures/signatures.test.js:160 test path this.client.idTokenSignedResponseAlg = 'RS256';
jose.algorithm · CWE-327
RSA-OAEP Quantum-vulnerable Recorded traffic 71 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/jwa.js:17 'RSA-OAEP',
  2. lib/consts/jwa.js:18 'RSA-OAEP-256', 'RSA-OAEP-384', 'RSA-OAEP-512',
  3. lib/helpers/defaults.js:3578 'RSA-OAEP',
  4. lib/helpers/defaults.js:3579 'RSA-OAEP-256',
  5. lib/helpers/defaults.js:3607 'RSA-OAEP',
  6. lib/helpers/defaults.js:3608 'RSA-OAEP-256',
  7. lib/helpers/defaults.js:3636 'RSA-OAEP',
  8. lib/helpers/defaults.js:3637 'RSA-OAEP-256',
  9. lib/helpers/defaults.js:3666 'RSA-OAEP',
  10. lib/helpers/defaults.js:3667 'RSA-OAEP-256',
  11. lib/helpers/defaults.js:3696 'RSA-OAEP',
  12. lib/helpers/defaults.js:3697 'RSA-OAEP-256',
  13. lib/helpers/initialize_keystore.js:112 available = ['RSA-OAEP', 'RSA-OAEP-256', 'RSA-OAEP-384', 'RSA-OAEP-512'];
  14. test/configuration/client_metadata.test.js:1019 test path 'RSA-OAEP',
  15. test/configuration/client_metadata.test.js:1020 test path 'RSA-OAEP-256',
  16. test/configuration/client_metadata.test.js:1021 test path 'RSA-OAEP-384',
  17. test/configuration/client_metadata.test.js:1022 test path 'RSA-OAEP-512',
  18. test/configuration/client_metadata.test.js:1053 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  19. test/configuration/client_metadata.test.js:1062 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  20. test/configuration/client_metadata.test.js:1073 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  21. test/configuration/client_metadata.test.js:1093 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  22. test/configuration/client_metadata.test.js:1125 test path 'RSA-OAEP',
  23. test/configuration/client_metadata.test.js:1126 test path 'RSA-OAEP-256',
  24. test/configuration/client_metadata.test.js:1127 test path 'RSA-OAEP-384',
  25. test/configuration/client_metadata.test.js:1128 test path 'RSA-OAEP-512',
  26. test/configuration/client_metadata.test.js:1153 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  27. test/configuration/client_metadata.test.js:1163 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  28. test/configuration/client_metadata.test.js:1175 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  29. test/configuration/client_metadata.test.js:1197 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  30. test/configuration/client_metadata.test.js:1230 test path 'RSA-OAEP',
  31. test/configuration/client_metadata.test.js:1231 test path 'RSA-OAEP-256',
  32. test/configuration/client_metadata.test.js:1232 test path 'RSA-OAEP-384',
  33. test/configuration/client_metadata.test.js:1233 test path 'RSA-OAEP-512',
  34. test/configuration/client_metadata.test.js:1258 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  35. test/configuration/client_metadata.test.js:1267 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  36. test/configuration/client_metadata.test.js:1278 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  37. test/configuration/client_metadata.test.js:1298 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  38. test/configuration/client_metadata.test.js:1330 test path 'RSA-OAEP',
  39. test/configuration/client_metadata.test.js:1331 test path 'RSA-OAEP-256',
  40. test/configuration/client_metadata.test.js:1332 test path 'RSA-OAEP-384',
  41. test/configuration/client_metadata.test.js:1333 test path 'RSA-OAEP-512',
  42. test/configuration/client_metadata.test.js:1358 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  43. test/configuration/client_metadata.test.js:1367 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  44. test/configuration/client_metadata.test.js:1378 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  45. test/configuration/client_metadata.test.js:1398 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  46. test/configuration/client_metadata.test.js:1434 test path 'RSA-OAEP',
  47. test/configuration/client_metadata.test.js:1435 test path 'RSA-OAEP-256',
  48. test/configuration/client_metadata.test.js:1436 test path 'RSA-OAEP-384',
  49. test/configuration/client_metadata.test.js:1437 test path 'RSA-OAEP-512',
  50. test/configuration/client_metadata.test.js:1462 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  51. test/configuration/client_metadata.test.js:1470 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  52. test/configuration/client_metadata.test.js:1480 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  53. test/configuration/client_metadata.test.js:1499 test path [this.title.replace(/(enc$)/, 'alg')]: 'RSA-OAEP',
  54. test/configuration/client_metadata.test.js:1846 test path ['RSA-OAEP', 'ECDH-ES', 'ECDH-ES+A128KW', 'ECDH-ES+A192KW', 'ECDH-ES+A256KW'].forEach(
  55. test/encryption/encryption.config.js:18 test path pull(config.enabledJWA.requestObjectEncryptionAlgValues, 'RSA-OAEP-512');
  56. test/encryption/encryption.config.js:21 test path export const keypair = await generateKeyPair('RSA-OAEP');
  57. test/encryption/encryption.config.js:33 test path id_token_encrypted_response_alg: 'RSA-OAEP',
  58. test/encryption/encryption.config.js:35 test path request_object_encryption_alg: 'RSA-OAEP',
  59. test/encryption/encryption.config.js:38 test path userinfo_encrypted_response_alg: 'RSA-OAEP',
  60. test/encryption/encryption.test.js:154 test path client.userinfoEncryptedResponseAlg = 'RSA-OAEP';
  61. test/encryption/encryption.test.js:177 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP-512' });
  62. test/encryption/encryption.test.js:181 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP-512' })
  63. test/encryption/encryption.test.js:208 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP-512' });
  64. test/encryption/encryption.test.js:212 test path .setProtectedHeader({ enc: 'A192CBC-HS384', alg: 'RSA-OAEP-512' })
  65. test/encryption/encryption.test.js:244 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP' });
  66. test/encryption/encryption.test.js:248 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  67. test/encryption/encryption.test.js:285 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP' });
  68. test/encryption/encryption.test.js:289 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  69. test/encryption/encryption.test.js:329 test path client.idTokenEncryptedResponseAlg = 'RSA-OAEP';
  70. test/jwks/jwks-enc.config.js:42 test path alg: 'RSA-OAEP',
  71. test/jwks/jwks_uri.test.js:38 test path alg: 'RSA-OAEP',
jose.algorithm · CWE-327
Ed25519255-bitother/Ed25519 Quantum-vulnerable Renamed import 57 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/oidc/configuration.js:90 crv: 'Ed25519',
  2. lib/consts/jwa.js:6 'Ed25519', 'EdDSA',
  3. lib/helpers/defaults.js:3431 'Ed25519',
  4. lib/helpers/defaults.js:3432 'EdDSA',
  5. lib/helpers/defaults.js:3453 idTokenSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  6. lib/helpers/defaults.js:3478 'Ed25519',
  7. lib/helpers/defaults.js:3479 'EdDSA',
  8. lib/helpers/defaults.js:3500 userinfoSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  9. lib/helpers/defaults.js:3524 'Ed25519',
  10. lib/helpers/defaults.js:3525 'EdDSA',
  11. lib/helpers/defaults.js:3550 'Ed25519',
  12. lib/helpers/defaults.js:3551 'EdDSA',
  13. lib/helpers/defaults.js:3818 dPoPSigningAlgValues: ['ES256', 'Ed25519', 'EdDSA'],
  14. lib/helpers/defaults.js:3837 attestSigningAlgValues: ['ES256', 'Ed25519', 'EdDSA'],
  15. lib/helpers/initialize_keystore.js:74 case 'Ed25519':
  16. lib/helpers/initialize_keystore.js:75 available = ['EdDSA', 'Ed25519'];
  17. lib/helpers/keystore.js:116 case 'EdDSA':
  18. lib/helpers/keystore.js:117 case 'Ed25519': return 'Ed25519';
  19. lib/models/client.js:28 const OKP_SUBTYPES = new Set(['Ed25519', 'X25519']);
  20. lib/models/id_token.js:29 case 'Ed25519':
  21. lib/models/id_token.js:30 case 'EdDSA': // alias for Ed25519, Ed448 is not supported
  22. test/attest_bindings/attest_bindings.test.js:24 test path alg: 'Ed25519',
  23. test/attest_bindings/attest_bindings.test.js:36 test path alg: 'Ed25519',
  24. test/client_auth/client_auth.test.js:75 test path alg: 'Ed25519',
  25. test/client_auth/client_auth.test.js:193 test path 'Ed25519',
  26. test/client_auth/client_auth.test.js:194 test path 'EdDSA',
  27. test/client_auth/client_auth.test.js:226 test path 'Ed25519',
  28. test/client_auth/client_auth.test.js:227 test path 'EdDSA',
  29. test/client_auth/client_auth.test.js:1419 test path alg: 'Ed25519',
  30. test/client_auth/client_auth.test.js:1442 test path alg: 'Ed25519',
  31. test/client_auth/client_auth.test.js:1581 test path alg: 'Ed25519',
  32. test/client_auth/client_auth.test.js:1612 test path alg: 'Ed25519',
  33. test/client_auth/client_auth.test.js:1635 test path alg: 'Ed25519',
  34. test/client_auth/client_auth.test.js:1660 test path alg: 'Ed25519',
  35. test/client_auth/client_auth.test.js:1669 test path alg: 'Ed25519',
  36. test/client_auth/client_auth.test.js:1678 test path alg: 'Ed25519',
  37. test/client_auth/client_auth.test.js:1687 test path alg: 'Ed25519',
  38. test/client_auth/client_auth.test.js:1696 test path alg: 'Ed25519',
  39. test/client_auth/client_auth.test.js:1705 test path alg: 'Ed25519',
  40. test/client_auth/client_auth.test.js:1714 test path alg: 'Ed25519',
  41. test/configuration/client_metadata.test.js:645 test path 'Ed25519',
  42. test/configuration/client_metadata.test.js:646 test path 'EdDSA',
  43. test/configuration/client_metadata.test.js:1608 test path 'Ed25519',
  44. test/configuration/client_metadata.test.js:1609 test path 'EdDSA',
  45. test/configuration/client_metadata.test.js:1781 test path [[{ kty: 'OKP', crv: 'Ed25519' }], 'jwks.keys[0].x must be a non-empty string for OKP keys'],
  46. test/configuration/client_metadata.test.js:1782 test path [[{ kty: 'OKP', crv: 'Ed25519', x: 'x', d: 'd' }], 'jwks.keys[0].d must not be provided for OKP keys'],
  47. test/configuration/client_metadata.test.js:1828 test path for (const alg of ['RS256', 'PS384', 'ES512', 'Ed25519', 'EdDSA', ...pqc]) {
  48. test/configuration/keystore_configuration.test.js:43 test path const { publicKey } = await generateKeyPair('EdDSA');
  49. test/jwt/jsonwebtoken.test.js:105 test path const { privateKey, publicKey } = await generateKeyPair('EdDSA');
  50. test/jwt/jsonwebtoken.test.js:107 test path return JWT.sign({ data: true }, privateKey, 'EdDSA')
  51. test/jwt/jsonwebtoken.test.js:110 test path expect(decoded.header).to.have.property('alg', 'EdDSA');
  52. test/jwt/jsonwebtoken.test.js:116 test path const { privateKey, publicKey } = await generateKeyPair('Ed25519');
  53. test/jwt/jsonwebtoken.test.js:118 test path return JWT.sign({ data: true }, privateKey, 'Ed25519')
  54. test/jwt/jsonwebtoken.test.js:121 test path expect(decoded.header).to.have.property('alg', 'Ed25519');
  55. test/keys.js:15 test path generate('EdDSA'),
  56. test/keys.js:16 test path generate('Ed25519'),
  57. test/signatures/signatures.test.js:77 test path for (const alg of ['Ed25519', 'EdDSA']) {
jose.algorithm · CWE-327
RSA-PSS Quantum-vulnerable 46 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/fapi/index.js:27 const ALGS = ['PS256'];
  2. certification/fapi/index.js:285 alg: 'PS256',
  3. certification/fapi/index.js:307 authorization_signed_response_alg: 'PS256',
  4. certification/fapi/index.js:308 id_token_signed_response_alg: 'PS256',
  5. certification/fapi/index.js:309 request_object_signing_alg: 'PS256',
  6. certification/fapi/plan.json:24 "alg": "PS256",
  7. certification/fapi/plan.json:55 "alg": "PS256",
  8. lib/consts/jwa.js:4 'PS256', 'PS384', 'PS512',
  9. lib/helpers/defaults.js:3429 'PS256',
  10. lib/helpers/defaults.js:3453 idTokenSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  11. lib/helpers/defaults.js:3476 'PS256',
  12. lib/helpers/defaults.js:3500 userinfoSigningAlgValues: ['RS256', 'PS256', 'ES256', 'Ed25519', 'EdDSA'],
  13. lib/helpers/defaults.js:3522 'PS256',
  14. lib/helpers/defaults.js:3548 'PS256',
  15. lib/helpers/initialize_keystore.js:56 available = ['PS256', 'PS384', 'PS512', 'RS256', 'RS384', 'RS512'];
  16. lib/models/id_token.js:16 case 'PS256':
  17. lib/models/id_token.js:21 case 'PS384':
  18. lib/models/id_token.js:26 case 'PS512':
  19. test/client_auth/client_auth.test.js:128 test path clientAuthSigningAlgValues: ['PS256'],
  20. test/client_auth/client_auth.test.js:187 test path 'PS256',
  21. test/client_auth/client_auth.test.js:188 test path 'PS384',
  22. test/client_auth/client_auth.test.js:189 test path 'PS512',
  23. test/client_auth/client_auth.test.js:220 test path 'PS256',
  24. test/client_auth/client_auth.test.js:221 test path 'PS384',
  25. test/client_auth/client_auth.test.js:222 test path 'PS512',
  26. test/configuration/client_metadata.test.js:639 test path 'PS256',
  27. test/configuration/client_metadata.test.js:640 test path 'PS384',
  28. test/configuration/client_metadata.test.js:641 test path 'PS512',
  29. test/configuration/client_metadata.test.js:1602 test path 'PS256',
  30. test/configuration/client_metadata.test.js:1603 test path 'PS384',
  31. test/configuration/client_metadata.test.js:1604 test path 'PS512',
  32. test/configuration/client_metadata.test.js:1828 test path for (const alg of ['RS256', 'PS384', 'ES512', 'Ed25519', 'EdDSA', ...pqc]) {
  33. test/configuration/client_metadata.test.js:2074 test path defaultsTo('id_token_signed_response_alg', 'PS256', undefined, {
  34. test/configuration/client_metadata.test.js:2076 test path id_token_signed_response_alg: 'PS256',
  35. test/configuration/client_metadata.test.js:2107 test path const supported = ['PS256', 'ES256', 'RS256'];
  36. test/configuration/client_metadata.test.js:2111 test path id_token_signing_alg_values_supported: ['PS256', 'RS256', 'ES256'],
  37. test/dpop/dpop.config.js:7 test path config.enabledJWA.dPoPSigningAlgValues = ['ES256', 'PS256'];
  38. test/dpop/dpop.test.js:47 test path expect(response.body).to.have.deep.property('dpop_signing_alg_values_supported', ['ES256', 'PS256']);
  39. test/formats/jwt.test.js:76 test path sign: { alg: 'PS256' },
  40. test/formats/jwt.test.js:85 test path expect(header).to.have.property('alg', 'PS256');
  41. test/formats/jwt.test.js:373 test path alg: 'PS256',
  42. test/formats/jwt.test.js:402 test path alg: 'PS256',
  43. test/registration_policies/registration_policies.test.js:95 test path id_token_signed_response_alg: 'PS256',
  44. test/registration_policies/registration_policies.test.js:99 test path expect(body).to.have.property('id_token_signed_response_alg', 'PS256');
  45. test/registration_policies/registration_policies.test.js:120 test path id_token_signed_response_alg: 'PS256',
  46. test/registration_policies/registration_policies.test.js:142 test path id_token_signed_response_alg: 'PS256',
jose.algorithm · CWE-327
ECDH Quantum-vulnerable Recorded traffic 41 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/jwa.js:19 'ECDH-ES', 'ECDH-ES+A128KW', 'ECDH-ES+A192KW', 'ECDH-ES+A256KW',
  2. lib/helpers/defaults.js:3577 'ECDH-ES',
  3. lib/helpers/defaults.js:3606 'ECDH-ES',
  4. lib/helpers/defaults.js:3635 'ECDH-ES',
  5. lib/helpers/defaults.js:3665 'ECDH-ES',
  6. lib/helpers/defaults.js:3695 'ECDH-ES',
  7. lib/helpers/initialize_keystore.js:119 available = ['ECDH-ES', 'ECDH-ES+A128KW', 'ECDH-ES+A192KW', 'ECDH-ES+A256KW'];
  8. lib/helpers/initialize_keystore.js:127 available = ['ECDH-ES', 'ECDH-ES+A128KW', 'ECDH-ES+A192KW', 'ECDH-ES+A256KW'];
  9. test/configuration/client_keystore.test.js:44 test path id_token_encrypted_response_alg: 'ECDH-ES+A128KW',
  10. test/configuration/client_metadata.test.js:1023 test path 'ECDH-ES',
  11. test/configuration/client_metadata.test.js:1024 test path 'ECDH-ES+A128KW',
  12. test/configuration/client_metadata.test.js:1025 test path 'ECDH-ES+A192KW',
  13. test/configuration/client_metadata.test.js:1026 test path 'ECDH-ES+A256KW',
  14. test/configuration/client_metadata.test.js:1129 test path 'ECDH-ES',
  15. test/configuration/client_metadata.test.js:1130 test path 'ECDH-ES+A128KW',
  16. test/configuration/client_metadata.test.js:1131 test path 'ECDH-ES+A192KW',
  17. test/configuration/client_metadata.test.js:1132 test path 'ECDH-ES+A256KW',
  18. test/configuration/client_metadata.test.js:1234 test path 'ECDH-ES',
  19. test/configuration/client_metadata.test.js:1235 test path 'ECDH-ES+A128KW',
  20. test/configuration/client_metadata.test.js:1236 test path 'ECDH-ES+A192KW',
  21. test/configuration/client_metadata.test.js:1237 test path 'ECDH-ES+A256KW',
  22. test/configuration/client_metadata.test.js:1334 test path 'ECDH-ES',
  23. test/configuration/client_metadata.test.js:1335 test path 'ECDH-ES+A128KW',
  24. test/configuration/client_metadata.test.js:1336 test path 'ECDH-ES+A192KW',
  25. test/configuration/client_metadata.test.js:1337 test path 'ECDH-ES+A256KW',
  26. test/configuration/client_metadata.test.js:1438 test path 'ECDH-ES',
  27. test/configuration/client_metadata.test.js:1439 test path 'ECDH-ES+A128KW',
  28. test/configuration/client_metadata.test.js:1440 test path 'ECDH-ES+A192KW',
  29. test/configuration/client_metadata.test.js:1441 test path 'ECDH-ES+A256KW',
  30. test/configuration/client_metadata.test.js:1846 test path ['RSA-OAEP', 'ECDH-ES', 'ECDH-ES+A128KW', 'ECDH-ES+A192KW', 'ECDH-ES+A256KW'].forEach(
  31. test/encryption/encryption.test.js:320 test path client.idTokenEncryptedResponseAlg = 'ECDH-ES';
  32. test/formats/jwt.test.js:376 test path alg: 'ECDH-ES',
  33. test/formats/jwt.test.js:388 test path expect(header).to.have.property('alg', 'ECDH-ES');
  34. test/formats/jwt.test.js:405 test path alg: 'ECDH-ES',
  35. test/formats/jwt.test.js:428 test path alg: 'ECDH-ES',
  36. test/formats/jwt.test.js:440 test path expect(header).to.have.property('alg', 'ECDH-ES');
  37. test/formats/jwt.test.js:577 test path alg: 'ECDH-ES',
  38. test/jwks/jwks-enc.config.js:57 test path alg: 'ECDH-ES',
  39. test/jwks/jwks_uri.test.js:54 test path alg: 'ECDH-ES',
  40. test/openid4vci/openid4vci.test.js:203 test path alg_values_supported: ['ECDH-ES'],
  41. test/openid4vci/openid4vci.test.js:225 test path alg_values_supported: ['ECDH-ES'],
jose.algorithm · CWE-327
ECDSA Quantum-vulnerable 30 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. test/ciba/ciba.test.js:921 test path }).setProtectedHeader({ alg: 'ES256' })
  2. test/ciba/ciba.test.js:947 test path }).setProtectedHeader({ alg: 'ES256' })
  3. test/ciba/ciba.test.js:981 test path }).setProtectedHeader({ alg: 'ES256' })
  4. test/ciba/ciba.test.js:1015 test path }).setProtectedHeader({ alg: 'ES256' })
  5. test/ciba/ciba.test.js:1049 test path }).setProtectedHeader({ alg: 'ES256' })
  6. test/dpop/dpop.test.js:27 test path }).setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: await exportJWK(keypair.publicKey) })
  7. test/dpop/dpop.test.js:123 test path alg: 'ES256',
  8. test/dpop/dpop.test.js:173 test path alg: 'ES256',
  9. test/dpop/dpop.test.js:197 test path alg: 'ES256',
  10. test/dpop/dpop.test.js:216 test path alg: 'ES256',
  11. test/dpop/dpop.test.js:232 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  12. test/dpop/dpop.test.js:246 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  13. test/dpop/dpop.test.js:261 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  14. test/dpop/dpop.test.js:292 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: this.jwk })
  15. test/fapi/fapi2.test.js:88 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey),
  16. test/fapi/fapi2.test.js:164 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  17. test/fapi/fapi2.test.js:195 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  18. test/fapi/fapi2.test.js:228 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  19. test/fapi/fapi2.test.js:261 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  20. test/fapi/fapi-final.test.js:115 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  21. test/fapi/fapi-final.test.js:151 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  22. test/fapi/fapi-final.test.js:184 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  23. test/fapi/fapi-final.test.js:218 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  24. test/fapi/fapi-final.test.js:252 test path }).setProtectedHeader({ alg: 'ES256' }).sign(keypair.privateKey);
  25. test/formats/jwt.test.js:535 test path alg: 'ES512',
  26. test/jwks/jwks_uri.test.js:105 test path alg: 'ES256',
  27. test/openid4vci/openid4vci.test.js:93 test path .setProtectedHeader({ alg: 'ES256', typ: 'dpop+jwt', jwk: await exportJWK(keypair.publicKey) })
  28. test/openid4vci/openid4vci.test.js:1462 test path alg: 'ES384',
  29. test/openid4vci/openid4vci.test.js:2030 test path alg: 'ES384',
  30. test/openid4vci/pre_authorized_code.test.js:167 test path alg: 'ES256',
js.jwt.algorithm · CWE-327
RSASSA-PKCS1v15 Quantum-vulnerable 20 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer. The v1.5 signature scheme of RFC 8017 section 8.2 has no classical break of its own; RSA-PSS is preferred for new work, but the quantum exposure is the same for both.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/dev_keystore.js:4 alg: 'RS256',
  2. test/client_auth/client_auth.test.js:64 test path alg: 'RS256',
  3. test/client_auth/client_auth.test.js:1411 test path alg: 'RS256',
  4. test/client_auth/client_auth.test.js:1459 test path alg: 'RS256',
  5. test/client_auth/client_auth.test.js:1471 test path alg: 'RS256',
  6. test/client_auth/client_auth.test.js:1483 test path alg: 'RS256',
  7. test/client_auth/client_auth.test.js:1495 test path alg: 'RS256',
  8. test/client_auth/client_auth.test.js:1507 test path alg: 'RS256',
  9. test/client_auth/client_auth.test.js:1519 test path alg: 'RS256',
  10. test/client_auth/client_auth.test.js:1531 test path alg: 'RS256',
  11. test/client_auth/client_auth.test.js:1543 test path alg: 'RS256',
  12. test/client_auth/client_auth.test.js:1570 test path alg: 'RS256',
  13. test/formats/jwt.test.js:100 test path expect(header).to.have.property('kid', i(this.provider).keystore.selectForSign({ alg: 'RS256' })[0].kid);
  14. test/formats/jwt.test.js:116 test path expect(header).to.have.property('kid', i(this.provider).keystore.selectForSign({ alg: 'RS256' })[0].kid);
  15. test/formats/jwt.test.js:122 test path const [source] = keystore.selectForSign({ alg: 'RS256' });
  16. test/formats/jwt.test.js:133 test path sign: { alg: 'RS256', kid: jwk.kid },
  17. test/jwks/jwks-enc.config.js:30 test path alg: 'RS256',
  18. test/jwks/jwks-noenc.config.js:30 test path alg: 'RS256',
  19. test/jwks/jwks_uri.test.js:30 test path alg: 'RS256',
  20. test/jwks/jwks_uri.test.js:95 test path alg: 'RS256',
js.jwt.algorithm · CWE-327
Ed25519255-bitother/Ed25519 Quantum-vulnerable 15 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

js.jwt.algorithm · CWE-327
Ed25519255-bitother/Ed25519 Quantum-vulnerable Renamed import 12 places See details

Classical key pair generated with Node crypto

`crypto.generateKeyPair()` or its synchronous form. The detector resolves the algorithm through a `promisify()` wrapper and through an import alias, both of which are common enough that missing them would leave real key generation unreported.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. ML-KEM-768 for encryption, ML-DSA-65 for signatures. Node exposes neither yet, so this usually means an addon or a service boundary.

  1. test/attest_bindings/attest_bindings.config.js:9 test path const attestationKeyPair = generateKeyPairSync('ed25519');
  2. test/attest_bindings/attest_bindings.test.js:62 test path const instanceKeyPair = generateKeyPairSync('ed25519');
  3. test/attest_bindings/attest_bindings.test.js:98 test path const instanceKeyPair2 = generateKeyPairSync('ed25519');
  4. test/attest_bindings/attest_bindings.test.js:172 test path const instanceKeyPair = generateKeyPairSync('ed25519');
  5. test/attest_bindings/attest_bindings.test.js:211 test path const instanceKeyPair = generateKeyPairSync('ed25519');
  6. test/attest_bindings/attest_bindings.test.js:238 test path const instanceKeyPair2 = generateKeyPairSync('ed25519');
  7. test/attest_bindings/attest_bindings.test.js:268 test path const instanceKeyPair = generateKeyPairSync('ed25519');
  8. test/attest_bindings/attest_bindings.test.js:290 test path const instanceKeyPair2 = generateKeyPairSync('ed25519');
  9. test/attest_bindings/attest_bindings.test.js:320 test path const instanceKeyPair = generateKeyPairSync('ed25519');
  10. test/attest_bindings/attest_bindings.test.js:343 test path const instanceKeyPair2 = generateKeyPairSync('ed25519');
  11. test/client_auth/client_auth.test.js:1241 test path const instanceKeyPair = generateKeyPairSync('ed25519');
  12. test/client_auth/client_auth.test.js:1400 test path const instanceKeyPair = generateKeyPairSync('ed25519');
js.generatekeypair · CWE-327
RSA-OAEP Quantum-vulnerable Recorded traffic 10 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. test/encryption/encryption.test.js:177 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP-512' });
  2. test/encryption/encryption.test.js:181 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP-512' })
  3. test/encryption/encryption.test.js:208 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP-512' });
  4. test/encryption/encryption.test.js:212 test path .setProtectedHeader({ enc: 'A192CBC-HS384', alg: 'RSA-OAEP-512' })
  5. test/encryption/encryption.test.js:244 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP' });
  6. test/encryption/encryption.test.js:248 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  7. test/encryption/encryption.test.js:285 test path let [key] = i(this.provider).keystore.selectForEncrypt({ kty: 'RSA', alg: 'RSA-OAEP' });
  8. test/encryption/encryption.test.js:289 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  9. test/jwks/jwks-enc.config.js:42 test path alg: 'RSA-OAEP',
  10. test/jwks/jwks_uri.test.js:38 test path alg: 'RSA-OAEP',
js.jwt.algorithm · CWE-327
ECDH256-bitsecg/secp256r1 Quantum-vulnerable Recorded traffic Renamed import 8 places See details

Classical key pair generated with Node crypto

`crypto.generateKeyPair()` or its synchronous form. The detector resolves the algorithm through a `promisify()` wrapper and through an import alias, both of which are common enough that missing them would leave real key generation unreported.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. ML-KEM-768 for encryption, ML-DSA-65 for signatures. Node exposes neither yet, so this usually means an addon or a service boundary.

  1. test/external_signing/external_signing.config.js:8 test path const es256 = crypto.generateKeyPairSync('ec', { namedCurve: 'P-256' });
  2. test/formats/jwt.test.js:378 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).publicKey,
  3. test/formats/jwt.test.js:407 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).publicKey,
  4. test/formats/jwt.test.js:430 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).publicKey,
  5. test/formats/jwt.test.js:494 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).publicKey,
  6. test/formats/jwt.test.js:515 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).privateKey,
  7. test/formats/jwt.test.js:557 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).privateKey,
  8. test/formats/jwt.test.js:579 test path key: (await generateKeyPair('ec', { namedCurve: 'P-256' })).publicKey,
js.generatekeypair · CWE-327
ECDH Quantum-vulnerable Recorded traffic 6 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. test/formats/jwt.test.js:376 test path alg: 'ECDH-ES',
  2. test/formats/jwt.test.js:405 test path alg: 'ECDH-ES',
  3. test/formats/jwt.test.js:428 test path alg: 'ECDH-ES',
  4. test/formats/jwt.test.js:577 test path alg: 'ECDH-ES',
  5. test/jwks/jwks-enc.config.js:57 test path alg: 'ECDH-ES',
  6. test/jwks/jwks_uri.test.js:54 test path alg: 'ECDH-ES',
js.jwt.algorithm · CWE-327
RSA-PSS Quantum-vulnerable 4 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/fapi/index.js:285 alg: 'PS256',
  2. test/formats/jwt.test.js:76 test path sign: { alg: 'PS256' },
  3. test/formats/jwt.test.js:373 test path alg: 'PS256',
  4. test/formats/jwt.test.js:402 test path alg: 'PS256',
js.jwt.algorithm · CWE-327
RSA Quantum-vulnerable Recorded traffic 3 places See details

Public key declared as a JSON Web Key

A `kty` field, with the curve read from the sibling `crv` where the family needs one. A JWKS document declares a key without naming an algorithm anywhere, so it is invisible to a scan that only looks for `alg`.

This file publishes the public keys other systems use to check this system's signatures. Everyone who trusts these keys has to accept the new kind of key before the old ones can be retired.

What to do. A published JWKS is what relying parties trust. It has to accept a post-quantum key type before the keys behind it can change, so put it early in the migration order.

  1. certification/fapi/plan.json:22 "kty": "RSA",
  2. certification/fapi/plan.json:53 "kty": "RSA",
  3. test/jwks/jwks.json:14 test path "kty": "RSA",
jose.jwk · CWE-327
ECDSA256-bitsecg/secp256r1 Quantum-vulnerable 2 places See details

X.509 certificate

A PEM certificate. The subject public-key algorithm and key size are read from the SubjectPublicKeyInfo structure, and the not-after date is reported so certificates that outlive the migration window are visible.

This is a digital identity document. Its expiry date matters: one valid for many years locks in today's algorithms for that long.

What to do. Shorten certificate lifetimes so re-issuing with a post-quantum key is routine.

  1. test/jwks/client.crt:1 test path -----BEGIN CERTIFICATE-----
  2. test/jwks/ec.crt:1 test path -----BEGIN CERTIFICATE-----
pem.certificate
RSA Quantum-vulnerable Recorded traffic Renamed import 2 places See details

One-shot signing or public-key encryption

`crypto.sign()`, `crypto.verify()`, `privateEncrypt()`, `publicDecrypt()`, `privateDecrypt()` or `publicEncrypt()`. These take the key at runtime, so the algorithm follows the key; every key type Node accepts here is classical.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. ML-KEM-768 for encryption, ML-DSA-65 for signatures.

  1. test/external_signing/external_signing.config.js:25 test path return crypto.sign('sha256', data, {
  2. test/external_signing/external_signing.config.js:74 test path return crypto.sign('sha384', data, {
js.node.oneshot · CWE-327
ECDH Quantum-vulnerable Recorded traffic 1 place See details

TLS cipher suite named in source

A cipher suite written into the code rather than into a configuration file - `TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256`, the OpenSSL spelling `ECDHE-RSA-AES128-GCM-SHA256`, or a TLS 1.3 suite. Each is reported as a setting of the TLS protocol and listed in its `cipherSuites`; RSA key transport and broken bulk ciphers are reported again, as `config.cipher-suite.weak`.

This code names the exact cryptography its TLS connections may use. Because the list is in the program rather than in a settings file, changing it needs a new release - which is the thing that makes a migration slow.

What to do. A hardcoded suite list ships with the binary and cannot be changed without a release, so move it to configuration first. The key exchange changes when the TLS library offers a hybrid group, not before.

  1. .github/workflows/conformance.yml:210 NODE_OPTIONS: --tls-cipher-list="ECDHE-RSA-AES128-GCM-SHA256 ECDHE-RSA-AES256-GCM-SHA384 ECDHE-ECDSA-AES128-GCM-SHA256 ECDHE-ECDSA-AES256-GCM-SHA384"
config.cipher-suite · CWE-757
ECDH384-bitsecg/secp384r1 Quantum-vulnerable Recorded traffic Renamed import 1 place See details

Classical key pair generated with Node crypto

`crypto.generateKeyPair()` or its synchronous form. The detector resolves the algorithm through a `promisify()` wrapper and through an import alias, both of which are common enough that missing them would leave real key generation unreported.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. ML-KEM-768 for encryption, ML-DSA-65 for signatures. Node exposes neither yet, so this usually means an addon or a service boundary.

  1. test/external_signing/external_signing.config.js:9 test path const es384 = crypto.generateKeyPairSync('ec', { namedCurve: 'P-384' });
js.generatekeypair · CWE-327
ECDSA Quantum-vulnerable 1 place See details

Private key committed to the repository

A PEM private-key block. The header names the algorithm where the format is the legacy one; for PKCS#8 the algorithm OID is read out of the DER. A private key in version control is a present-day incident before it is a quantum question.

A secret key is stored in this repository's files. Anyone who can read the repository can use it. This needs attention today, regardless of quantum computers.

What to do. Revoke and rotate the key, then keep key material out of the repository. Record the algorithm in the inventory.

  1. test/jwks/ec.key:1 test path -----BEGIN EC PRIVATE KEY-----
pem.private-key · CWE-321, CWE-327
ECDSA256-bitsecg/secp256r1 Quantum-vulnerable 1 place See details

Public key declared as a JSON Web Key

A `kty` field, with the curve read from the sibling `crv` where the family needs one. A JWKS document declares a key without naming an algorithm anywhere, so it is invisible to a scan that only looks for `alg`.

This file publishes the public keys other systems use to check this system's signatures. Everyone who trusts these keys has to accept the new kind of key before the old ones can be retired.

What to do. A published JWKS is what relying parties trust. It has to accept a post-quantum key type before the keys behind it can change, so put it early in the migration order.

  1. test/jwks/jwks.json:4 test path "kty": "EC",
jose.jwk · CWE-327
RSA2048-bit Quantum-vulnerable Recorded traffic Renamed import 1 place See details

Classical key pair generated with Node crypto

`crypto.generateKeyPair()` or its synchronous form. The detector resolves the algorithm through a `promisify()` wrapper and through an import alias, both of which are common enough that missing them would leave real key generation unreported.

A quantum computer of sufficient size breaks this completely. It has to be replaced, not tuned. Broken by Shor's algorithm on a cryptographically relevant quantum computer.

What to do. ML-KEM-768 for encryption, ML-DSA-65 for signatures. Node exposes neither yet, so this usually means an addon or a service boundary.

  1. test/external_signing/external_signing.config.js:10 test path const rs256 = crypto.generateKeyPairSync('rsa', { modulusLength: 2048 });
js.generatekeypair · CWE-327
RSA2048-bit Quantum-vulnerable 1 place See details

X.509 certificate

A PEM certificate. The subject public-key algorithm and key size are read from the SubjectPublicKeyInfo structure, and the not-after date is reported so certificates that outlive the migration window are visible.

This is a digital identity document. Its expiry date matters: one valid for many years locks in today's algorithms for that long.

What to do. Shorten certificate lifetimes so re-issuing with a post-quantum key is routine.

  1. test/jwks/rsa.crt:1 test path -----BEGIN CERTIFICATE-----
pem.certificate
RSA Quantum-vulnerable Recorded traffic 1 place See details

Private key committed to the repository

A PEM private-key block. The header names the algorithm where the format is the legacy one; for PKCS#8 the algorithm OID is read out of the DER. A private key in version control is a present-day incident before it is a quantum question.

A secret key is stored in this repository's files. Anyone who can read the repository can use it. This needs attention today, regardless of quantum computers.

What to do. Revoke and rotate the key, then keep key material out of the repository. Record the algorithm in the inventory.

  1. test/jwks/rsa.key:1 test path -----BEGIN RSA PRIVATE KEY-----
pem.private-key · CWE-321, CWE-327
AES-128 Reduced margin 85 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer weakens this but does not break it. Increasing the key or digest size restores the margin. Grover's algorithm halves the effective strength; the parameter, not the design, is the problem.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/fapi/index.js:333 enc: 'A128CBC-HS256',
  2. lib/consts/client_attributes.js:130 authorization_encrypted_response_enc: ['authorization_encrypted_response_alg', 'A128CBC-HS256'],
  3. lib/consts/client_attributes.js:131 id_token_encrypted_response_enc: ['id_token_encrypted_response_alg', 'A128CBC-HS256'],
  4. lib/consts/client_attributes.js:132 introspection_encrypted_response_enc: ['introspection_encrypted_response_alg', 'A128CBC-HS256'],
  5. lib/consts/client_attributes.js:133 request_object_encryption_enc: ['request_object_encryption_alg', 'A128CBC-HS256'],
  6. lib/consts/client_attributes.js:134 userinfo_encrypted_response_enc: ['userinfo_encrypted_response_alg', 'A128CBC-HS256'],
  7. lib/consts/jwa.js:21 'A128GCMKW', 'A192GCMKW', 'A256GCMKW', 'A128KW', 'A192KW', 'A256KW',
  8. lib/consts/jwa.js:27 'A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM',
  9. lib/helpers/defaults.js:3575 'A128KW',
  10. lib/helpers/defaults.js:3604 'A128KW',
  11. lib/helpers/defaults.js:3633 'A128KW',
  12. lib/helpers/defaults.js:3663 'A128KW',
  13. lib/helpers/defaults.js:3693 'A128KW',
  14. lib/helpers/defaults.js:3715 'A128CBC-HS256',
  15. lib/helpers/defaults.js:3716 'A128GCM',
  16. lib/helpers/defaults.js:3735 'A128CBC-HS256',
  17. lib/helpers/defaults.js:3736 'A128GCM',
  18. lib/helpers/defaults.js:3755 'A128CBC-HS256',
  19. lib/helpers/defaults.js:3756 'A128GCM',
  20. lib/helpers/defaults.js:3775 'A128CBC-HS256',
  21. lib/helpers/defaults.js:3776 'A128GCM',
  22. lib/helpers/defaults.js:3795 'A128CBC-HS256',
  23. lib/helpers/defaults.js:3796 'A128GCM',
  24. test/configuration/client_keystore.test.js:45 test path id_token_encrypted_response_enc: 'A128CBC-HS256',
  25. test/configuration/client_metadata.test.js:1027 test path 'A128GCMKW',
  26. test/configuration/client_metadata.test.js:1030 test path 'A128KW',
  27. test/configuration/client_metadata.test.js:1051 test path 'A128CBC-HS256',
  28. test/configuration/client_metadata.test.js:1067 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  29. test/configuration/client_metadata.test.js:1133 test path 'A128GCMKW',
  30. test/configuration/client_metadata.test.js:1136 test path 'A128KW',
  31. test/configuration/client_metadata.test.js:1151 test path 'A128CBC-HS256',
  32. test/configuration/client_metadata.test.js:1169 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  33. test/configuration/client_metadata.test.js:1238 test path 'A128GCMKW',
  34. test/configuration/client_metadata.test.js:1241 test path 'A128KW',
  35. test/configuration/client_metadata.test.js:1256 test path 'A128CBC-HS256',
  36. test/configuration/client_metadata.test.js:1272 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  37. test/configuration/client_metadata.test.js:1338 test path 'A128GCMKW',
  38. test/configuration/client_metadata.test.js:1341 test path 'A128KW',
  39. test/configuration/client_metadata.test.js:1356 test path 'A128CBC-HS256',
  40. test/configuration/client_metadata.test.js:1372 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  41. test/configuration/client_metadata.test.js:1442 test path 'A128GCMKW',
  42. test/configuration/client_metadata.test.js:1445 test path 'A128KW',
  43. test/configuration/client_metadata.test.js:1460 test path 'A128CBC-HS256',
  44. test/configuration/client_metadata.test.js:1474 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  45. test/encryption/encryption.config.js:47 test path id_token_encrypted_response_alg: 'A128KW',
  46. test/encryption/encryption.config.js:56 test path id_token_encrypted_response_alg: 'A128KW',
  47. test/encryption/encryption.test.js:25 test path 'A128GCMKW', 'A192GCMKW', 'A256GCMKW', 'A128KW', 'A192KW', 'A256KW',
  48. test/encryption/encryption.test.js:181 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP-512' })
  49. test/encryption/encryption.test.js:248 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  50. test/encryption/encryption.test.js:289 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  51. test/encryption/encryption.test.js:365 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128KW' });
  52. test/encryption/encryption.test.js:369 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'A128KW' })
  53. test/encryption/encryption.test.js:401 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128KW' });
  54. test/encryption/encryption.test.js:405 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'A128KW' })
  55. test/encryption/encryption.test.js:431 test path expect(header).to.have.property('alg', 'A128KW');
  56. test/encryption/encryption.test.js:463 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128CBC-HS256' });
  57. test/encryption/encryption.test.js:467 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'dir' })
  58. test/encryption/encryption.test.js:499 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128CBC-HS256' });
  59. test/encryption/encryption.test.js:503 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'dir' })
  60. test/encryption/encryption.test.js:530 test path expect(header).to.have.property('enc', 'A128CBC-HS256');
  61. test/formats/jwt.test.js:212 test path enc: 'A128GCM',
  62. test/formats/jwt.test.js:271 test path enc: 'A128GCM',
  63. test/formats/jwt.test.js:283 test path expect(header).to.have.property('enc', 'A128GCM');
  64. test/formats/jwt.test.js:298 test path enc: 'A128GCM',
  65. test/formats/jwt.test.js:310 test path expect(header).to.have.property('enc', 'A128GCM');
  66. test/formats/jwt.test.js:325 test path enc: 'A128GCM',
  67. test/formats/jwt.test.js:337 test path expect(header).to.have.property('enc', 'A128GCM');
  68. test/formats/jwt.test.js:352 test path enc: 'A128GCM',
  69. test/formats/jwt.test.js:377 test path enc: 'A128GCM',
  70. test/formats/jwt.test.js:389 test path expect(header).to.have.property('enc', 'A128GCM');
  71. test/formats/jwt.test.js:406 test path enc: 'A128GCM',
  72. test/formats/jwt.test.js:429 test path enc: 'A128GCM',
  73. test/formats/jwt.test.js:441 test path expect(header).to.have.property('enc', 'A128GCM');
  74. test/formats/jwt.test.js:556 test path enc: 'A128GCM',
  75. test/formats/jwt.test.js:578 test path enc: 'A128GCM',
  76. test/formats/jwt.test.js:601 test path enc: 'A128GCM',
  77. test/jwt_introspection/jwt_introspection.config.js:33 test path introspection_encrypted_response_alg: 'A128KW',
  78. test/jwt_introspection/jwt_introspection.test.js:173 test path expect(header).to.have.property('alg', 'A128KW');
  79. test/jwt_introspection/jwt_introspection.test.js:174 test path expect(header).to.have.property('enc', 'A128CBC-HS256');
  80. test/jwt/jsonwebtoken.test.js:140 test path () => generateSecret('A128GCM', { extractable: true }),
  81. test/jwt/jsonwebtoken.test.js:158 test path alg: 'dir', enc: 'A128GCM',
  82. test/jwt/jsonwebtoken.test.js:179 test path alg: 'dir', enc: 'A128GCM',
  83. test/jwt_response_modes/jwt_response_modes.config.js:29 test path authorization_encrypted_response_alg: 'A128KW',
  84. test/openid4vci/openid4vci.test.js:204 test path enc_values_supported: ['A128GCM'],
  85. test/openid4vci/openid4vci.test.js:226 test path enc_values_supported: ['A128GCM'],
jose.algorithm · CWE-327
AES-128 Reduced margin 25 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer weakens this but does not break it. Increasing the key or digest size restores the margin. Grover's algorithm halves the effective strength; the parameter, not the design, is the problem.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/fapi/index.js:333 enc: 'A128CBC-HS256',
  2. test/encryption/encryption.test.js:181 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP-512' })
  3. test/encryption/encryption.test.js:248 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  4. test/encryption/encryption.test.js:289 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'RSA-OAEP' })
  5. test/encryption/encryption.test.js:365 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128KW' });
  6. test/encryption/encryption.test.js:369 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'A128KW' })
  7. test/encryption/encryption.test.js:401 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128KW' });
  8. test/encryption/encryption.test.js:405 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'A128KW' })
  9. test/encryption/encryption.test.js:463 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128CBC-HS256' });
  10. test/encryption/encryption.test.js:467 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'dir' })
  11. test/encryption/encryption.test.js:499 test path let [key] = client.symmetricKeyStore.selectForEncrypt({ alg: 'A128CBC-HS256' });
  12. test/encryption/encryption.test.js:503 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'dir' })
  13. test/formats/jwt.test.js:212 test path enc: 'A128GCM',
  14. test/formats/jwt.test.js:271 test path enc: 'A128GCM',
  15. test/formats/jwt.test.js:298 test path enc: 'A128GCM',
  16. test/formats/jwt.test.js:325 test path enc: 'A128GCM',
  17. test/formats/jwt.test.js:352 test path enc: 'A128GCM',
  18. test/formats/jwt.test.js:377 test path enc: 'A128GCM',
  19. test/formats/jwt.test.js:406 test path enc: 'A128GCM',
  20. test/formats/jwt.test.js:429 test path enc: 'A128GCM',
  21. test/formats/jwt.test.js:556 test path enc: 'A128GCM',
  22. test/formats/jwt.test.js:578 test path enc: 'A128GCM',
  23. test/formats/jwt.test.js:601 test path enc: 'A128GCM',
  24. test/jwt/jsonwebtoken.test.js:158 test path alg: 'dir', enc: 'A128GCM',
  25. test/jwt/jsonwebtoken.test.js:179 test path alg: 'dir', enc: 'A128GCM',
js.jwt.algorithm · CWE-327
AES-192 Reduced margin 20 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

A quantum computer weakens this but does not break it. Increasing the key or digest size restores the margin. Grover's algorithm halves the effective strength; the parameter, not the design, is the problem.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/jwa.js:21 'A128GCMKW', 'A192GCMKW', 'A256GCMKW', 'A128KW', 'A192KW', 'A256KW',
  2. lib/consts/jwa.js:27 'A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM',
  3. test/configuration/client_metadata.test.js:1028 test path 'A192GCMKW',
  4. test/configuration/client_metadata.test.js:1031 test path 'A192KW',
  5. test/configuration/client_metadata.test.js:1067 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  6. test/configuration/client_metadata.test.js:1134 test path 'A192GCMKW',
  7. test/configuration/client_metadata.test.js:1137 test path 'A192KW',
  8. test/configuration/client_metadata.test.js:1169 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  9. test/configuration/client_metadata.test.js:1239 test path 'A192GCMKW',
  10. test/configuration/client_metadata.test.js:1242 test path 'A192KW',
  11. test/configuration/client_metadata.test.js:1272 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  12. test/configuration/client_metadata.test.js:1339 test path 'A192GCMKW',
  13. test/configuration/client_metadata.test.js:1342 test path 'A192KW',
  14. test/configuration/client_metadata.test.js:1372 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  15. test/configuration/client_metadata.test.js:1443 test path 'A192GCMKW',
  16. test/configuration/client_metadata.test.js:1446 test path 'A192KW',
  17. test/configuration/client_metadata.test.js:1474 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  18. test/encryption/encryption.config.js:19 test path pull(config.enabledJWA.requestObjectEncryptionEncValues, 'A192CBC-HS384');
  19. test/encryption/encryption.test.js:25 test path 'A128GCMKW', 'A192GCMKW', 'A256GCMKW', 'A128KW', 'A192KW', 'A256KW',
  20. test/encryption/encryption.test.js:212 test path .setProtectedHeader({ enc: 'A192CBC-HS384', alg: 'RSA-OAEP-512' })
jose.algorithm · CWE-327
SHA-256 Reduced margin Renamed import 3 places See details

Hash function in use

`createHash()` or `subtle.digest()`. The digest is read from the argument, so one rule covers the family: MD5 and SHA-1 are reported as broken, SHA-256 as a reduced margin, SHA-384 and above as inventory.

A quantum computer weakens this but does not break it. Increasing the key or digest size restores the margin. Pre-image resistance falls to about 128 bits of quantum work. Adequate for most uses; SHA-384 restores the full margin where a signature must last decades.

What to do. SHA-256 as the floor, SHA-384 where the digest protects something long-lived.

  1. certification/oidc/configuration.js:191 return crypto.createHash('sha256')
  2. test/introspection/introspection.config.js:18 test path .createHash('sha256')
  3. test/pairwise/pairwise.config.js:13 test path .createHash('sha256')
js.hash · CWE-328
AES-192 Reduced margin 1 place See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

A quantum computer weakens this but does not break it. Increasing the key or digest size restores the margin. Grover's algorithm halves the effective strength; the parameter, not the design, is the problem.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. test/encryption/encryption.test.js:212 test path .setProtectedHeader({ enc: 'A192CBC-HS384', alg: 'RSA-OAEP-512' })
js.jwt.algorithm · CWE-327
unknown Could not be determined 2 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

The algorithm could not be established from the source. Usually it is selected while the program runs, but it may equally be that the call gives no clue, or that it is decided somewhere this scan does not reach. Somebody has to check.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. test/formats/jwt.test.js:453 test path alg: 'none',
  2. test/pushed_authorization_requests/pushed_authorization_requests.test.js:237 test path expect(header).to.deep.eql({ alg: 'none' });
js.jwt.algorithm · CWE-327
unknown Could not be determined 1 place See details

Key pair algorithm chosen at runtime

`generateKeyPair(x, …)` where the first argument is an identifier rather than a literal. Reported as unresolved rather than assumed.

This code picks its encryption method while it runs. A scan cannot tell which one it ends up using.

What to do. Trace the value to its configuration source and record the concrete algorithm by hand.

  1. test/keys.js:8 test path const result = await generateKeyPair(alg, { extractable: true });
js.generatekeypair.variable · CWE-327
unknown Could not be determined 1 place See details

Cryptographic library in the dependency manifest

A dependency known to implement classical asymmetric cryptography. Its presence is inventory, not a finding about this codebase: the library may never be called with a quantum-vulnerable algorithm.

The project depends on a cryptography library. Listed so the inventory is complete; it is not by itself a problem.

What to do. Check the version. Several of these libraries have shipped ML-KEM and ML-DSA support since 2024, so the migration may need an upgrade rather than a replacement.

  1. package.json:62 "jose": "^6.2.8",
dep.crypto-library
HMAC Quantum-safe Renamed import 186 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

No known quantum attack changes how strong this is. A keyed MAC is not affected by Shor and only marginally by Grover.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/jwa.js:2 'HS256', 'HS384', 'HS512',
  2. lib/helpers/defaults.js:3427 'HS256',
  3. lib/helpers/defaults.js:3474 'HS256',
  4. lib/models/id_token.js:18 case 'HS256':
  5. lib/models/id_token.js:23 case 'HS384':
  6. lib/models/id_token.js:28 case 'HS512':
  7. test/ciba/ciba.test.js:855 test path expect(response.body).to.have.property('backchannel_authentication_request_signing_alg_values_supported').not.contains('HS256');
  8. test/client_auth/client_auth.test.js:145 test path clientAuthSigningAlgValues: ['HS256'],
  9. test/client_auth/client_auth.test.js:164 test path 'HS256',
  10. test/client_auth/client_auth.test.js:165 test path 'HS384',
  11. test/client_auth/client_auth.test.js:166 test path 'HS512',
  12. test/client_auth/client_auth.test.js:214 test path 'HS256',
  13. test/client_auth/client_auth.test.js:215 test path 'HS384',
  14. test/client_auth/client_auth.test.js:216 test path 'HS512',
  15. test/client_auth/client_auth.test.js:651 test path this.key = await importJWK((await this.provider.Client.find('client-jwt-secret')).symmetricKeyStore.selectForSign({ alg: 'HS256' })[0]);
  16. test/client_auth/client_auth.test.js:660 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  17. test/client_auth/client_auth.test.js:677 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  18. test/client_auth/client_auth.test.js:694 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  19. test/client_auth/client_auth.test.js:712 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post('/token/introspection')
  20. test/client_auth/client_auth.test.js:730 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post('/token/introspection')
  21. test/client_auth/client_auth.test.js:750 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  22. test/client_auth/client_auth.test.js:773 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  23. test/client_auth/client_auth.test.js:795 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  24. test/client_auth/client_auth.test.js:837 test path }, this.key, 'HS256', {
  25. test/client_auth/client_auth.test.js:862 test path }, this.key, 'HS256', {
  26. test/client_auth/client_auth.test.js:888 test path }, this.key, 'HS256', {
  27. test/client_auth/client_auth.test.js:914 test path }, this.key, 'HS256', {
  28. test/client_auth/client_auth.test.js:940 test path }, this.key, 'HS256', {
  29. test/client_auth/client_auth.test.js:966 test path }, this.key, 'HS256', {
  30. test/client_auth/client_auth.test.js:990 test path }, this.key, 'HS256', { expiresIn: 60 }).then((assertion) => this.agent.post(route)
  31. test/client_auth/client_auth.test.js:1012 test path }, this.key, 'HS256', {
  32. test/client_auth/client_auth.test.js:1035 test path }, this.key, 'HS256', {
  33. test/client_auth/client_auth.test.js:1076 test path }, this.key, 'HS256', {
  34. test/client_auth/client_auth.test.js:1095 test path const key = await importJWK((await this.provider.Client.find('secret-expired-jwt')).symmetricKeyStore.selectForSign({ alg: 'HS256' })[0]);
  35. test/client_auth/client_auth.test.js:1101 test path }, key, 'HS256', {
  36. test/client_auth/client_auth.test.js:1126 test path }, this.key, 'HS256', {
  37. test/client_auth/client_auth.test.js:1159 test path (await this.provider.Client.find('client-jwt-secret')).tokenEndpointAuthSigningAlg = 'HS384';
  38. test/client_auth/client_auth.test.js:1172 test path }, this.key, 'HS256', {
  39. test/configuration/client_keystore.test.js:43 test path id_token_signed_response_alg: 'HS256',
  40. test/configuration/client_metadata.test.js:633 test path 'HS256',
  41. test/configuration/client_metadata.test.js:634 test path 'HS384',
  42. test/configuration/client_metadata.test.js:635 test path 'HS512',
  43. test/configuration/client_metadata.test.js:945 test path allows(this.title, 'HS256', undefined, configuration);
  44. test/configuration/client_metadata.test.js:966 test path allows(this.title, 'HS256', undefined, configuration);
  45. test/configuration/client_metadata.test.js:975 test path allows(this.title, 'HS256', undefined, configuration);
  46. test/configuration/client_metadata.test.js:1617 test path rejects(this.title, 'HS256', undefined, metadata, withRequestObjects);
  47. test/configuration/client_metadata.test.js:1618 test path rejects(this.title, 'HS384', undefined, metadata, withRequestObjects);
  48. test/configuration/client_metadata.test.js:1619 test path rejects(this.title, 'HS512', undefined, metadata, withRequestObjects);
  49. test/configuration/configuration.test.js:13 test path clientAuthSigningAlgValues: ['HS256', 'RS256'],
  50. test/configuration/configuration.test.js:44 test path expect(input.enabledJWA.clientAuthSigningAlgValues).to.eql(['HS256', 'RS256']);
  51. test/configuration/omit_algs.test.js:11 test path invalidProperty: ['HS256', 'RS256'],
  52. test/configuration/omit_algs.test.js:21 test path idTokenSigningAlgValues: new Set(['HS256', 'RS256']),
  53. test/configuration/omit_algs.test.js:41 test path idTokenSigningAlgValues: ['HS256', 'RS256'],
  54. test/configuration/omit_algs.test.js:48 test path expect(i(provider).configuration.idTokenSigningAlgValues).to.eql(['HS256', 'RS256']);
  55. test/core/implicit/implicit.config.js:16 test path id_token_signed_response_alg: 'HS256',
  56. test/dpop/dpop.test.js:150 test path for (const value of [1, true, 'none', 'HS256', 'unsupported']) {
  57. test/dpop/dpop.test.js:666 test path .setProtectedHeader({ alg: 'HS256' })
  58. test/dynamic_registration/dynamic_registration.test.js:264 test path id_token_signed_response_alg: 'HS256',
  59. test/encryption/encryption.config.js:72 test path request_object_signing_alg: 'HS256',
  60. test/encryption/encryption.test.js:123 test path client.userinfoSignedResponseAlg = 'HS256';
  61. test/encryption/encryption.test.js:175 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer });
  62. test/encryption/encryption.test.js:206 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer });
  63. test/encryption/encryption.test.js:236 test path const [hsSecret] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  64. test/encryption/encryption.test.js:242 test path }, client.symmetricKeyStore.getKeyObject(hsSecret), 'HS256', { issuer: 'client', audience: this.provider.issuer });
  65. test/encryption/encryption.test.js:277 test path const [hsSecret] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  66. test/encryption/encryption.test.js:283 test path }, client.symmetricKeyStore.getKeyObject(hsSecret), 'HS256', { issuer: 'clientRequestObjectSigningAlg', audience: this.provider.issuer });
  67. test/encryption/encryption.test.js:363 test path }, Buffer.from('secret'), 'HS256', { issuer: 'clientSymmetric', audience: this.provider.issuer });
  68. test/encryption/encryption.test.js:399 test path }, Buffer.from('secret'), 'HS256', { issuer: 'clientSymmetric-expired', audience: this.provider.issuer });
  69. test/encryption/encryption.test.js:461 test path }, Buffer.from('secret'), 'HS256', { issuer: 'clientSymmetric-dir', audience: this.provider.issuer });
  70. test/encryption/encryption.test.js:497 test path }, Buffer.from('secret'), 'HS256', { issuer: 'clientSymmetric-expired', audience: this.provider.issuer });
  71. test/end_session/end_session.config.js:22 test path id_token_signed_response_alg: 'HS256',
  72. test/end_session/end_session.test.js:334 test path }, Buffer.from('secret'), 'HS256'),
  73. test/end_session/end_session.test.js:359 test path }, Buffer.from('not THE secret'), 'HS256'),
  74. test/formats/jwt.test.js:156 test path sign: { alg: 'HS256', key: crypto.randomBytes(32) },
  75. test/formats/jwt.test.js:165 test path expect(header).to.have.property('alg', 'HS256');
  76. test/formats/jwt.test.js:174 test path sign: { alg: 'HS256', key: await crypto.subtle.generateKey({ name: 'HMAC', hash: 'SHA-256' }, false, ['sign']) },
  77. test/formats/jwt.test.js:183 test path expect(header).to.have.property('alg', 'HS256');
  78. test/formats/jwt.test.js:192 test path sign: { alg: 'HS256', key: crypto.randomBytes(32), kid: 200 },
  79. test/formats/jwt.test.js:233 test path sign: { alg: 'HS256', key: crypto.randomBytes(32), kid: 'feb-2020' },
  80. test/formats/jwt.test.js:250 test path sign: { alg: 'HS256', key: crypto.createSecretKey(crypto.randomBytes(32)) },
  81. test/formats/jwt.test.js:259 test path expect(header).to.have.property('alg', 'HS256');
  82. test/formats/jwt.test.js:473 test path alg: 'HS256',
  83. test/formats/jwt.test.js:493 test path alg: 'HS256',
  84. test/formats/jwt.test.js:514 test path alg: 'HS256',
  85. test/id_token_claims/conform.config.js:23 test path userinfo_signed_response_alg: 'HS256',
  86. test/id_token_claims/conform.test.js:90 test path client.userinfoSignedResponseAlg = 'HS256';
  87. test/id_token_claims/non_conform.test.js:80 test path client.userinfoSignedResponseAlg = 'HS256';
  88. test/jwt_introspection/jwt_introspection.config.js:26 test path introspection_signed_response_alg: 'HS256',
  89. test/jwt/jsonwebtoken.test.js:49 test path const keyobject = await generateSecret('HS256', { extractable: true });
  90. test/jwt/jsonwebtoken.test.js:62 test path const keyobject = await generateSecret('HS256', { extractable: true });
  91. test/jwt/jsonwebtoken.test.js:64 test path return JWT.sign({ data: true }, keyobject, 'HS256')
  92. test/jwt/jsonwebtoken.test.js:68 test path expect(decoded.header).to.have.property('alg', 'HS256');
  93. test/jwt/jsonwebtoken.test.js:74 test path const keyobject = await generateSecret('HS256', { extractable: true });
  94. test/jwt/jsonwebtoken.test.js:75 test path return JWT.sign({ 'ś∂źć√': 'ś∂źć√' }, keyobject, 'HS256')
  95. test/jwt/jsonwebtoken.test.js:135 test path () => generateSecret('HS256', { extractable: true }),
  96. test/jwt/jsonwebtoken.test.js:147 test path const jwt = await JWT.sign({ data: true }, signingKeys[position], 'HS256');
  97. test/jwt/jsonwebtoken.test.js:169 test path const jwt = await JWT.sign({ data: true }, signingKeys[3], 'HS256');
  98. test/jwt/jsonwebtoken.test.js:189 test path const jwt = await JWT.sign({ data: true }, signingKeys[3], 'HS256');
  99. test/jwt/jsonwebtoken.test.js:207 test path it('iat by default', async () => JWT.sign({ data: true }, await generateSecret('HS256', { extractable: true }), 'HS256')
  100. test/jwt/jsonwebtoken.test.js:213 test path it('expiresIn', async () => JWT.sign({ data: true }, await generateSecret('HS256', { extractable: true }), 'HS256', { expiresIn: 60 })
  101. test/jwt/jsonwebtoken.test.js:219 test path it('audience', async () => JWT.sign({ data: true }, await generateSecret('HS256', { extractable: true }), 'HS256', { audience: 'clientId' })
  102. test/jwt/jsonwebtoken.test.js:225 test path it('issuer', async () => JWT.sign({ data: true }, await generateSecret('HS256', { extractable: true }), 'HS256', { issuer: 'http://example.com/issuer' })
  103. test/jwt/jsonwebtoken.test.js:231 test path it('subject', async () => JWT.sign({ data: true }, await generateSecret('HS256', { extractable: true }), 'HS256', { subject: 'http://example.com/subject' })
  104. test/jwt/jsonwebtoken.test.js:240 test path const keyobject = await generateSecret('HS256', { extractable: true });
  105. test/jwt/jsonwebtoken.test.js:242 test path return JWT.sign({ data: true, nbf: epochTime() + 3600 }, keyobject, 'HS256')
  106. test/jwt/jsonwebtoken.test.js:254 test path const keyobject = await generateSecret('HS256', { extractable: true });
  107. test/jwt/jsonwebtoken.test.js:256 test path return JWT.sign({ data: true, nbf: epochTime() + 3600 }, keyobject, 'HS256')
  108. test/jwt/jsonwebtoken.test.js:263 test path const keyobject = await generateSecret('HS256', { extractable: true });
  109. test/jwt/jsonwebtoken.test.js:265 test path return JWT.sign({ data: true, nbf: epochTime() + 5 }, keyobject, 'HS256')
  110. test/jwt/jsonwebtoken.test.js:272 test path const keyobject = await generateSecret('HS256', { extractable: true });
  111. test/jwt/jsonwebtoken.test.js:274 test path return JWT.sign({ data: true, nbf: 'not a nbf' }, keyobject, 'HS256')
  112. test/jwt/jsonwebtoken.test.js:286 test path const keyobject = await generateSecret('HS256', { extractable: true });
  113. test/jwt/jsonwebtoken.test.js:288 test path return JWT.sign({ data: true, iat: epochTime() + 3600 }, keyobject, 'HS256', {
  114. test/jwt/jsonwebtoken.test.js:302 test path const keyobject = await generateSecret('HS256', { extractable: true });
  115. test/jwt/jsonwebtoken.test.js:304 test path return JWT.sign({ data: true, iat: epochTime() + 3600 }, keyobject, 'HS256', {
  116. test/jwt/jsonwebtoken.test.js:313 test path const keyobject = await generateSecret('HS256', { extractable: true });
  117. test/jwt/jsonwebtoken.test.js:315 test path return JWT.sign({ data: true, iat: epochTime() + 5 }, keyobject, 'HS256', {
  118. test/jwt/jsonwebtoken.test.js:324 test path const keyobject = await generateSecret('HS256', { extractable: true });
  119. test/jwt/jsonwebtoken.test.js:326 test path return JWT.sign({ data: true, iat: 'not an iat' }, keyobject, 'HS256', {
  120. test/jwt/jsonwebtoken.test.js:340 test path const keyobject = await generateSecret('HS256', { extractable: true });
  121. test/jwt/jsonwebtoken.test.js:342 test path return JWT.sign({ data: true, exp: epochTime() - 3600 }, keyobject, 'HS256')
  122. test/jwt/jsonwebtoken.test.js:354 test path const keyobject = await generateSecret('HS256', { extractable: true });
  123. test/jwt/jsonwebtoken.test.js:356 test path return JWT.sign({ data: true, exp: epochTime() - 3600 }, keyobject, 'HS256')
  124. test/jwt/jsonwebtoken.test.js:363 test path const keyobject = await generateSecret('HS256', { extractable: true });
  125. test/jwt/jsonwebtoken.test.js:365 test path return JWT.sign({ data: true, exp: epochTime() - 5 }, keyobject, 'HS256')
  126. test/jwt/jsonwebtoken.test.js:372 test path const keyobject = await generateSecret('HS256', { extractable: true });
  127. test/jwt/jsonwebtoken.test.js:374 test path return JWT.sign({ data: true, exp: 'not an exp' }, keyobject, 'HS256')
  128. test/jwt/jsonwebtoken.test.js:386 test path const keyobject = await generateSecret('HS256', { extractable: true });
  129. test/jwt/jsonwebtoken.test.js:388 test path return JWT.sign({ data: true }, keyobject, 'HS256', {
  130. test/jwt/jsonwebtoken.test.js:397 test path const keyobject = await generateSecret('HS256', { extractable: true });
  131. test/jwt/jsonwebtoken.test.js:399 test path return JWT.sign({ data: true }, keyobject, 'HS256', {
  132. test/jwt/jsonwebtoken.test.js:408 test path const keyobject = await generateSecret('HS256', { extractable: true });
  133. test/jwt/jsonwebtoken.test.js:410 test path return JWT.sign({ data: true }, keyobject, 'HS256', {
  134. test/jwt/jsonwebtoken.test.js:427 test path const keyobject = await generateSecret('HS256', { extractable: true });
  135. test/jwt/jsonwebtoken.test.js:429 test path return JWT.sign({ data: true }, keyobject, 'HS256', {
  136. test/jwt/jsonwebtoken.test.js:446 test path const keyobject = await generateSecret('HS256', { extractable: true });
  137. test/jwt/jsonwebtoken.test.js:448 test path return JWT.sign({ data: true }, keyobject, 'HS256', {
  138. test/jwt/jsonwebtoken.test.js:457 test path const keyobject = await generateSecret('HS256', { extractable: true });
  139. test/jwt/jsonwebtoken.test.js:459 test path return JWT.sign({ data: true }, keyobject, 'HS256', {
  140. test/jwt_response_modes/jwt_response_modes.config.js:38 test path authorization_signed_response_alg: 'HS256',
  141. test/pushed_authorization_requests/pushed_authorization_requests.config.js:51 test path request_object_signing_alg: 'HS256',
  142. test/pushed_authorization_requests/pushed_authorization_requests.test.js:381 test path this.key = await importJWK(client.symmetricKeyStore.selectForSign({ alg: 'HS256' })[0]);
  143. test/pushed_authorization_requests/pushed_authorization_requests.test.js:428 test path }, this.key, 'HS256', { expiresIn: 30 }).then((request) => {
  144. test/pushed_authorization_requests/pushed_authorization_requests.test.js:452 test path }, this.key, 'HS256', {
  145. test/pushed_authorization_requests/pushed_authorization_requests.test.js:484 test path }, this.key, 'HS256'),
  146. test/pushed_authorization_requests/pushed_authorization_requests.test.js:508 test path }, this.key, 'HS256', {
  147. test/pushed_authorization_requests/pushed_authorization_requests.test.js:536 test path }, this.key, 'HS256', {
  148. test/pushed_authorization_requests/pushed_authorization_requests.test.js:566 test path }, this.key, 'HS256', { expiresIn: 30 }),
  149. test/pushed_authorization_requests/pushed_authorization_requests.test.js:586 test path }, this.key, 'HS384'),
  150. test/pushed_authorization_requests/pushed_authorization_requests.test.js:604 test path }, this.key, 'HS256', { expiresIn: 30 }),
  151. test/pushed_authorization_requests/pushed_authorization_requests.test.js:625 test path }, this.key, 'HS256', { expiresIn: 30 }),
  152. test/pushed_authorization_requests/pushed_authorization_requests.test.js:647 test path }, this.key, 'HS256', { expiresIn: 30 }),
  153. test/pushed_authorization_requests/pushed_authorization_requests.test.js:676 test path }, this.key, 'HS256', { expiresIn: 30 }),
  154. test/registration_policies/registration_policies.test.js:73 test path properties.id_token_signed_response_alg = 'HS256';
  155. test/registration_policies/registration_policies.test.js:87 test path expect(body).to.have.property('id_token_signed_response_alg', 'HS256');
  156. test/registration_policies/registration_policies.test.js:108 test path properties.id_token_signed_response_alg = 'HS256';
  157. test/registration_policies/registration_policies.test.js:124 test path expect(body).to.have.property('id_token_signed_response_alg', 'HS256');
  158. test/request/jwt_request.test.js:93 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  159. test/request/jwt_request.test.js:124 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  160. test/request/jwt_request.test.js:155 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  161. test/request/jwt_request.test.js:191 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  162. test/request/jwt_request.test.js:224 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  163. test/request/jwt_request.test.js:245 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  164. test/request/jwt_request.test.js:257 test path }, key, 'HS256', { issuer: 'client-with-HS-sig', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  165. test/request/jwt_request.test.js:274 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  166. test/request/jwt_request.test.js:284 test path }, key, 'HS256', { issuer: 'client-with-HS-sig', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  167. test/request/jwt_request.test.js:301 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  168. test/request/jwt_request.test.js:314 test path }, key, 'HS256', { issuer: 'client-with-HS-sig-expired', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  169. test/request/jwt_request.test.js:348 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  170. test/request/jwt_request.test.js:382 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  171. test/request/jwt_request.test.js:415 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  172. test/request/jwt_request.test.js:443 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  173. test/request/jwt_request.test.js:477 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  174. test/request/jwt_request.test.js:511 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client2', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  175. test/request/jwt_request.test.js:546 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client2', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  176. test/request/jwt_request.test.js:603 test path }, Buffer.from('secret'), 'HS512', { issuer: 'client-with-HS-sig', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  177. test/request/jwt_request.test.js:636 test path }, crypto.createSecretKey(crypto.randomBytes(48)), 'HS384', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  178. test/request/jwt_request.test.js:665 test path }, Buffer.from('not THE secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  179. test/request/jwt_request.test.js:696 test path }, Buffer.from('secret'), 'HS256', { issuer: 'client', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  180. test/request/jwt_request.test.js:716 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  181. test/request/jwt_request.test.js:727 test path }, key, 'HS256', { issuer: 'client-with-HS-sig', audience: this.provider.issuer, expiresIn: 30 }).then((request) => this.wrap({
  182. test/request/request.config.js:17 test path pull(config.enabledJWA.requestObjectSigningAlgValues, 'HS384');
  183. test/request/request.config.js:38 test path request_object_signing_alg: 'HS256',
  184. test/request/request.config.js:46 test path request_object_signing_alg: 'HS256',
  185. test/signatures/signatures.config.js:25 test path id_token_signed_response_alg: 'HS256',
  186. test/signatures/signatures.test.js:44 test path expect(decode(this.idToken)).to.have.nested.property('header.alg', 'HS256');
jose.algorithm · CWE-327
AES-256 Quantum-safe 33 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. lib/consts/jwa.js:21 'A128GCMKW', 'A192GCMKW', 'A256GCMKW', 'A128KW', 'A192KW', 'A256KW',
  2. lib/consts/jwa.js:27 'A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM',
  3. lib/helpers/defaults.js:3576 'A256KW',
  4. lib/helpers/defaults.js:3605 'A256KW',
  5. lib/helpers/defaults.js:3634 'A256KW',
  6. lib/helpers/defaults.js:3664 'A256KW',
  7. lib/helpers/defaults.js:3694 'A256KW',
  8. lib/helpers/defaults.js:3717 'A256CBC-HS512',
  9. lib/helpers/defaults.js:3718 'A256GCM',
  10. lib/helpers/defaults.js:3737 'A256CBC-HS512',
  11. lib/helpers/defaults.js:3738 'A256GCM',
  12. lib/helpers/defaults.js:3757 'A256CBC-HS512',
  13. lib/helpers/defaults.js:3758 'A256GCM',
  14. lib/helpers/defaults.js:3777 'A256CBC-HS512',
  15. lib/helpers/defaults.js:3778 'A256GCM',
  16. lib/helpers/defaults.js:3797 'A256CBC-HS512',
  17. lib/helpers/defaults.js:3798 'A256GCM',
  18. test/configuration/client_metadata.test.js:1029 test path 'A256GCMKW',
  19. test/configuration/client_metadata.test.js:1032 test path 'A256KW',
  20. test/configuration/client_metadata.test.js:1067 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  21. test/configuration/client_metadata.test.js:1135 test path 'A256GCMKW',
  22. test/configuration/client_metadata.test.js:1138 test path 'A256KW',
  23. test/configuration/client_metadata.test.js:1169 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  24. test/configuration/client_metadata.test.js:1240 test path 'A256GCMKW',
  25. test/configuration/client_metadata.test.js:1243 test path 'A256KW',
  26. test/configuration/client_metadata.test.js:1272 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  27. test/configuration/client_metadata.test.js:1340 test path 'A256GCMKW',
  28. test/configuration/client_metadata.test.js:1343 test path 'A256KW',
  29. test/configuration/client_metadata.test.js:1372 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  30. test/configuration/client_metadata.test.js:1444 test path 'A256GCMKW',
  31. test/configuration/client_metadata.test.js:1447 test path 'A256KW',
  32. test/configuration/client_metadata.test.js:1474 test path ['A128CBC-HS256', 'A128GCM', 'A192CBC-HS384', 'A192GCM', 'A256CBC-HS512', 'A256GCM'].forEach(
  33. test/encryption/encryption.test.js:25 test path 'A128GCMKW', 'A192GCMKW', 'A256GCMKW', 'A128KW', 'A192KW', 'A256KW',
jose.algorithm · CWE-327
CSPRNG Quantum-safe Renamed import 19 places See details

Random number generation

`crypto.randomBytes()`, `randomUUID()` or `getRandomValues()`. A platform CSPRNG is not a quantum exposure; it is recorded because an inventory that omits the randomness source is incomplete. `Math.random()` is a separate, present-day defect.

This is where the software gets its random numbers. Quantum computers do not weaken it.

What to do. No action.

  1. certification/fapi/index.js:105 const eKey = crypto.randomBytes(32);
  2. certification/oidc/configuration.js:173 nonceSecret: crypto.randomBytes(32),
  3. certification/oidc/index.js:53 ctx.res.locals.cspNonce = crypto.randomBytes(16).toString('base64');
  4. lib/helpers/defaults.js:274 return crypto.randomBytes(64).toString('base64url');
  5. lib/shared/xsrf.js:7 const secret = crypto.randomBytes(24).toString('hex');
  6. test/attest_bindings/attest_bindings.config.js:23 test path challengeSecret: randomBytes(32),
  7. test/attest_bindings/attest_bindings.test.js:39 test path .setJti(crypto.randomUUID())
  8. test/backchannel_logout/backchannel_logout.test.js:115 test path nonce: randomBytes(16).toString('base64url'),
  9. test/client_auth/client_auth.config.js:49 test path challengeSecret: randomBytes(32),
  10. test/configuration/keystore_configuration.test.js:35 test path { kty: 'oct', k: randomBytes(32).toString('base64url') },
  11. test/dpop/dpop.test.js:217 test path jwk: await exportJWK(randomBytes(32)),
  12. test/end_session/end_session.test.js:50 test path nonce: randomBytes(16).toString('base64url'),
  13. test/fapi/fapi2.test.js:82 test path jti: crypto.randomUUID(),
  14. test/formats/jwt.test.js:156 test path sign: { alg: 'HS256', key: crypto.randomBytes(32) },
  15. test/helpers/challenge.test.js:11 test path const secret = randomBytes(32);
  16. test/openid4vci/openid4vci.test.js:94 test path .setJti(randomUUID())
  17. test/pushed_authorization_requests/pushed_authorization_requests.test.js:423 test path jti: randomBytes(16).toString('base64url'),
  18. test/request/jwt_request.test.js:70 test path this.code_verifier = crypto.randomBytes(32).toString('base64url');
  19. test/test_helper.js:264 test path this.state = 'state' in parameters ? parameters.state : crypto.randomBytes(16).toString('base64url');
js.rng
HMAC Quantum-safe Renamed import 18 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

No known quantum attack changes how strong this is. A keyed MAC is not affected by Shor and only marginally by Grover.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. test/client_auth/client_auth.test.js:651 test path this.key = await importJWK((await this.provider.Client.find('client-jwt-secret')).symmetricKeyStore.selectForSign({ alg: 'HS256' })[0]);
  2. test/client_auth/client_auth.test.js:1095 test path const key = await importJWK((await this.provider.Client.find('secret-expired-jwt')).symmetricKeyStore.selectForSign({ alg: 'HS256' })[0]);
  3. test/dpop/dpop.test.js:666 test path .setProtectedHeader({ alg: 'HS256' })
  4. test/encryption/encryption.test.js:236 test path const [hsSecret] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  5. test/encryption/encryption.test.js:277 test path const [hsSecret] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  6. test/formats/jwt.test.js:156 test path sign: { alg: 'HS256', key: crypto.randomBytes(32) },
  7. test/formats/jwt.test.js:174 test path sign: { alg: 'HS256', key: await crypto.subtle.generateKey({ name: 'HMAC', hash: 'SHA-256' }, false, ['sign']) },
  8. test/formats/jwt.test.js:192 test path sign: { alg: 'HS256', key: crypto.randomBytes(32), kid: 200 },
  9. test/formats/jwt.test.js:233 test path sign: { alg: 'HS256', key: crypto.randomBytes(32), kid: 'feb-2020' },
  10. test/formats/jwt.test.js:250 test path sign: { alg: 'HS256', key: crypto.createSecretKey(crypto.randomBytes(32)) },
  11. test/formats/jwt.test.js:473 test path alg: 'HS256',
  12. test/formats/jwt.test.js:493 test path alg: 'HS256',
  13. test/formats/jwt.test.js:514 test path alg: 'HS256',
  14. test/pushed_authorization_requests/pushed_authorization_requests.test.js:381 test path this.key = await importJWK(client.symmetricKeyStore.selectForSign({ alg: 'HS256' })[0]);
  15. test/request/jwt_request.test.js:245 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  16. test/request/jwt_request.test.js:274 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  17. test/request/jwt_request.test.js:301 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
  18. test/request/jwt_request.test.js:716 test path let [key] = client.symmetricKeyStore.selectForSign({ alg: 'HS256' });
js.jwt.algorithm · CWE-327
ML-DSA-44 Quantum-safe 14 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/oidc/configuration.js:104 if (SubtleCrypto.supports?.('importKey', 'ML-DSA-44')) {
  2. certification/oidc/configuration.js:106 alg: 'ML-DSA-44',
  3. lib/consts/jwa.js:12 signingAlgValues.push('ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87');
  4. lib/helpers/initialize_keystore.js:82 case 'ML-DSA-44':
  5. lib/models/id_token.js:32 case 'ML-DSA-44':
  6. test/client_auth/client_auth.test.js:27 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  7. test/configuration/client_keystore.test.js:108 test path alg: 'ML-DSA-44',
  8. test/configuration/client_metadata.test.js:23 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  9. test/configuration/client_metadata.test.js:1784 test path [[{ kty: 'AKP', alg: 'ML-DSA-44' }], 'jwks.keys[0].pub must be a non-empty string for AKP keys'],
  10. test/configuration/client_metadata.test.js:1785 test path [[{ kty: 'AKP', alg: 'ML-DSA-44', pub: 'pub', priv: 'priv' }], 'jwks.keys[0].priv must not be provided for AKP keys'],
  11. test/configuration/keystore_configuration.test.js:52 test path if (SubtleCrypto.supports?.('generateKey', 'ML-DSA-44') !== true) {
  12. test/configuration/keystore_configuration.test.js:55 test path const { publicKey } = await generateKeyPair('ML-DSA-44');
  13. test/keys.js:19 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  14. test/signatures/signatures.test.js:97 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
jose.algorithm · CWE-327
AES-256 Quantum-safe 12 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/fapi/index.js:332 alg: 'dir',
  2. test/encryption/encryption.test.js:467 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'dir' })
  3. test/encryption/encryption.test.js:503 test path .setProtectedHeader({ enc: 'A128CBC-HS256', alg: 'dir' })
  4. test/formats/jwt.test.js:211 test path alg: 'dir',
  5. test/formats/jwt.test.js:270 test path alg: 'dir',
  6. test/formats/jwt.test.js:297 test path alg: 'dir',
  7. test/formats/jwt.test.js:324 test path alg: 'dir',
  8. test/formats/jwt.test.js:351 test path alg: 'dir',
  9. test/formats/jwt.test.js:555 test path alg: 'dir',
  10. test/formats/jwt.test.js:600 test path alg: 'dir',
  11. test/jwt/jsonwebtoken.test.js:158 test path alg: 'dir', enc: 'A128GCM',
  12. test/jwt/jsonwebtoken.test.js:179 test path alg: 'dir', enc: 'A128GCM',
js.jwt.algorithm · CWE-327
ML-DSA-65 Quantum-safe 9 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/oidc/configuration.js:113 if (SubtleCrypto.supports?.('importKey', 'ML-DSA-65')) {
  2. certification/oidc/configuration.js:115 alg: 'ML-DSA-65',
  3. lib/consts/jwa.js:12 signingAlgValues.push('ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87');
  4. lib/helpers/initialize_keystore.js:83 case 'ML-DSA-65':
  5. lib/models/id_token.js:33 case 'ML-DSA-65':
  6. test/client_auth/client_auth.test.js:27 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  7. test/configuration/client_metadata.test.js:23 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  8. test/keys.js:19 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  9. test/signatures/signatures.test.js:97 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
jose.algorithm · CWE-327
ML-DSA-87 Quantum-safe 9 places See details

JOSE algorithm declared in configuration

An `alg` value in JSON or YAML. `none` is reported as a critical defect; HS* is an HMAC and is not quantum-vulnerable; RS*, PS*, ES* and EdDSA are.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/oidc/configuration.js:122 if (SubtleCrypto.supports?.('importKey', 'ML-DSA-87')) {
  2. certification/oidc/configuration.js:124 alg: 'ML-DSA-87',
  3. lib/consts/jwa.js:12 signingAlgValues.push('ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87');
  4. lib/helpers/initialize_keystore.js:84 case 'ML-DSA-87':
  5. lib/models/id_token.js:34 case 'ML-DSA-87':
  6. test/client_auth/client_auth.test.js:27 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  7. test/configuration/client_metadata.test.js:23 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  8. test/keys.js:19 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
  9. test/signatures/signatures.test.js:97 test path for (const alg of ['ML-DSA-44', 'ML-DSA-65', 'ML-DSA-87']) {
jose.algorithm · CWE-327
ML-DSA-44 Quantum-safe 4 places See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

  1. certification/oidc/configuration.js:106 alg: 'ML-DSA-44',
  2. test/configuration/client_keystore.test.js:108 test path alg: 'ML-DSA-44',
  3. test/configuration/client_metadata.test.js:1784 test path [[{ kty: 'AKP', alg: 'ML-DSA-44' }], 'jwks.keys[0].pub must be a non-empty string for AKP keys'],
  4. test/configuration/client_metadata.test.js:1785 test path [[{ kty: 'AKP', alg: 'ML-DSA-44', pub: 'pub', priv: 'priv' }], 'jwks.keys[0].priv must not be provided for AKP keys'],
js.jwt.algorithm · CWE-327
ML-DSA-65 Quantum-safe 1 place See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

js.jwt.algorithm · CWE-327
ML-DSA-87 Quantum-safe 1 place See details

JWT signed with a classical algorithm

A JOSE `alg` value. RS*, PS*, ES* and EdDSA sign with a quantum-vulnerable key; HS* is an HMAC and is not affected. `alg: 'none'` is reported as a critical defect today.

No known quantum attack changes how strong this is. No known quantum algorithm changes the security margin.

What to do. No standardised post-quantum JOSE algorithm exists yet. Keep token lifetimes short.

js.jwt.algorithm · CWE-327

Cryptographic assets

Algorithm Assessment What it means Occurrences
HMAC Quantum-safe A keyed MAC is not affected by Shor and only marginally by Grover. 204
ECDSA Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. 148
RSASSA-PKCS1v15 Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. The v1.5 signature scheme of RFC 8017 section 8.2 has no classical break of its own; RSA-PSS is preferred for new work, but the quantum exposure is the same for both. 115
AES-128 Reduced margin Grover's algorithm halves the effective strength; the parameter, not the design, is the problem. 110
Ed25519 Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. 84
RSA-OAEP Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. 81
unknown Could not be determined The algorithm could not be established from the source - chosen at runtime, or decided somewhere this scan does not reach. 70
ECDH Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. 57
RSA-PSS Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. 50
AES-256 Quantum-safe No known quantum algorithm changes the security margin. 45
AES-192 Reduced margin Grover's algorithm halves the effective strength; the parameter, not the design, is the problem. 21
CSPRNG Quantum-safe A cryptographically secure random number generator provided by the platform. Not weakened by a quantum computer. 19
ML-DSA-44 Quantum-safe No known quantum algorithm changes the security margin. 18
ML-DSA-65 Quantum-safe No known quantum algorithm changes the security margin. 10
ML-DSA-87 Quantum-safe No known quantum algorithm changes the security margin. 10
RSA Quantum-vulnerable Broken by Shor's algorithm on a cryptographically relevant quantum computer. 8
SHA-256 Reduced margin Pre-image resistance falls to about 128 bits of quantum work. Adequate for most uses; SHA-384 restores the full margin where a signature must last decades. 3

Imported cryptographic libraries

Library Files
node:crypto the Node crypto module 57