Skip to content
Heist/ feed
Back to feed
Low

nix — security advisory

Type: advisorySources: OSVAdvisory ID: UBUNTU-CVE-2026-64846

Nix is a package manager for Linux and other Unix systems. Prior to 2.35.0, a malicious derivation executed with the recursive-nix experimental feature can exploit a time-of-check/time-of-use race involving final symlink handling in the LocalStore restore path. The race can cause writeFile to follow a substituted final symlink when opening a path with O_TRUNC instead of enforcing FinalSymlink::DontFollow, allowing the Nix process or nix-daemon to create or truncate an empty file outside the build sandbox with the daemon user's permissions. The primitive does not provide arbitrary-content writes and requires winning the race. This issue is fixed in version 2.35.0.

Products
nix
Affected versions
2.16.1+dfsg-3ubuntu1, 2.18.1+dfsg-1ubuntu1, 2.18.1+dfsg-1ubuntu2, 2.18.1+dfsg-1ubuntu4, 2.18.1+dfsg-1ubuntu5, 2.18.1+dfsg-1ubuntu5+esm2, 2.26.3+dfsg-1ubuntu4, 2.26.3+dfsg-1ubuntu5, 2.3.10+dfsg1-1, 2.3.10+dfsg1-1build1, 2.32.5+dfsg-1ubuntu3, 2.32.5+dfsg-2ubuntu1, 2.34.3+dfsg-1, 2.34.6+dfsg-1, 2.34.6+dfsg-1build1, 2.34.8+dfsg-1, 2.34.8+dfsg-1build1, 2.6.0+dfsg-2, 2.6.0+dfsg-3, 2.6.0+dfsg-3ubuntu0.1~esm1
Fixed versions
Not specified
CVEs
CVE-2026-64846
Confirmed fixed CVEs
Not specified
Updated in this feed
31 Oct 2026, 03:12 UTC · Revision 1

Source evidence

UBUNTU-CVE-2026-64846

core-osv · Original source

Published 20 Aug 2026, 17:19 UTC

Nix is a package manager for Linux and other Unix systems. Prior to 2.35.0, a malicious derivation executed with the recursive-nix experimental feature can exploit a time-of-check/time-of-use race involving final symlink handling in the LocalStore restore path. The race can cause writeFile to follow a substituted final symlink when opening a path with O_TRUNC instead of enforcing FinalSymlink::DontFollow, allowing the Nix process or nix-daemon to create or truncate an empty file outside the build sandbox with the daemon user's permissions. The primitive does not provide arbitrary-content writes and requires winning the race. This issue is fixed in version 2.35.0.

osv:UBUNTU-CVE-2026-64846

nix

Fixed versions: Not specified

nix

Fixed versions: Not specified

nix

Fixed versions: Not specified

nix

Fixed versions: Not specified

