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
    • 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-2021-35937

CVE-2021-35937: RPM Privilege Escalation Vulnerability

CVE-2021-35937 is a race condition privilege escalation flaw in RPM that allows local unprivileged users to gain root privileges. This article covers the technical details, affected versions, impact, and mitigation.

Published: February 25, 2026

CVE-2021-35937 Overview

A race condition vulnerability was discovered in RPM (Red Hat Package Manager), the widely-used package management system for Linux distributions. This flaw allows a local unprivileged user to exploit a Time-of-Check Time-of-Use (TOCTOU) race condition to bypass security checks that were previously implemented to address CVE-2017-7500 and CVE-2017-7501, potentially leading to root privilege escalation.

Critical Impact

Local attackers can exploit this race condition to gain root privileges, compromising data confidentiality, integrity, and system availability on affected Linux systems.

Affected Products

  • RPM Package Manager (all vulnerable versions prior to 4.18.0)
  • Red Hat Enterprise Linux 6.0, 7.0, 8.0, and 9.0
  • Fedora 34

Discovery Timeline

  • 2022-08-25 - CVE-2021-35937 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2021-35937

Vulnerability Analysis

This vulnerability represents a classic Time-of-Check Time-of-Use (TOCTOU) race condition (CWE-367) combined with improper link resolution (CWE-59). The flaw exists in how RPM handles file operations during package installation, where a window of opportunity exists between when a file path is verified and when it is actually used.

The vulnerability bypasses security mitigations that were previously introduced to address similar symlink-based attacks (CVE-2017-7500 and CVE-2017-7501). An attacker with local access can manipulate filesystem objects during the race window to redirect file operations to privileged locations, ultimately achieving arbitrary file writes with root privileges.

The attack requires local access and high privileges to initiate, but the complexity lies in successfully winning the race condition. When successfully exploited, an attacker can achieve complete system compromise including arbitrary code execution as root.

Root Cause

The root cause stems from improper handling of symbolic links and hard links during RPM package installation operations. RPM performs security checks on file paths before writing package contents, but a timing gap exists between the check and the actual file operation. During this window, an attacker can substitute a legitimate path with a symbolic link pointing to a privileged system location, bypassing the initial security validation.

This represents both a symlink following vulnerability (CWE-59) and a TOCTOU race condition (CWE-367), where the security properties of a resource change between verification and use.

Attack Vector

The attack requires local access to the target system. An attacker must:

  1. Identify an RPM installation or upgrade operation in progress
  2. Monitor the filesystem for the timing window between security checks and file writes
  3. Create a symbolic link during this window that redirects the file write to a privileged location
  4. Successfully win the race condition to have their symlink processed instead of the legitimate target

Due to the local attack vector and the need to precisely time the race condition, exploitation requires persistence and multiple attempts. However, successful exploitation results in root privilege escalation with full impact to confidentiality, integrity, and availability.

For detailed technical analysis of race condition exploitation techniques in package managers, refer to the USENIX Security Paper on related attack methodologies.

Detection Methods for CVE-2021-35937

Indicators of Compromise

  • Unexpected symbolic links created in /var/lib/rpm/ or package staging directories during installation
  • Rapid file creation and deletion patterns during RPM operations indicating race condition attempts
  • Unexpected file modifications in privileged directories coinciding with package installation timestamps
  • Process tracing showing suspicious timing between stat() and open() syscalls on package files

Detection Strategies

  • Monitor for anomalous symlink creation activity during package management operations using filesystem auditing
  • Deploy behavioral detection rules that flag rapid filesystem object manipulation during rpm process execution
  • Implement auditd rules to track symlink creation in RPM working directories
  • Use inotify-based monitoring to detect suspicious filesystem changes during package operations

Monitoring Recommendations

  • Enable detailed filesystem auditing for /var/lib/rpm/ and temporary package directories
  • Configure audit rules to log all symlink and hardlink creation events: auditctl -w /var/lib/rpm/ -p wa -k rpm_race
  • Monitor for privilege escalation indicators following any RPM package operations
  • Review system logs for failed RPM operations that may indicate exploitation attempts

How to Mitigate CVE-2021-35937

Immediate Actions Required

  • Update RPM to version 4.18.0 or later which contains the fix for this vulnerability
  • Apply vendor-specific patches from Red Hat, Fedora, or your Linux distribution
  • Restrict local user access on critical systems to minimize attack surface
  • Monitor systems for exploitation attempts while patches are being deployed

Patch Information

The vulnerability has been addressed in RPM version 4.18.0. Vendors have released patches through their respective security advisory channels:

  • Red Hat CVE Advisory - Official Red Hat security information and patch availability
  • Red Hat Bug Report - Detailed bug tracking and patch status
  • RPM 4.18.0 Release Notes - Upstream fix information
  • Gentoo GLSA 2022-22 - Gentoo Linux security advisory

Apply updates through your distribution's package manager to receive the patched version of RPM.

Workarounds

  • Limit local user access to systems where RPM operations are performed regularly
  • Implement mandatory access control (SELinux/AppArmor) policies to restrict symlink operations during package installation
  • Consider running RPM operations in isolated environments or containers where possible
  • Temporarily restrict package installation to maintenance windows with reduced local user activity
bash
# Enable SELinux protection for RPM operations
setsebool -P rpm_enable_homedirs off

# Add audit rules to monitor for exploitation attempts
auditctl -w /var/lib/rpm/ -p wa -k rpm_symlink_race
auditctl -a always,exit -F arch=b64 -S symlink -S symlinkat -k symlink_creation

# Verify RPM version after patching
rpm --version

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

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechRpm

  • SeverityMEDIUM

  • CVSS Score6.4

  • EPSS Probability0.01%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityHigh
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-59

  • CWE-367
  • Technical References
  • RPM Release Information

  • Gentoo GLSA Advisory 2022-22

  • USENIX Security Paper
  • Vendor Resources
  • Red Hat CVE Advisory

  • Red Hat Bug Report
  • Related CVEs
  • CVE-2021-35938: Rpm Package Manager Privilege Escalation

  • CVE-2026-2625: rust-rpm-sequoia DoS Vulnerability

  • CVE-2021-20271: RPM Package Manager 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