CVE-2021-28480

9.8 CRITICAL

📋 TL;DR

CVE-2021-28480 is a critical remote code execution vulnerability in Microsoft Exchange Server that allows unauthenticated attackers to execute arbitrary code on vulnerable servers. This affects organizations running on-premises Exchange Server installations. Successful exploitation gives attackers full control over the Exchange server.

💻 Affected Systems

Products:
  • Microsoft Exchange Server
Versions: Exchange Server 2013, 2016, 2019
Operating Systems: Windows Server
Default Config Vulnerable: ⚠️ Yes
Notes: Affects all supported versions of Exchange Server. Exchange Online is not affected.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete compromise of Exchange server leading to data exfiltration, lateral movement to other systems, deployment of ransomware, and persistent backdoor access to the organization's email infrastructure.

🟠

Likely Case

Attackers gain initial foothold in the network, steal sensitive email data, deploy web shells for persistence, and use the compromised server for further attacks against internal systems.

🟢

If Mitigated

Attack attempts are blocked at network perimeter or detected by security controls, with minimal impact due to segmentation and monitoring.

🌐 Internet-Facing: HIGH - Exchange servers are typically internet-facing for email access, making them prime targets for external attackers.
🏢 Internal Only: MEDIUM - While primarily an external threat, compromised internal systems could also exploit this vulnerability.

🎯 Exploit Status

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

This vulnerability was actively exploited in the wild as part of the HAFNIUM attacks. Multiple exploit chains and proof-of-concepts are publicly available.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Security updates for Exchange Server 2013 CU23, 2016 CU19, 2019 CU8 and later

Vendor Advisory: https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2021-28480

Restart Required: Yes

Instructions:

1. Download the appropriate security update from Microsoft Update Catalog. 2. Apply the update to all Exchange servers. 3. Restart the Exchange services. 4. Run the Exchange Health Checker script to verify patch installation.

🔧 Temporary Workarounds

URL Rewrite Rule Mitigation

windows

Blocks malicious HTTP requests targeting the vulnerable component

Import-Module WebAdministration
Add-WebConfigurationProperty -pspath 'IIS:\Sites\Default Web Site\Autodiscover' -filter 'system.webServer/rewrite/rules' -name '.' -value @{name='Block CVE-2021-28480'; patternSyntax='ECMAScript'; stopProcessing='True'; match='.*autodiscover\.json.*@.*Powershell.*'} | Out-Null

🧯 If You Can't Patch

  • Isolate Exchange servers from the internet using firewall rules or reverse proxy
  • Implement network segmentation to limit lateral movement from Exchange servers

🔍 How to Verify

Check if Vulnerable:

Run the Exchange Health Checker script (HealthChecker.ps1) or check Exchange build numbers against patched versions

Check Version:

Get-ExchangeServer | Format-List Name, Edition, AdminDisplayVersion

Verify Fix Applied:

Verify Exchange Server build number matches patched versions: 2013 CU23+, 2016 CU19+, 2019 CU8+ with latest security updates

📡 Detection & Monitoring

Log Indicators:

  • Unusual PowerShell execution in Exchange logs
  • Suspicious Autodiscover requests
  • Web shell creation in Exchange directories

Network Indicators:

  • Unusual outbound connections from Exchange servers
  • HTTP requests to suspicious external IPs
  • Anomalous Autodiscover traffic patterns

SIEM Query:

source="exchange*" AND ("autodiscover.json" OR "PowerShell" OR "New-MailboxExportRequest") AND status=200

🔗 References

📤 Share & Export