Complete source record
{
  "id": "3c3944f88eb36dc8561e7fda649a8cec07da185095100766564399e6e373a86a",
  "url": "https://osv.dev/vulnerability/UBUNTU-CVE-2026-64846",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "UBUNTU-CVE-2026-64846",
    "summary": "Nix is a package manager for Linux and other Unix systems. Prior to 2.35.0, a malicious derivation executed with the recursive-nix experimental feature can exploit a time-of-check/time-of-use race involving final symlink handling in the LocalStore restore path. The race can cause writeFile to follow a substituted final symlink when opening a path with O_TRUNC instead of enforcing FinalSymlink::DontFollow, allowing the Nix process or nix-daemon to create or truncate an empty file outside the build sandbox with the daemon user's permissions. The primitive does not provide arbitrary-content writes and requires winning the race. This issue is fixed in version 2.35.0.",
    "evidence": "osv:UBUNTU-CVE-2026-64846",
    "products": [
      {
        "name": {
          "value": "nix",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.3.10+dfsg1-1",
            "evidence": "/affected/0/versions"
          },
          {
            "value": "2.3.10+dfsg1-1build1",
            "evidence": "/affected/0/versions"
          },
          {
            "value": "2.6.0+dfsg-2",
            "evidence": "/affected/0/versions"
          },
          {
            "value": "2.6.0+dfsg-3",
            "evidence": "/affected/0/versions"
          },
          {
            "value": "2.6.0+dfsg-3ubuntu0.1~esm1",
            "evidence": "/affected/0/versions"
          }
        ]
      },
      {
        "name": {
          "value": "nix",
          "evidence": "/affected/1/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.16.1+dfsg-3ubuntu1",
            "evidence": "/affected/1/versions"
          },
          {
            "value": "2.18.1+dfsg-1ubuntu1",
            "evidence": "/affected/1/versions"
          },
          {
            "value": "2.18.1+dfsg-1ubuntu2",
            "evidence": "/affected/1/versions"
          },
          {
            "value": "2.18.1+dfsg-1ubuntu4",
            "evidence": "/affected/1/versions"
          },
          {
            "value": "2.18.1+dfsg-1ubuntu5",
            "evidence": "/affected/1/versions"
          },
          {
            "value": "2.18.1+dfsg-1ubuntu5+esm2",
            "evidence": "/affected/1/versions"
          }
        ]
      },
      {
        "name": {
          "value": "nix",
          "evidence": "/affected/2/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.34.3+dfsg-1",
            "evidence": "/affected/2/versions"
          },
          {
            "value": "2.34.6+dfsg-1",
            "evidence": "/affected/2/versions"
          },
          {
            "value": "2.34.6+dfsg-1build1",
            "evidence": "/affected/2/versions"
          },
          {
            "value": "2.34.8+dfsg-1",
            "evidence": "/affected/2/versions"
          },
          {
            "value": "2.34.8+dfsg-1build1",
            "evidence": "/affected/2/versions"
          }
        ]
      },
      {
        "name": {
          "value": "nix",
          "evidence": "/affected/3/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [],
        "affected_versions": [
          {
            "value": "2.26.3+dfsg-1ubuntu4",
            "evidence": "/affected/3/versions"
          },
          {
            "value": "2.26.3+dfsg-1ubuntu5",
            "evidence": "/affected/3/versions"
          },
          {
            "value": "2.32.5+dfsg-1ubuntu3",
            "evidence": "/affected/3/versions"
          },
          {
            "value": "2.32.5+dfsg-2ubuntu1",
            "evidence": "/affected/3/versions"
          },
          {
            "value": "2.34.3+dfsg-1",
            "evidence": "/affected/3/versions"
          }
        ]
      }
    ],
    "severity": "low",
    "structured": {
      "id": "UBUNTU-CVE-2026-64846",
      "aliases": [
        "UBUNTU-CVE-2026-64846"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:C/C:N/I:L/A:N"
        },
        {
          "type": "Ubuntu",
          "score": "medium"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "nix",
            "purl": "pkg:deb/ubuntu/nix?arch=source&distro=esm-apps%2Fjammy",
            "ecosystem": "Ubuntu:Pro:22.04:LTS"
          },
          "versions": [
            "2.3.10+dfsg1-1",
            "2.3.10+dfsg1-1build1",
            "2.6.0+dfsg-2",
            "2.6.0+dfsg-3",
            "2.6.0+dfsg-3ubuntu0.1~esm1"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-64846.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "nix-bin",
                "binary_version": "2.6.0+dfsg-3ubuntu0.1~esm1"
              },
              {
                "binary_name": "nix-setup-systemd",
                "binary_version": "2.6.0+dfsg-3ubuntu0.1~esm1"
              }
            ]
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "nix",
            "purl": "pkg:deb/ubuntu/nix?arch=source&distro=esm-apps%2Fnoble",
            "ecosystem": "Ubuntu:Pro:24.04:LTS"
          },
          "versions": [
            "2.16.1+dfsg-3ubuntu1",
            "2.18.1+dfsg-1ubuntu1",
            "2.18.1+dfsg-1ubuntu2",
            "2.18.1+dfsg-1ubuntu4",
            "2.18.1+dfsg-1ubuntu5",
            "2.18.1+dfsg-1ubuntu5+esm2"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-64846.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "nix-bin",
                "binary_version": "2.18.1+dfsg-1ubuntu5+esm2"
              },
              {
                "binary_name": "nix-setup-systemd",
                "binary_version": "2.18.1+dfsg-1ubuntu5+esm2"
              }
            ]
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "nix",
            "purl": "pkg:deb/ubuntu/nix?arch=source&distro=stonking",
            "ecosystem": "Ubuntu:26.10"
          },
          "versions": [
            "2.34.3+dfsg-1",
            "2.34.6+dfsg-1",
            "2.34.6+dfsg-1build1",
            "2.34.8+dfsg-1",
            "2.34.8+dfsg-1build1"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-64846.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "nix-bin",
                "binary_version": "2.34.8+dfsg-1build1"
              },
              {
                "binary_name": "nix-setup-systemd",
                "binary_version": "2.34.8+dfsg-1build1"
              }
            ]
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                }
              ]
            }
          ],
          "package": {
            "name": "nix",
            "purl": "pkg:deb/ubuntu/nix?arch=source&distro=resolute",
            "ecosystem": "Ubuntu:26.04:LTS"
          },
          "versions": [
            "2.26.3+dfsg-1ubuntu4",
            "2.26.3+dfsg-1ubuntu5",
            "2.32.5+dfsg-1ubuntu3",
            "2.32.5+dfsg-2ubuntu1",
            "2.34.3+dfsg-1"
          ],
          "database_specific": {
            "source": "https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2026/UBUNTU-CVE-2026-64846.json"
          },
          "ecosystem_specific": {
            "binaries": [
              {
                "binary_name": "nix-bin",
                "binary_version": "2.34.3+dfsg-1"
              },
              {
                "binary_name": "nix-setup-systemd",
                "binary_version": "2.34.3+dfsg-1"
              }
            ]
          }
        }
      ],
      "modified": "2026-10-17T13:00:33.970395948Z",
      "provider": "osv",
      "upstream": [
        "CVE-2026-64846"
      ],
      "references": [
        "https://ubuntu.com/security/CVE-2026-64846",
        "https://www.cve.org/CVERecord?id=CVE-2026-64846"
      ]
    },
    "related_cves": [
      {
        "value": "CVE-2026-64846",
        "evidence": "/upstream"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 360697,
  "published_at": "2026-08-20T17:19:00+00:00"
}