Attackers Can Hide Microsoft Defender Exclusions from PowerShell Queries

· Original article ↗

Summary

Huntress explains how attackers use Microsoft Defender Antivirus exclusions to evade scans, including a registry setting that can hide exclusions from PowerShell queries, and describes the telemetry and detections it added.

Key points

  • Attackers can use path and extension exclusions to prevent Defender from scanning files, including during real-time monitoring.
  • Exclusions can be added through PowerShell, WMI, Group Policy, or registry changes; they are ultimately represented in the registry.
  • A Group Policy registry entry can add exclusions directly, though the article says the change requires a reboot.
  • Setting HideExclusionsFromLocalAdmins can prevent administrators and SYSTEM users from viewing exclusions through PowerShell queries.
  • The exclusions can still be inspected directly in the registry.
  • Huntress says it added telemetry for exclusion changes and the hiding setting, plus detections for suspicious exclusions and attempts to hide them.

Article Details

Attack Vectors
  • Attackers add Microsoft Defender Antivirus path or extension exclusions through PowerShell, WMI, Group Policy, or direct modification of the Group Policy exclusions registry key, reducing scanning and real-time protection for matching files or paths.
  • Attackers can set the HideExclusionsFromLocalAdmins registry value to prevent exclusions from appearing in PowerShell queries by administrators and SYSTEM users.
Defensive Notes
  • Monitor registry operations that set Defender exclusions and the HideExclusionsFromLocalAdmins setting, regardless of the method used to create an exclusion.
  • Review exclusions directly in the registry when PowerShell queries do not show them.
  • Investigate suspicious exclusions, particularly those covering known-bad binaries or broad or commonly abused directories such as C:\, Temp, and Downloads.

MITRE ATT&CK

People

Threat Actors

Vendors

Products

Tools

Related Articles