The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-39860

CVE-2026-39860: Nix Package Manager Privilege Escalation

CVE-2026-39860 is a privilege escalation vulnerability in Nix package manager affecting sandboxed Linux builds. Attackers can gain root access by exploiting symlink handling during output registration.

Published: April 10, 2026

CVE-2026-39860 Overview

A critical symlink attack vulnerability exists in the Nix package manager for Linux systems that allows local users to escalate privileges to root. This flaw is a bypass of the previous fix for CVE-2024-27297, enabling arbitrary file overwrites through symlink following during fixed-output derivation output registration. The vulnerability specifically affects sandboxed Linux builds while macOS builds remain unaffected.

Critical Impact

Local privilege escalation to root in multi-user Nix installations, allowing any user with build submission rights to gain complete system control by overwriting sensitive system files.

Affected Products

  • Nix Package Manager versions prior to 2.34.5
  • Nix Package Manager versions prior to 2.33.4
  • Nix Package Manager versions prior to 2.32.7
  • Nix Package Manager versions prior to 2.31.4
  • Nix Package Manager versions prior to 2.30.4
  • Nix Package Manager versions prior to 2.29.3
  • Nix Package Manager versions prior to 2.28.6

Discovery Timeline

  • April 8, 2026 - CVE-2026-39860 published to NVD
  • April 8, 2026 - Last updated in NVD database

Technical Details for CVE-2026-39860

Vulnerability Analysis

This vulnerability represents a UNIX Symbolic Link (Symlink) Following flaw (CWE-61) that occurs during the output registration phase of fixed-output derivations in the Nix package manager. The core issue stems from an incomplete fix for the previous CVE-2024-27297 vulnerability.

In multi-user Nix installations, the Nix daemon typically runs as root and orchestrates builds within isolated chroot environments. The vulnerability arises because the temporary output location used during the output copy operation is positioned inside the build chroot. A malicious derivation builder can craft a symlink at this temporary path pointing to any arbitrary location in the host filesystem. When the Nix daemon process—executing in the host mount namespace—performs the output registration, it follows this symlink and overwrites the target destination with the derivation's output contents.

The attack surface encompasses all users configured in the allowed-users setting, which defaults to all users on the system. This creates a significant privilege escalation vector where unprivileged users can modify critical system files such as /etc/passwd, /etc/shadow, or system binaries.

Root Cause

The root cause lies in the failure to properly isolate file operations during the output registration phase. The Nix process running with root privileges in the host namespace trusts paths within the build chroot without verifying whether they are symlinks pointing outside the sandbox boundary. The original fix for CVE-2024-27297 did not adequately address the scenario where the temporary output path itself could be replaced with a malicious symlink before the copy operation completes.

Attack Vector

The attack requires local access to a system running a multi-user Nix installation. An attacker creates a malicious derivation that:

  1. Places a symlink at the expected temporary output location within the build chroot
  2. Points the symlink to a sensitive file on the host filesystem (e.g., /etc/passwd)
  3. When the Nix daemon registers the output, it follows the symlink and overwrites the target file with attacker-controlled content

This results in arbitrary file overwrite with root privileges, enabling complete system compromise.

The security patch addresses this by copying the output to a fresh temporary file before registration, ensuring no symlinks can be followed:

text
             [&](const DerivationOutput::CAFixed & dof) {
                 auto & wanted = dof.ca.hash;
 
+                // Replace the output by a fresh copy of itself to make sure
+                // that there's no stale file descriptor pointing to it
+                Path tmpOutput = actualPath + ".tmp";
+                copyFile(actualPath, tmpOutput, true);
+                renameFile(tmpOutput, actualPath);
+
                 auto newInfo0 = newInfoFromCA(DerivationOutput::CAFloating {
                     .method = dof.ca.method,
                     .hashAlgo = wanted.algo,

Source: GitHub NixOS Commit 244f3ee

The fix also introduces a new copyFile function to safely handle the copy operation:

text
     }
 }
 
+void copyFile(const Path & oldPath, const Path & newPath, bool andDelete)
+{
+    return copy(fs::directory_entry(fs::path(oldPath)), fs::path(newPath), andDelete);
+}
+
 void renameFile(const Path & oldName, const Path & newName)
 {
     fs::rename(oldName, newName);

Source: GitHub NixOS Commit 244f3ee

Detection Methods for CVE-2026-39860

Indicators of Compromise

  • Unexpected symlinks appearing in Nix store temporary directories pointing to sensitive system files
  • Unauthorized modifications to critical files such as /etc/passwd, /etc/shadow, or system binaries
  • Suspicious build submissions from non-administrative users targeting fixed-output derivations
  • Anomalous file descriptor activity during Nix daemon build operations

Detection Strategies

  • Monitor the Nix daemon process for file operations that traverse outside expected store paths
  • Implement file integrity monitoring (FIM) on critical system files to detect unauthorized modifications
  • Audit derivation build logs for unusual patterns or repeated failed builds that may indicate exploitation attempts
  • Deploy endpoint detection rules to identify symlink creation within build chroot environments

Monitoring Recommendations

  • Enable verbose logging for the Nix daemon to capture detailed build operation traces
  • Configure alerts for any root-level file modifications initiated by the Nix daemon process
  • Monitor allowed-users configuration changes and restrict build submission rights to trusted users only
  • Implement baseline monitoring for Nix store directory structures to detect anomalous symlinks

How to Mitigate CVE-2026-39860

Immediate Actions Required

  • Upgrade Nix to patched versions: 2.34.5, 2.33.4, 2.32.7, 2.31.4, 2.30.4, 2.29.3, or 2.28.6
  • Review and restrict the allowed-users configuration to minimize users permitted to submit builds
  • Audit existing derivations and build configurations for potentially malicious content
  • Consider temporarily disabling multi-user mode if immediate patching is not possible

Patch Information

NixOS has released security patches across multiple version branches. The fix ensures that fixed-output derivation outputs are copied to a fresh temporary location before registration, preventing symlink following attacks. Detailed commit information is available in the GitHub NixOS Security Advisory GHSA-g3g9-5vj6-r3gj.

Additional technical details can be found in GitHub NixOS Pull Request 10178.

Workarounds

  • Restrict allowed-users in /etc/nix/nix.conf to explicitly trusted accounts only
  • Disable untrusted builds by configuring require-sigs = true and limiting access to signing keys
  • Run Nix in single-user mode where multi-user functionality is not required
  • Implement network segmentation to limit access to systems running vulnerable Nix installations
bash
# Configuration example - Restrict allowed users in /etc/nix/nix.conf
# Only allow specific trusted users to submit builds
allowed-users = trusted-admin build-operator

# Require signatures for all store paths
require-sigs = true

# Limit builders to trusted sources
trusted-users = root trusted-admin

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechNix

  • SeverityCRITICAL

  • CVSS Score9.0

  • EPSS Probability0.02%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:N
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityNone
  • CWE References
  • CWE-61
  • Technical References
  • GitHub NixOS Commit 244f3ee

  • GitHub NixOS Commit 4bc5a35

  • GitHub NixOS Commit 7794354

  • GitHub NixOS Commit a3163b9

  • GitHub NixOS Pull Request 10178

  • GitHub NixOS Security Advisory GHSA-g3g9-5vj6-r3gj
  • Related CVEs
  • CVE-2026-44029: Nix Path Traversal Vulnerability

  • CVE-2026-44028: Nix and Lix NAR Parser RCE Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English