CVE-2017-16007: Node jose Invalid Curve Attack Vulnerability

MODERATE
Advisory Identifier: GHSA-rvj9-8cvx-3vq9
CVSS 5.9
CWE-200
Published
Advisory Summary

CVE-2017-16007 is a MODERATE (CVSS 5.9) invalid curve attack vulnerability (CWE-200: Exposure of Sensitive Information to an Unauthorized Actor) affecting Node jose libraries in the npm ecosystem. The issue involves invalid curve attack in node-jose. Remediation is available by upgrading affected packages to version 0.9.3.

CVE-2017-16007 at a Glance

CVE Identifier CVE-2017-16007
GHSA Identifier GHSA-rvj9-8cvx-3vq9
Severity MODERATE
CVSS v3.1 Base Score 5.9
CWE Classification CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
Affected Product Node jose
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 5.9

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2017-16007

To remediate this vulnerability, upgrade all affected Node jose dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

node-jose fixed: 0.9.3
npm install node-jose@0.9.3
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls node-jose

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2017-16007, inspect your project dependencies using npm:

npm ls node-jose

Analyze the terminal output to locate any version of Node jose in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.9.3), your application is affected.

Note: The npm ls node-jose command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor, where the product exposes sensitive information to an actor that is not explicitly authorized to have access to that information. In Node jose, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Affected versions of `node-jose` are vulnerable to an invalid curve attack. This allows an attacker to recover the private secret key when JWE with Key Agreement with Elliptic Curve Diffie-Hellman Ephemeral Static (ECDH-ES) is used. [Proof of Concept](https://gist.github.com/asanso/fa25685348051ef6a28d49aa0f27a4ae) ## Recommendation Update to version 0.9.3 or later.

CVE-2017-16007 Affected Node jose Versions

1 component(s)
Fixed Versions:
0.9.3
Product / Package Ecosystem Affected Versions Fixed Version
node-jose
npm
< 0.9.3
0.9.3

References

Frequently Asked Questions

What is CVE-2017-16007?
CVE-2017-16007 is a security vulnerability in Node jose involving Invalid Curve Attack in node-jose under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor.
Which Node jose versions are affected?
Affected versions include releases prior to 0.9.3 across affected packages: node-jose.
What version fixes CVE-2017-16007?
Upgrading to 0.9.3 (or the latest patched release for your respective branch) resolves the vulnerability.
Is node-jose affected?
Yes, node-jose is affected in releases prior to 0.9.3. Upgrade your dependency to 0.9.3 or later.
What is the CVSS score of CVE-2017-16007?
CVE-2017-16007 has a CVSS v3.1 base score of 5.9 (MODERATE) with vector string CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2017-16007?
CVE-2017-16007 is classified under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor (The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.).
How can I check npm dependencies for CVE-2017-16007?
Run the dependency tree command: 'npm ls node-jose'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-rvj9-8cvx-3vq9",
  "modified" : "2023-09-06T23:38:57Z",
  "published" : "2018-07-20T21:10:14Z",
  "aliases" : [ "CVE-2017-16007" ],
  "summary" : "Invalid Curve Attack in node-jose",
  "details" : "Affected versions of `node-jose` are vulnerable to an invalid curve attack. This allows an attacker to recover the private secret key when JWE with Key Agreement with Elliptic Curve Diffie-Hellman Ephemeral Static (ECDH-ES) is used.\n\n[Proof of Concept](https://gist.github.com/asanso/fa25685348051ef6a28d49aa0f27a4ae)\n\n\n## Recommendation\n\nUpdate to version 0.9.3 or later.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "node-jose"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.9.3"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2017-16007"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/cisco/node-jose/pull/88"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/cisco/node-jose/commit/f92cffb4a0398b4b1158be98423369233282e0af"
  }, {
    "type" : "WEB",
    "url" : "https://gist.github.com/asanso/fa25685348051ef6a28d49aa0f27a4ae"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/cisco/node-jose"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/cisco/node-jose/compare/0.9.2...0.9.3"
  }, {
    "type" : "WEB",
    "url" : "http://blog.intothesymmetry.com/2017/03/critical-vulnerability-in-json-web.html"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-200" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-06-16T21:56:00Z",
    "nvd_published_at" : null
  }
}