# CVE-2021-21374: Nimble fails to validate certificates due to insecure httpClient defaults

- Severity: High 8.1 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:H/A:L`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.04%, higher than 64% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2021-03-26T21:25:14.000Z
- Modified: 2026-06-17T03:35:25.067Z
- Weaknesses: CWE-295, CWE-348, CWE-349, CWE-599
- Assigned by: GitHub_M

## Description

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.

(As written by CVE List.)

## Affected

- nim-lang security: < 1.2.10; >= 1.4.0, < 1.4.4
- nim-lang nim: before 1.2.10; from 1.4.0 before 1.4.4

## Every score

- GitHub_M: CVSS:3.1 8.1 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:H/A:L`
- NVD: CVSS:3.1 8.1 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 6.8 Medium `AV:N/AC:M/Au:N/C:P/I:P/A:P`

## References

- <https://consensys.net/diligence/vulnerabilities/nim-insecure-ssl-tls-defaults-remote-code-execution/> (exploit, third-party-advisory)
- <https://github.com/nim-lang/nimble/blob/master/changelog.markdown#0130> (release-notes, third-party-advisory)
- <https://github.com/nim-lang/security/security/advisories/GHSA-c2wm-v66h-xhxx> (third-party-advisory)
- <https://github.com/nim-lang/Nim/pull/16940> (patch, third-party-advisory)

## Sources

- CVE List: [CVE-2021-21374](https://www.cve.org/CVERecord?id=CVE-2021-21374), CVE Terms of Use, modified 2024-08-03
- NVD: [CVE-2021-21374](https://nvd.nist.gov/vuln/detail/CVE-2021-21374), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-21374 · Whole record: https://cve.day/CVE-2021-21374.json · Rebuilt by cve.day 2026-11-25T22:58:00.473Z
