CVE-2021-21355

8.6 HIGH

📋 TL;DR

This vulnerability allows unauthenticated attackers to upload arbitrary files with any extension to TYPO3 CMS servers. It affects TYPO3 installations using Extbase MVC framework with FileReference domain models that don't implement custom type converters. Attackers can upload malicious files that may be directly accessible.

💻 Affected Systems

Products:
  • TYPO3 CMS
Versions: TYPO3 versions before 8.7.40, 9.5.25, 10.4.14, 11.1.1
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects installations using Extbase MVC framework with FileReference domain models that rely on default UploadedFileReferenceConverter.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers upload web shells or malicious scripts, gain remote code execution, and compromise the entire server.

🟠

Likely Case

Attackers upload malicious files (PHP scripts, HTML pages with XSS) that get stored in accessible directories, enabling website defacement, data theft, or further attacks.

🟢

If Mitigated

With proper file extension filtering and directory restrictions, impact is limited to storage consumption and potential information disclosure through filename guessing.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploitation requires finding vulnerable extensions using FileReference models. Public advisories provide technical details.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: TYPO3 8.7.40, 9.5.25, 10.4.14, 11.1.1

Vendor Advisory: https://typo3.org/security/advisory/typo3-core-sa-2021-002

Restart Required: No

Instructions:

1. Identify your TYPO3 version. 2. Update to the patched version matching your branch (8.7.x, 9.5.x, 10.4.x, or 11.1.x). 3. Clear caches after update.

🔧 Temporary Workarounds

Restrict file upload directories

all

Configure web server to block execution in /fileadmin/user_upload/ directory

For Apache: Add 'php_flag engine off' to .htaccess in upload directory
For Nginx: Add 'location ~ \.php$ { deny all; }' for upload directory

Implement custom file type validation

all

Add custom type converter for FileReference models to enforce mime-type validation

🧯 If You Can't Patch

  • Disable or audit all extensions using FileReference domain models with Extbase MVC
  • Implement web application firewall rules to block suspicious file uploads

🔍 How to Verify

Check if Vulnerable:

Check TYPO3 version in Admin Tools > System or via composer show typo3/cms

Check Version:

composer show typo3/cms | grep version

Verify Fix Applied:

Confirm version is 8.7.40+, 9.5.25+, 10.4.14+, or 11.1.1+

📡 Detection & Monitoring

Log Indicators:

  • Unusual file uploads to /fileadmin/user_upload/
  • Files with unexpected extensions being uploaded

Network Indicators:

  • POST requests to TYPO3 endpoints with file uploads
  • Subsequent requests to uploaded files in user_upload directory

SIEM Query:

source="web_logs" AND (uri_path="/fileadmin/user_upload/*" AND method="POST") OR (uri_path="/fileadmin/user_upload/*.php" AND method="GET")

🔗 References

📤 Share & Export