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-20264

CVE-2021-20264: Oracle OpenJDK Privilege Escalation Flaw

CVE-2021-20264 is a privilege escalation vulnerability in Oracle OpenJDK containers allowing attackers to modify /etc/passwd and gain elevated privileges. This article covers technical details, affected versions, and mitigation.

Published: February 25, 2026

CVE-2021-20264 Overview

An insecure modification flaw in the /etc/passwd file was found in the openjdk-1.8 and openjdk-11 containers. This vulnerability allows an attacker with access to the container to modify the /etc/passwd file and escalate their privileges. The highest threat from this vulnerability is to confidentiality, integrity, as well as system availability.

Critical Impact

This privilege escalation vulnerability allows container users to gain elevated privileges by modifying the /etc/passwd file, potentially leading to complete container compromise and lateral movement within containerized environments.

Affected Products

  • Oracle OpenJDK 1.8.0 Container Images
  • Oracle OpenJDK 11 Container Images
  • Red Hat OpenJDK Container Images

Discovery Timeline

  • 2021-10-06 - CVE-2021-20264 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2021-20264

Vulnerability Analysis

This vulnerability stems from improper file permissions on the /etc/passwd file within OpenJDK container images. The insecure permissions allow non-privileged users within the container to modify the /etc/passwd file, which is critical for user authentication and privilege management on Unix-like systems.

The vulnerability is classified under CWE-266 (Incorrect Privilege Assignment) and CWE-732 (Incorrect Permission Assignment for Critical Resource). When exploited, an attacker can manipulate user entries in the /etc/passwd file to create new privileged users, modify existing user permissions, or change authentication credentials.

This flaw requires local access to the container (local attack vector) with low-privilege user access. The exploitation complexity is low, requiring no user interaction, making it a practical target for attackers who have already gained a foothold within the container environment.

Root Cause

The root cause of this vulnerability is incorrect permission assignment for the /etc/passwd file within the OpenJDK container images. The container images were built with overly permissive file permissions on the /etc/passwd file, allowing write access to non-root users. This violates the principle of least privilege and enables unauthorized modification of critical system files.

In standard Linux security practices, the /etc/passwd file should be readable by all users but writable only by root. The misconfiguration in the affected OpenJDK container images allows regular container users to modify this file, bypassing normal privilege restrictions.

Attack Vector

The attack exploits the local access to the container environment. An attacker who has gained access to the container, even as a low-privileged user, can exploit this vulnerability through the following attack flow:

  1. Initial Access: Attacker gains access to the container through a vulnerable application, compromised credentials, or other means
  2. File Permission Check: Attacker verifies write permissions on /etc/passwd
  3. Privilege Escalation: Attacker modifies /etc/passwd to add a new user with root privileges or changes the UID of their current user to 0
  4. Privileged Access: Attacker switches to the newly created or modified privileged user

The vulnerability requires no special tools or complex exploitation techniques, making it easily exploitable once container access is obtained.

Detection Methods for CVE-2021-20264

Indicators of Compromise

  • Unexpected modifications to the /etc/passwd file within container environments
  • New user accounts appearing in /etc/passwd with UID 0 or other elevated privileges
  • Changes to existing user entries, particularly modifications to UID/GID fields
  • Container process execution under unexpected user contexts

Detection Strategies

  • Implement file integrity monitoring on /etc/passwd and other critical system files within containers
  • Monitor for permission changes on sensitive files using audit logging
  • Deploy container security solutions that alert on privilege escalation attempts
  • Use SentinelOne Singularity Platform to detect and prevent container-based privilege escalation attacks
  • Enable auditd rules to track writes to /etc/passwd and /etc/shadow

Monitoring Recommendations

  • Configure container runtime security to detect file modifications in /etc/ directory
  • Implement real-time alerting for changes to authentication-related files
  • Deploy container-aware EDR solutions to monitor process privilege changes
  • Review container logs for unexpected su, sudo, or user context switching activities

How to Mitigate CVE-2021-20264

Immediate Actions Required

  • Audit all deployed OpenJDK container images for proper /etc/passwd file permissions
  • Update to patched container images from Oracle or Red Hat
  • Implement container security policies that restrict write access to critical system files
  • Deploy runtime container security monitoring to detect exploitation attempts
  • Review and validate file permissions on all container images before deployment

Patch Information

Oracle and Red Hat have addressed this vulnerability in updated container images. Organizations should pull the latest openjdk-1.8 and openjdk-11 container images from official repositories. Additional technical details and patch information can be found in the Red Hat Bug Report #1932283.

Workarounds

  • Manually correct file permissions on /etc/passwd within containers by ensuring only root has write access
  • Implement read-only root filesystems where possible using container runtime flags
  • Deploy container security policies using tools like Open Policy Agent (OPA) to enforce proper file permissions
  • Use admission controllers in Kubernetes to prevent deployment of containers with vulnerable images
bash
# Verify and fix /etc/passwd permissions in container
# Check current permissions
ls -la /etc/passwd

# Correct permissions if necessary (run as root)
chmod 644 /etc/passwd
chown root:root /etc/passwd

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

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechOracle Openjdk

  • SeverityHIGH

  • CVSS Score7.8

  • EPSS Probability0.12%

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

  • CWE-732
  • Technical References
  • Red Hat Bug Report #1932283
  • Related CVEs
  • CVE-2024-20952: Oracle OpenJDK Privilege Escalation Flaw

  • CVE-2021-35567: Oracle OpenJDK Auth Bypass Vulnerability

  • CVE-2021-2341: Oracle OpenJDK Information Disclosure Flaw

  • CVE-2021-2388: Oracle OpenJDK 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