CVE-2020-12607: Fastecdsa Improper Verification Of Cryptographic Signature Vulnerability

HIGH
Advisory Identifier: GHSA-56wv-2wr9-3h9r
CVSS 7.5
CWE-347
Published
Advisory Summary

CVE-2020-12607 is a HIGH (CVSS 7.5) improper verification of cryptographic signature vulnerability (CWE-347: Improper Verification of Cryptographic Signature) affecting Fastecdsa libraries in the PyPI ecosystem. The issue involves improper verification of cryptographic signature in fastecdsa. Remediation is available by upgrading affected packages to version 2.1.2.

CVE-2020-12607 at a Glance

CVE Identifier CVE-2020-12607
GHSA Identifier GHSA-56wv-2wr9-3h9r
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-347: Improper Verification of Cryptographic Signature
Affected Product Fastecdsa
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 7.5

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

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
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-2020-12607

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

fastecdsa fixed: 2.1.2
pip install fastecdsa>=2.1.2
Verify Direct and Transitive Dependencies

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

pip show fastecdsa

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2020-12607, inspect your installed packages using pip:

pip show fastecdsa

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

Note: The pip show fastecdsa command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-347: Improper Verification of Cryptographic Signature, where the product does not verify, or incorrectly verifies, the cryptographic signature for data. In Fastecdsa, 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

An issue was discovered in fastecdsa before 2.1.2. When using the NIST P-256 curve in the ECDSA implementation, the point at infinity is mishandled. This means that for an extreme value in k and s<sup>-1</sup>, the signature verification fails even if the signature is correct. This behavior is not solely a usability problem. There are some threat models where an attacker can benefit by successfully guessing users for whom signature verification will fail.

CVE-2020-12607 Affected Fastecdsa Versions

1 component(s)
Fixed Versions:
2.1.2
Product / Package Ecosystem Affected Versions Fixed Version
fastecdsa
PyPI
< 2.1.2
2.1.2

References

Frequently Asked Questions

What is CVE-2020-12607?
CVE-2020-12607 is a security vulnerability in Fastecdsa involving Improper Verification of Cryptographic Signature in fastecdsa under CWE-347: Improper Verification of Cryptographic Signature.
Which Fastecdsa versions are affected?
Affected versions include releases prior to 2.1.2 across affected packages: fastecdsa.
What version fixes CVE-2020-12607?
Upgrading to 2.1.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is fastecdsa affected?
Yes, fastecdsa is affected in releases prior to 2.1.2. Upgrade your dependency to 2.1.2 or later.
What is the CVSS score of CVE-2020-12607?
CVE-2020-12607 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2020-12607?
CVE-2020-12607 is classified under CWE-347: Improper Verification of Cryptographic Signature (The product does not verify, or incorrectly verifies, the cryptographic signature for data.).
How can I check PyPI dependencies for CVE-2020-12607?
Run the dependency tree command: 'pip show fastecdsa'. 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-56wv-2wr9-3h9r",
  "modified" : "2025-02-12T18:33:20Z",
  "published" : "2021-10-12T16:30:37Z",
  "aliases" : [ "CVE-2020-12607" ],
  "summary" : "Improper Verification of Cryptographic Signature in fastecdsa",
  "details" : "An issue was discovered in fastecdsa before 2.1.2. When using the NIST P-256 curve in the ECDSA implementation, the point at infinity is mishandled. This means that for an extreme value in k and s<sup>-1</sup>, the signature verification fails even if the signature is correct. This behavior is not solely a usability problem. There are some threat models where an attacker can benefit by successfully guessing users for whom signature verification will fail.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "fastecdsa"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.1.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-12607"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/AntonKueltz/fastecdsa/issues/52"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/AntonKueltz/fastecdsa/commit/4a16daeaf139be20654ef58a9fe4c79dc030458c"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/AntonKueltz/fastecdsa/commit/7b64e3efaa806b4daaf73bb5172af3581812f8de"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/AntonKueltz/fastecdsa/commit/e592f106edd5acf6dacedfab2ad16fe6c735c9d1"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/AntonKueltz/fastecdsa"
  }, {
    "type" : "ADVISORY",
    "url" : "https://github.com/advisories/GHSA-56wv-2wr9-3h9r"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/fastecdsa/PYSEC-2020-42.yaml"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-347" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2021-10-08T22:28:23Z",
    "nvd_published_at" : "2020-06-02T21:15:00Z"
  }
}