Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
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-2021-21687

CVE-2021-21687: Jenkins Privilege Escalation Vulnerability

CVE-2021-21687 is a privilege escalation vulnerability in Jenkins that fails to check agent-to-controller access when creating symbolic links. This article covers technical details, affected versions, and mitigation.

Published: February 25, 2026

CVE-2021-21687 Overview

CVE-2021-21687 is a critical authorization bypass vulnerability affecting Jenkins 2.318 and earlier, as well as LTS 2.303.2 and earlier. The vulnerability exists in the FilePath#untar function, which fails to properly check agent-to-controller access when creating symbolic links during archive extraction operations. This missing authorization check allows malicious agents to create arbitrary symbolic links on the Jenkins controller, potentially leading to unauthorized access to sensitive files and data.

Critical Impact

Attackers with access to a Jenkins agent can exploit this vulnerability to create symbolic links that bypass agent-to-controller security restrictions, potentially compromising the confidentiality and integrity of the Jenkins controller and its data.

Affected Products

  • Jenkins 2.318 and earlier
  • Jenkins LTS 2.303.2 and earlier

Discovery Timeline

  • 2021-11-04 - CVE-2021-21687 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2021-21687

Vulnerability Analysis

This vulnerability is classified under CWE-862 (Missing Authorization), representing a critical flaw in Jenkins' security architecture. The core issue resides in the FilePath#untar method, which is responsible for extracting tar archives. When this method encounters symbolic links within an archive, it creates them on the file system without verifying whether the requesting agent has the appropriate permissions to create such links on the controller.

The agent-to-controller security subsystem in Jenkins is designed to restrict what operations agents can perform on the controller. This is a critical security boundary, as agents are often less trusted than the controller itself and may be running on compromised or less secure infrastructure. By failing to enforce this security boundary during untar operations, the vulnerability allows agents to effectively bypass access controls.

Root Cause

The root cause of CVE-2021-21687 is the absence of authorization checks in the FilePath#untar implementation when processing symbolic links. The method processes archive contents and recreates the file structure, including symbolic links, without consulting the agent-to-controller access control mechanism. This oversight means that even when administrators have configured strict agent-to-controller security policies, those policies are not enforced during archive extraction operations involving symbolic links.

Attack Vector

The attack vector for this vulnerability is network-based and can be exploited by any entity that controls a Jenkins agent. An attacker would need to:

  1. Gain control of or compromise a Jenkins agent connected to the target controller
  2. Craft a malicious tar archive containing symbolic links pointing to sensitive files or directories on the controller
  3. Trigger an untar operation on the controller via the compromised agent
  4. Use the created symbolic links to access or manipulate files that should be protected by agent-to-controller access controls

The symbolic links could point to sensitive configuration files, credentials, or other protected resources on the Jenkins controller, effectively allowing unauthorized read or write access depending on the target and the controller's file system permissions.

Detection Methods for CVE-2021-21687

Indicators of Compromise

  • Unexpected symbolic links appearing in Jenkins workspace or controller directories
  • Agent activity involving tar archive extraction operations targeting the controller
  • Unauthorized access attempts to sensitive files or directories through indirect paths
  • Unusual file access patterns from agent processes on the controller

Detection Strategies

  • Monitor Jenkins audit logs for FilePath#untar operations initiated by agents
  • Implement file integrity monitoring on the Jenkins controller to detect new symbolic links
  • Review agent activity logs for archive extraction operations
  • Deploy endpoint detection to identify suspicious file system operations

Monitoring Recommendations

  • Enable comprehensive Jenkins security audit logging to capture agent-to-controller operations
  • Configure alerts for symbolic link creation in sensitive controller directories
  • Monitor network traffic between agents and the controller for unusual archive transfer patterns
  • Regularly audit Jenkins controller file systems for unexpected symbolic links

How to Mitigate CVE-2021-21687

Immediate Actions Required

  • Upgrade Jenkins to version 2.319 or later immediately
  • For LTS users, upgrade to version 2.303.3 or later
  • Review agent-to-controller security configurations and restrict permissions
  • Audit existing symbolic links on Jenkins controllers for suspicious entries

Patch Information

Jenkins has addressed this vulnerability in Jenkins 2.319 and Jenkins LTS 2.303.3. The fix implements proper authorization checks in the FilePath#untar method to verify agent-to-controller access before creating symbolic links. Administrators should upgrade to these versions or later to fully remediate the vulnerability. For detailed information about the fix, refer to the Jenkins Security Advisory #SECURITY-2455.

Workarounds

  • Restrict agent-to-controller access to only trusted agents until patches can be applied
  • Disable or limit the use of archive extraction features where possible
  • Implement network segmentation between agents and controllers to limit exposure
  • Consider running agents in isolated environments to minimize the impact of potential compromise
bash
# Verify Jenkins version to ensure patched version is installed
java -jar jenkins-cli.jar -s http://your-jenkins-server/ version

# Check if version is 2.319+ (or LTS 2.303.3+)
# If running vulnerable version, upgrade immediately

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

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechJenkins

  • SeverityCRITICAL

  • CVSS Score9.1

  • EPSS Probability0.27%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityNone
  • CWE References
  • CWE-862
  • Vendor Resources
  • Jenkins Security Advisory #SECURITY-2455
  • Related CVEs
  • CVE-2025-31720: Jenkins Privilege Escalation Vulnerability

  • CVE-2025-31721: Jenkins Privilege Escalation Vulnerability

  • CVE-2021-21685: Jenkins Privilege Escalation Vulnerability

  • CVE-2026-33004: Jenkins LoadNinja Information Disclosure
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