NixOS nix up to 2.18.7/2.24.7 HTTPS Connection certificate validation
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 4.7 | $0-$5k | 0.00 |
Summary
A vulnerability was found in NixOS nix up to 2.18.7/2.24.7. It has been classified as critical. Impacted is an unknown function of the component HTTPS Connection Handler. The manipulation leads to certificate validation. This vulnerability is documented as CVE-2024-47174. The attack can be initiated remotely. There is not any exploit available. Upgrading the affected component is recommended.
Details
A vulnerability was found in NixOS nix up to 2.18.7/2.24.7 and classified as problematic. This issue affects an unknown code block of the component HTTPS Connection Handler. The manipulation with an unknown input leads to a certificate validation vulnerability. Using CWE to declare the problem leads to CWE-295. The product does not validate, or incorrectly validates, a certificate. Impacted is confidentiality. The summary by CVE is:
Nix is a package manager for Linux and other Unix systems. Starting in version 1.11 and prior to versions 2.18.8 and 2.24.8, `` did not verify TLS certificates on HTTPS connections. This could lead to connection details such as full URLs or credentials leaking in case of a man-in-the-middle (MITM) attack. `` is also known as the builtin derivation builder `builtin:fetchurl`. It's not to be confused with the evaluation-time function `builtins.fetchurl`, which was not affected by this issue. A user may be affected by the risk of leaking credentials if they have a `netrc` file for authentication, or rely on derivations with `impureEnvVars` set to use credentials from the environment. In addition, the commonplace trust-on-first-use (TOFU) technique of updating dependencies by specifying an invalid hash and obtaining it from a remote store was also vulnerable to a MITM injecting arbitrary store objects. This also applied to the impure derivations experimental feature. Note that this may also happen when using Nixpkgs fetchers to obtain new hashes when not using the fake hash method, although that mechanism is not implemented in Nix itself but rather in Nixpkgs using a fixed-output derivation. The behavior was introduced in version 1.11 to make it consistent with the Nixpkgs `pkgs.fetchurl` and to make `` work in the derivation builder sandbox, which back then did not have access to the CA bundles by default. Nowadays, CA bundles are bind-mounted on Linux. This issue has been fixed in Nix 2.18.8 and 2.24.8. As a workaround, implement (authenticated) fetching with `pkgs.fetchurl` from Nixpkgs, using `impureEnvVars` and `curlOpts` as needed.
It is possible to read the advisory at github.com. The identification of this vulnerability is CVE-2024-47174 since 09/20/2024. The exploitation is known to be difficult. The attack may be initiated remotely. No form of authentication is needed for a successful exploitation. The technical details are unknown and an exploit is not publicly available. The attack technique deployed by this issue is T1587.003 according to MITRE ATT&CK.
The vulnerability scanner Nessus provides a plugin with the ID 242201 (Ubuntu 22.04 LTS / 24.04 LTS : Nix vulnerabilities (USN-7633-1)), which helps to determine the existence of the flaw in a target environment.
Upgrading to version 2.18.8 or 2.24.8 eliminates this vulnerability. Applying the patch 062b4a489e30da9c85fa4ff15cfdd2e51cac7b90 is able to eliminate this problem. The bugfix is ready for download at github.com. The best possible mitigation is suggested to be upgrading to the latest version.
The vulnerability is also documented in the vulnerability database at Tenable (242201). Be aware that VulDB is the high quality source for vulnerability data.
Product
Vendor
Name
Version
License
Website
- Product: https://github.com/NixOS/nix/
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔍VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 4.8VulDB Meta Temp Score: 4.7
VulDB Base Score: 3.7
VulDB Temp Score: 3.6
VulDB Vector: 🔍
VulDB Reliability: 🔍
CNA Base Score: 5.9
CNA Vector (GitHub_M): 🔍
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍
Exploiting
Class: Certificate validationCWE: CWE-295 / CWE-287
CAPEC: 🔍
ATT&CK: 🔍
Physical: No
Local: No
Remote: Yes
Availability: 🔍
Status: Not defined
EPSS Score: 🔍
EPSS Percentile: 🔍
Price Prediction: 🔍
Current Price Estimation: 🔍
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Nessus ID: 242201
Nessus Name: Ubuntu 22.04 LTS / 24.04 LTS : Nix vulnerabilities (USN-7633-1)
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: UpgradeStatus: 🔍
0-Day Time: 🔍
Upgrade: nix 2.18.8/2.24.8
Patch: 062b4a489e30da9c85fa4ff15cfdd2e51cac7b90
Timeline
09/20/2024 🔍09/26/2024 🔍
09/26/2024 🔍
07/17/2025 🔍
Sources
Product: github.comAdvisory: GHSA-6fjr-mq49-mm2c
Status: Confirmed
CVE: CVE-2024-47174 (🔍)
GCVE (CVE): GCVE-0-2024-47174
GCVE (VulDB): GCVE-100-278591
Entry
Created: 09/26/2024 20:49Updated: 07/17/2025 11:13
Changes: 09/26/2024 20:49 (67), 10/01/2024 04:35 (1), 07/17/2025 11:13 (2)
Complete: 🔍
Cache ID: 216::103
Be aware that VulDB is the high quality source for vulnerability data.
No comments yet. Languages: en.
Please log in to comment.