# CVE-2020-28498: Elliptic weak ECDH key validation in secp256k1

Source: https://junglewise.ai/threats/cve-2020-28498-elliptic-weak-ecdh-key-validation-in-secp256k1  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2021-03-08. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2020-28498 · Severity: low · CVSS 3.1 · Published 2021-03-08

Elliptic is a widely-used JavaScript cryptography library providing elliptic curve operations for secure communications. The library's ECDH (key exchange) implementation fails to validate that a peer's public key lies on the intended cryptographic curve, allowing an attacker to perform twist attacks that gradually leak the victim's private key through repeated key exchange operations.

Technologies: [elliptic (npm)](https://junglewise.ai/threats/technologies/elliptic). Vendors: [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is CVE-2020-28498 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2020-28498 being exploited in the wild.

**How severe is CVE-2020-28498?** Low severity, with a CVSS score of 3.1, published 8 March 2021.

**Which products and versions are affected?** elliptic (npm) SEMVER:introduced=0,fixed=6.5.4.

**Is there a fix for CVE-2020-28498?** Yes. elliptic (npm): upgrade to 6.5.4 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2020-28498 attacked?** It is attacked over the network.

**Am I affected by CVE-2020-28498?** Check whether you run elliptic (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- elliptic (npm): upgrade to 6.5.4 or later

  ```sh
  npm install elliptic@6.5.4
  ```


## Technical details

The vulnerability is a cryptographic validation weakness (CWE-327) in the secp256k1 curve implementation within elliptic/ec/key.js. The derive() function does not verify that an incoming public key point actually exists on the secp256k1 curve before using it in ECDH operations. An unauthenticated attacker with network access to a service using the library can supply specially-crafted public keys from the curve's twist to extract bits of the private key across multiple key exchanges. A patch was released in version 6.5.4.

## Affected products

- Elliptic elliptic before 6.5.4

## Identifiers

- CVE-2020-28498
- GHSA-r9p9-mrjm-926w

## Timeline

- 2021-03-08: disclosed: GHSA advisory published
- 2021-02-02: advisory: CVE-2020-28498 published on NVD
- 2020-2021: patched: Fixed in version 6.5.4

## References

- [https://github.com/indutny/elliptic/pull/244/commits](https://github.com/indutny/elliptic/pull/244/commits)

## Related threats

- [Elliptic ECDSA signature generation implementation flaw](https://junglewise.ai/threats/cve-2025-14505-elliptic-ecdsa-signature-generation-implementation-flaw)
- [Elliptic ECDSA private key extraction via malformed input](https://junglewise.ai/threats/elliptic-ecdsa-private-key-extraction-via-malformed-input-286138fe)
- [Elliptic ECDSA signature verification bypass with leading zero bytes](https://junglewise.ai/threats/cve-2024-48948-elliptic-ecdsa-signature-verification-bypass-with-leading-zero)
- [Elliptic EdDSA signature malleability via missing validation](https://junglewise.ai/threats/cve-2024-48949-elliptic-eddsa-signature-malleability-via-missing-validation)
- [Elliptic signature malleability in EDDSA and ECDSA](https://junglewise.ai/threats/cve-2024-42459-elliptic-signature-malleability-in-eddsa-and-ecdsa)
