CVE-2020-13822: Elliptic Signature Malleabillity Vulnerability
HIGHCVE-2020-13822 is a HIGH (CVSS 7.7) signature malleabillity vulnerability (CWE-190: Integer Overflow or Wraparound) affecting Elliptic libraries in the npm ecosystem. The issue involves signature malleabillity in elliptic. Remediation is available by upgrading affected packages to version 6.5.3.
CVE-2020-13822 at a Glance
Security Impact
CVSS: 7.7
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:L).
How to Fix CVE-2020-13822
To remediate this vulnerability, upgrade all affected Elliptic dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install elliptic@6.5.3
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls elliptic
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2020-13822, inspect your project dependencies using npm:
npm ls elliptic
Analyze the terminal output to locate any version of Elliptic in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 6.5.3), your application is affected.
Note: The npm ls elliptic 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-190: Integer Overflow or Wraparound, where the product performs a calculation that can produce an integer overflow or wraparound when the logic assumes that the resulting value will always be larger than the original value. this occurs when an integer value is incremented to a value that is too large to store in the associated representation. when this occurs, the value may become a very small or negative number. In Elliptic, 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
CVE-2020-13822 Affected Elliptic Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
elliptic
|
npm |
< 6.5.3
|
6.5.3
|
References
Frequently Asked Questions
What is CVE-2020-13822?
Which Elliptic versions are affected?
What version fixes CVE-2020-13822?
Is elliptic affected?
What is the CVSS score of CVE-2020-13822?
What CWE is associated with CVE-2020-13822?
How can I check npm dependencies for CVE-2020-13822?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-vh7m-p724-62c2",
"modified" : "2024-10-16T17:02:45Z",
"published" : "2020-07-29T20:40:35Z",
"aliases" : [ "CVE-2020-13822" ],
"summary" : "Signature Malleabillity in elliptic",
"details" : "The Elliptic package before version 6.5.3 for Node.js allows ECDSA signature malleability via variations in encoding, leading '\\0' bytes, or integer overflows. This could conceivably have a security-relevant impact if an application relied on a single canonical signature.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:L"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "elliptic"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "6.5.3"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-13822"
}, {
"type" : "WEB",
"url" : "https://github.com/indutny/elliptic/issues/226"
}, {
"type" : "WEB",
"url" : "https://github.com/indutny/elliptic/commit/856fe4d99fe7b6200556e6400b3bf585b1721bec"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/indutny/elliptic"
}, {
"type" : "WEB",
"url" : "https://medium.com/%40herman_10687/malleability-attack-why-it-matters-7b5f59fb99a4"
}, {
"type" : "WEB",
"url" : "https://medium.com/@herman_10687/malleability-attack-why-it-matters-7b5f59fb99a4"
}, {
"type" : "WEB",
"url" : "https://www.npmjs.com/package/elliptic"
}, {
"type" : "WEB",
"url" : "https://yondon.blog/2019/01/01/how-not-to-use-ecdsa"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-190" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2020-07-29T20:39:31Z",
"nvd_published_at" : "2020-06-04T15:15:13Z"
}
}