Skip to content
Fencer Vulns
high 8.1

CVE-2021-21374 json

Nimble fails to validate certificates due to insecure httpClient defaults

published 2021-03-26 5 y ago modified 2026-06-17 4 mo ago also EUVD-2021-8684

cvss
8.1
version 3.1, CNA
cisa kev
Not listed
not in CISA's catalog
epss
1.0%
EPSS 1.0% chance of exploitation in 30 days, percentile 64%
public exploits
0
none known

Summary

Nimble is a package manager for the Nim programming language. In Nim release versions before versions 1.2.10 and 1.4.4, "nimble refresh" fetches a list of Nimble packages over HTTPS without full verification of the SSL/TLS certificate due to the default setting of httpClient. An attacker able to perform MitM can deliver a modified package list containing malicious software packages. If the packages are installed and used the attack escalates to untrusted code execution.

Patch / fix

  • nim-lang nim 1.2.10, 1.4.4
  • nim Debian 14, Debian 12 1.4.6+really1.4.2-1

debian advisories DEBIAN-CVE-2021-21374

  • nim openSUSE Tumbleweed 1.2.12-1.7
  • nim Package Hub 15 SP4, openSUSE Leap 15.4 1.6.6-bp154.2.3.1
  • nim Package Hub 15 SP3, openSUSE Leap 15.3 1.6.6-bp153.2.3.1
  • nim Package Hub 15 SP2 1.2.12-bp152.4.3.1
  • nim openSUSE Leap 15.2 1.2.12-lp152.2.3.1

opensuse advisories openSUSE-SU-2024:11093-1openSUSE-SU-2022:10101-1openSUSE-SU-2022:10095-1openSUSE-SU-2021:0628-1openSUSE-SU-2021:0618-1

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2021-21374 updated cvss 8.1

nim: Improper verification of the SSL/TLS certificate

  • Red Hat All currently supported Red Hat products
    not affected: vulnerable code not present

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Exploit prediction

1.04% chance of exploitation in the next 30 days, higher than 64% of all scored CVEs (FIRST EPSS, 2026-11-08).

Exploits and checks

  • consensys.net https://consensys.net/diligence/vulnerabilities/nim-insecure-ssl-tls-defaults-remote-code-execution/ referenced PoC, tagged "exploit" by a source, unverified

CVSS scores

assigned by version score vector
CNA 3.1 8.1 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:H/A:L
NVD 3.1 8.1 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
NVD 2.0 6.8 AV:N/AC:M/Au:N/C:P/I:P/A:P

Affected products

  • nim-lang security

Classification

Weakness
  • CWE-348 Use of Less Trusted Source
  • CWE-599 Missing Validation of OpenSSL Certificate
  • CWE-349 Acceptance of Extraneous Untrusted Data With Trusted Data
  • CWE-295 Improper Certificate Validation

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.