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

CVE-2021-32802: Nextcloud Server SSRF Vulnerability

CVE-2021-32802 is an SSRF vulnerability in Nextcloud Server's image preview rendering that could allow file disclosure or code execution. This article covers the technical details, affected versions, and mitigation steps.

Published: February 25, 2026

CVE-2021-32802 Overview

CVE-2021-32802 is a critical vulnerability affecting Nextcloud Server, an open source, self-hosted personal cloud platform. The vulnerability exists in the image preview rendering functionality, where Nextcloud was invoking a third-party library unsuited for processing untrusted user-supplied content. This flaw enables multiple attack vectors including Server-Side Request Forgery (SSRF), file disclosure, and potentially arbitrary code execution on the affected system.

Critical Impact

Attackers can exploit the image preview feature to perform SSRF attacks, disclose sensitive files, or execute arbitrary code depending on system configuration and library versions installed.

Affected Products

  • Nextcloud Server versions prior to 20.0.12
  • Nextcloud Server versions prior to 21.0.4
  • Nextcloud Server versions prior to 22.1.0

Discovery Timeline

  • 2021-09-07 - CVE-2021-32802 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2021-32802

Vulnerability Analysis

This vulnerability falls under CWE-829 (Inclusion of Functionality from Untrusted Control Sphere), where Nextcloud Server incorporated a third-party library for rendering image previews that was not designed to safely handle untrusted user input. When users upload files to their Nextcloud instance, the server attempts to generate preview thumbnails for supported file types. The problematic library processes these user-supplied images without adequate input validation or sandboxing.

The exploitation potential varies based on the target environment's configuration and the specific version of the vulnerable library installed. In worst-case scenarios, attackers could leverage this vulnerability to achieve remote code execution. The vulnerability is accessible over the network and requires no authentication or user interaction to exploit, making it particularly dangerous for internet-facing Nextcloud deployments.

Root Cause

The root cause is the use of a third-party image processing library that was not designed to handle untrusted input securely. Nextcloud's preview generation feature passed user-uploaded file content directly to this library without proper sanitization or isolation, exposing the server to various attack vectors inherent to the library's functionality.

Attack Vector

The attack is network-based and can be exploited remotely. An attacker would craft a malicious file designed to exploit the vulnerable third-party library and upload it to a Nextcloud instance. When the server attempts to generate an image preview for this file, the malicious payload is processed, potentially resulting in:

  1. Server-Side Request Forgery (SSRF): The attacker can force the server to make requests to internal or external resources
  2. File Disclosure: Sensitive files on the server filesystem may be read and exfiltrated
  3. Code Execution: Depending on library version and system configuration, arbitrary code execution may be possible

The attack requires no authentication when public uploads are enabled, or can be performed by any authenticated user with file upload capabilities.

Detection Methods for CVE-2021-32802

Indicators of Compromise

  • Unusual outbound network connections from the Nextcloud server to internal or unexpected external addresses
  • Unexpected file access patterns in server logs, particularly accessing files outside the Nextcloud data directory
  • Anomalous CPU or memory usage during image preview generation
  • Error logs showing failed preview generation with unusual file types or malformed images

Detection Strategies

  • Monitor Nextcloud server logs for suspicious preview generation errors or unusual file processing activities
  • Implement network monitoring to detect SSRF attempts, particularly outbound connections to internal network ranges
  • Deploy file integrity monitoring on critical system files to detect unauthorized access or modification
  • Review uploaded files for known malicious image patterns or suspicious file structures

Monitoring Recommendations

  • Enable verbose logging for the Nextcloud preview generation subsystem
  • Configure network egress filtering and alerting for the Nextcloud server
  • Implement application-level monitoring to track preview generation requests and their outcomes
  • Set up alerts for unusual file access patterns or unexpected system calls from the web server process

How to Mitigate CVE-2021-32802

Immediate Actions Required

  • Upgrade Nextcloud Server to version 20.0.12, 21.0.4, or 22.1.0 or later immediately
  • If immediate upgrade is not possible, disable image previews as a temporary workaround
  • Audit uploaded files for potentially malicious content
  • Review server logs for signs of exploitation attempts

Patch Information

Nextcloud has released patched versions that no longer use the vulnerable third-party library for image preview generation. The following versions contain the fix:

  • Nextcloud Server 20.0.12 and later in the 20.x branch
  • Nextcloud Server 21.0.4 and later in the 21.x branch
  • Nextcloud Server 22.1.0 and later in the 22.x branch

For detailed information, refer to the GitHub Security Advisory GHSA-m682-v4g9-wrq7.

Workarounds

  • Disable image previews by setting enable_previews to false in config.php
  • Restrict file upload capabilities to trusted users only
  • Implement network segmentation to limit SSRF impact
  • Consider deploying a web application firewall (WAF) to filter malicious uploads
bash
# Configuration example - Disable previews in Nextcloud config.php
# Add or modify the following line in your config/config.php file:
'enable_previews' => false,

# To apply changes, ensure proper file permissions:
sudo chown www-data:www-data /var/www/nextcloud/config/config.php
sudo chmod 640 /var/www/nextcloud/config/config.php

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

  • Vulnerability Details
  • TypeSSRF

  • Vendor/TechNextcloud

  • SeverityCRITICAL

  • CVSS Score9.8

  • EPSS Probability2.25%

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

  • Gentoo GLSA 202208-17
  • Vendor Resources
  • Nextcloud Previews Configuration Guide

  • GitHub Security Advisory GHSA-m682-v4g9-wrq7
  • Related CVEs
  • CVE-2026-28474: Nextcloud Talk Auth Bypass Vulnerability
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