ASR Rules Quick Reference
All 19 attack surface reduction rules. What each one stops, and how to roll it out.
Every Microsoft Defender ASR rule with its GUID, action types, Warn and alert support, exclusion behavior, the attack it breaks and what trips it legitimately, plus configuration in Intune, Group Policy and PowerShell, Microsoft's rollout sequence, monitoring queries and troubleshooting. No account needed.
All 19 Microsoft Defender attack surface reduction rules, with the facts Microsoft publishes for each one (GUID, names, action types, dependencies, Warn, alerts, operating system and deployment support, and which exclusions it honors) alongside what it blocks, the attack it breaks, what trips it legitimately and a query for its events. Then how to configure the rules in every tool, Microsoft's rollout sequence, monitoring, investigating a hit and troubleshooting.
What ASR rules are, and what they need
ASR rules stop specific behaviors that malware relies on and ordinary software rarely needs: Office starting a shell, a script launching what it downloaded, a process reading LSASS memory. Each rule is a single behavior, identified by a GUID, set to Off, Audit, Warn or Block. They are part of Microsoft Defender Antivirus, so they need it running as the primary antivirus.
| Requirement | What it means |
|---|---|
| Microsoft Defender Antivirus, in Active mode | Not passive mode, not passive with EDR in block mode, not limited periodic scanning, not off. A third-party antivirus as the primary product means no ASR rules. |
| Real-time protection on | The rules run as part of real-time protection. |
| Cloud-delivered protection | Microsoft calls it critical to the rules. Three rules need it to work at all, and some only raise EDR alerts or pop-ups at the higher cloud protection levels. The device must reach the Defender cloud service. |
| Current Defender components | Platform and engine no more than two versions behind the latest, and security intelligence kept current; Microsoft ties out-of-date versions to more false positives. |
| A way to deploy them | Defender for Endpoint enforces the rules but does not push them: Intune, the Defender portal, Configuration Manager, any MDM through the Policy CSP, Group Policy, or PowerShell on the device. |
| Licensing, for the reporting | The rules themselves do not need Microsoft 365 E5. The ASR report and device timeline need Defender for Endpoint Plan 2 or Defender for Business; advanced hunting needs Plan 2. Without them, the events are only in the local event log. |
| Windows Server 2012 R2 and 2016 | Onboarded with the modern unified solution package, or the rules (and the report) do not apply. |
The 19 rules at a glance
Microsoft calls the first three the standard protection rules and recommends Block mode for them; it says they can typically go straight to Block or Warn without an audit phase. Test the other sixteen in Audit first. The ASR report shows only the standard protection rules until you change its filter.
Rule modes
| Mode | Value | PowerShell name | What happens |
|---|---|---|---|
| Off | 0 | Disabled | The rule does not run. |
| Block | 1 | Enabled | The rule blocks the behavior and logs event 1121. |
| Audit | 2 | AuditMode | Nothing is blocked; what the rule would have blocked is logged as event 1122. |
| Not configured | 5 | NotConfigured | Equivalent to Off, without the potential for rule conflicts. The policy reference adds that a subsample of audit events is still collected for rules left Not configured, unless the rule is disabled. |
| Warn | 6 | Warn | Blocks, but the user can choose Unblock to bypass it for 24 hours, after which they are warned again. The bypass is logged as event 1129. |
- Warn needs Windows 10 1809 or later and Defender platform 4.18.2008.9 and engine 1.1.17400.5 or later. On older Windows the rule simply blocks. Configuration Manager cannot set Warn.
- Two rules have no Warn mode: LSASS credential theft and Office code injection.
- Since platform 4.18.26060, using Unblock on a Warn prompt needs administrator approval. Microsoft is explicit that Unblock is temporary suppression, not an exclusion: if the file should run, exclude it.
- The overview page lists audit detections under event IDs 1122, 1125, 1132 and 1134. The ASR events page and the troubleshooting page give 1122 as the rule audit event; 1125 is network protection's audit event.
Exclusions
An excluded file is allowed to run, and nothing is recorded about it: no event, no report entry. That is why exclusions are the decision in an ASR rollout that most needs a reason written down.
| Type | Scope | Set with |
|---|---|---|
| Defender Antivirus file and folder exclusions | Not every rule honors them (table below). Every rule honors Defender Antivirus process exclusions. | Any Defender Antivirus exclusion method |
| Global ASR exclusions (ASR only exclusions) | Every ASR rule. | Every configuration method, PowerShell included (AttackSurfaceReductionOnlyExclusions) |
| Per-rule exclusions | One rule. | Group Policy (and its registry values), Intune endpoint security policy, Defender portal endpoint security policy. Not PowerShell. |
| Indicators (IoCs) | Most rules honor file and certificate Allow indicators. | The Defender portal |
Which rules honor which exclusions
| Rule | Defender AV file and folder exclusions | Global ASR exclusions | Per-rule exclusions | File IoCs | Certificate IoCs |
|---|---|---|---|---|---|
| Vulnerable signed drivers | Yes | Yes | Yes | Yes | Yes |
| LSASS credential theft | No | Yes | Yes | No | No |
| WMI event subscription persistence | No | Yes | Yes | No | No |
| Adobe Reader child processes | No | Yes | Yes | Yes | Yes |
| Office child processes | Yes | Yes | Yes | Yes | Yes |
| Executable content from email | Yes | Yes | Yes | Yes | Yes |
| Prevalence, age or trusted list | Yes | Yes | Yes | Yes | Yes |
| Obfuscated scripts | Yes | Yes | Yes | Yes | Yes |
| Script launching downloads | Yes | Yes | Yes | Yes | Yes |
| Office writing executables | No | Yes | Yes | Yes | Yes |
| Office code injection | No | Yes | Yes | No | No |
| Outlook child processes | No | Yes | Yes | Yes | Yes |
| PsExec and WMI process creation | No | Yes | Yes | Yes | Yes |
| Safe Mode reboot | Yes | Yes | Yes | Yes | Yes |
| Untrusted processes from USB | Yes | Yes | Yes | Yes | Yes |
| Copied or impersonated system tools | Yes | Yes | Yes | Yes | Yes |
| Web shell creation on Exchange | Yes | Yes | Yes | Yes | Yes |
| Win32 API calls from macros | Yes | Yes | Yes | Yes | No |
| Advanced ransomware protection | Yes | Yes | Yes | Yes | Yes |
- Paths can use environment variables and wildcards, with the same rules as Defender Antivirus exclusions. Do not use user environment variables as wildcards.
- Microsoft recommends excluding the specific file rather than the folder.
- With Disable local admin merge on (Intune, Defender security settings management, the Defender CSP DisableLocalAdminMerge, or the Group Policy setting for local administrator merge), per-rule and local exclusions do not apply.
- Our rule: never exclude a folder a standard user can write to. An exclusion for C:\Users\*\Downloads is an instruction to put the payload there.
The rules
Each card gives the rule's purpose and our reading of it, then the reference facts parsed from Microsoft's tables, then a query for its events. Open a card from the table above, or filter by keyword.
01Block abuse of exploited vulnerable signed drivers (Device)Standard protection
Stops an application from writing a signed driver that Microsoft knows to be vulnerable to disk. It does not stop a driver that is already on the device from loading.
Bring your own vulnerable driver. An attacker with administrator rights drops a legitimately signed but exploitable driver, loads it, and uses it to reach the kernel, typically to kill or blind the endpoint security product before the ransomware or the credential theft starts.
Older hardware, firmware and system utilities that still install a driver Microsoft has since listed as vulnerable. The fix is the vendor's current version of the tool, not an exclusion.
- The rule only covers drivers being saved, so a vulnerable driver installed before the rule was turned on is not touched by it.
- Microsoft takes driver submissions for analysis at microsoft.com/wdsi/driversubmission.
- Microsoft pairs it with App Control for Business (Windows 10 and Server 2016 or later), the Microsoft vulnerable driver blocklist (Windows 11 and Server 2019 1809 or later) and AppLocker for older systems.
A standard protection rule: Microsoft says these can typically go to Block without an audit phase.
| Field | Value |
|---|---|
| GUID | 56a863a9-875e-4185-98a7-b882c64b5ce5 |
| Intune name | Block abuse of exploited vulnerable signed drivers (Device) |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrVulnerableSignedDriverAudited AsrVulnerableSignedDriverBlocked |
| Dependencies | None |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Windows Server 1803 (SAC) or later. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Vulnerable signed drivers: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrVulnerableSignedDriverAudited",
"AsrVulnerableSignedDriverBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, SHA256, InitiatingProcessFileName
| order by Hits desc02Block credential stealing from the Windows local security authority subsystemStandard protectionNo Warn mode
Denies other processes the access to LSASS process memory that credential dumping needs. It blocks the memory access, not the process: when it names svchost.exe or an updater, that process carried on running.
Credential dumping from LSASS with Mimikatz, a comsvcs.dll MiniDump call, a renamed ProcDump or a custom dumper, to collect NTLM hashes, Kerberos tickets and, where they are cached, cleartext passwords for lateral movement.
Very many processes open LSASS with more access than they need, so the rule is noisy by design: Microsoft's own example is Chrome's updater, which keeps working when denied. Inventory and monitoring agents that enumerate every process do the same. Microsoft lists one real conflict, Quest Dirsync Password Sync (KB 4253914).
- If LSA protection is on (Microsoft recommends it, with Credential Guard), this rule adds nothing, and the Defender portal marks it as not applicable.
- No Warn mode.
- Microsoft says its audit events are almost all safe to ignore once the rule is in Block, that you can skip the audit phase, and that it should start on a small set of devices and widen from there.
- It suppresses alerts and pop-ups for friendly processes and for repeat blocks, and the user notifications column is No.
- An app that only enumerates LSASS and keeps working does not need an exclusion.
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions, file IoCs or certificate IoCs.
Turn on RunAsPPL (LSA protection) where you can; where a driver or smart card stack prevents it, this rule is the stand-in. Read its audit data by the initiating process, not by the count.
| Field | Value |
|---|---|
| GUID | 9e6c4e1f-7d60-472f-ba1a-a39ef669e4b2 |
| Intune name | Block credential stealing from the Windows local security authority subsystem |
| Configuration Manager name | Block credential stealing from the Windows local security authority subsystem |
| Advanced hunting action types | AsrLsassCredentialTheftAudited AsrLsassCredentialTheftBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Not supported |
| EDR alert in Block or Warn | No |
| User notification | No |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: No. Certificate IoCs: No. |
| Windows | Windows 11: Yes. Windows 10: 1803 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1802 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// LSASS credential theft: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrLsassCredentialTheftAudited",
"AsrLsassCredentialTheftBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by InitiatingProcessFileName, InitiatingProcessFolderPath
| order by Hits desc03Block persistence through WMI event subscriptionStandard protection
Prevents processes from creating WMI event subscriptions that would run code when an event fires.
Fileless persistence: an __EventFilter, a CommandLineEventConsumer or ActiveScriptEventConsumer and the binding between them, stored in the WMI repository rather than on disk, so the payload comes back after every reboot or on a timer.
Management agents that register WMI subscriptions for monitoring. Configuration Manager is the one Microsoft names: its client depends on WMI.
- Not supported on Windows Server 2012 R2 or 2016 when deployed through Intune with the modern unified solution.
- With Configuration Manager in the estate, Microsoft asks for extensive Audit-mode testing before Block.
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions, file IoCs or certificate IoCs.
A standard protection rule, but the one of the three to audit first if Configuration Manager or another WMI-heavy agent manages the devices.
| Field | Value |
|---|---|
| GUID | e6db77e5-3df2-4cf1-b95a-636979351e5b |
| Intune name | Block persistence through WMI event subscription |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrPersistenceThroughWmiAudited AsrPersistenceThroughWmiBlocked |
| Dependencies | Microsoft Defender Antivirus, RPC |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes |
| User notification | Yes |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: No. Certificate IoCs: No. |
| Windows | Windows 11: Yes. Windows 10: 1903 or later. |
| Windows Server | 2019 and later: Windows Server 1903 (SAC) or later. 2016: No. 2012 R2: No. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// WMI event subscription persistence: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrPersistenceThroughWmiAudited",
"AsrPersistenceThroughWmiBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by InitiatingProcessFileName, InitiatingProcessCommandLine
| order by Hits desc04Block Adobe Reader from creating child processes
Stops Adobe Reader from starting any other process.
A malicious PDF that exploits the reader, or persuades the user to allow an action, and then launches a shell, a script host or a dropped payload from inside the Reader process.
Reader plug-ins and workflows that open a helper application, and PDFs with embedded launch actions that a business process genuinely depends on.
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions.
Usually quiet. Where Adobe Reader is not deployed it costs nothing to turn on.
| Field | Value |
|---|---|
| GUID | 7674ba52-37eb-4a4f-a9a1-f0f9a1619a2c |
| Intune name | Block Adobe Reader from creating child processes |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrAdobeReaderChildProcessAudited AsrAdobeReaderChildProcessBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes (High plus or Zero tolerance cloud protection only) |
| User notification | Yes (High, High plus or Zero tolerance cloud protection only) |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1809 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Adobe Reader child processes: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrAdobeReaderChildProcessAudited",
"AsrAdobeReaderChildProcessBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, InitiatingProcessFileName, InitiatingProcessCommandLine
| order by Hits desc05Block all Office applications from creating child processes
Stops Word, Excel, PowerPoint, OneNote and Access from starting child processes.
The macro or exploit document that spawns cmd.exe, powershell.exe, mshta.exe, rundll32.exe or a script host to download and run the next stage. It is the single most common way a phishing attachment turns into code execution.
Line-of-business macros and add-ins that shell out: Microsoft's examples are a macro starting a command prompt and PowerShell used to set registry values. Finance and reporting workbooks are the usual source.
- Enforced only when Office is installed under Program Files or Program Files (x86).
Expect the audit data to name a handful of workbooks or add-ins. Exclude the specific file the rule names, or fix the macro, rather than leaving the rule in Audit.
| Field | Value |
|---|---|
| GUID | d4f940ab-401b-4efc-aadc-ad5f3c50688a |
| Intune name | Block all Office applications from creating child processes |
| Configuration Manager name | Block Office application from creating child processes |
| Advanced hunting action types | AsrOfficeChildProcessAudited AsrOfficeChildProcessBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Office child processes: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrOfficeChildProcessAudited",
"AsrOfficeChildProcessBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, InitiatingProcessFileName, ProcessCommandLine
| order by Hits desc06Block executable content from email client and webmail
Stops mail opened in Outlook, Outlook.com and other common webmail from launching executables (.exe, .dll, .scr), scripts (.ps1, .vbs, .js) and archives such as .zip.
The attachment the user opens directly from the mail client or from the browser's download of a webmail attachment.
Users who legitimately receive tools, installers or scripts by email, typically IT staff and developers. Those should move to a file share or a software catalog, not to an exclusion.
- The same rule appears under other names: in Intune configuration profiles, Execution of executable content (exe, dll, ps, js, vbs, etc.) dropped from email (webmail/mail client) (no exceptions); in Configuration Manager, Block executable content download from email and webmail clients.
Usually quiet in a Microsoft 365 estate where attachment filtering already strips most executables.
| Field | Value |
|---|---|
| GUID | be9ba2d9-53ea-4cdc-84e5-9b1eeee46550 |
| Intune name | Block executable content from email client and webmail |
| Configuration Manager name | Block executable content from email client and webmail |
| Advanced hunting action types | AsrExecutableEmailContentAudited AsrExecutableEmailContentBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes (High plus or Zero tolerance cloud protection only) |
| User notification | Yes (High, High plus or Zero tolerance cloud protection only) |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Executable content from email: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrExecutableEmailContentAudited",
"AsrExecutableEmailContentBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, InitiatingProcessFileName
| order by Hits desc07Block executable files from running unless they meet a prevalence, age, or trusted list criterionNeeds cloud protection
Blocks executables (.exe, .dll, .scr) that the Microsoft cloud has not seen widely enough, long enough, or on a trusted list.
The freshly compiled or repacked payload: a loader built for this victim, which no reputation system has seen before.
In-house tools, newly built line-of-business software, developer output, small-vendor utilities and anything updated more often than reputation can keep up with. Expect it to be noisy on developer and IT devices, where most of that software lives.
- Needs cloud-delivered protection.
- Exclusions can be folder paths or fully qualified resource names.
- Its section on Learn says it has limited exclusion support, while Microsoft's exclusions table marks all five exclusion types as honored. Test an exclusion on one device before relying on it.
Roll it out to standard user devices first. On build servers and developer workstations, decide per ring whether its value is worth the exclusions.
| Field | Value |
|---|---|
| GUID | 01443614-cd74-433a-b99e-2ecdc07bfc25 |
| Intune name | Block executable files from running unless they meet a prevalence, age, or trusted list criterion |
| Configuration Manager name | Block executable files from running unless they meet a prevalence, age, or trusted list criteria |
| Advanced hunting action types | AsrUntrustedExecutableAudited AsrUntrustedExecutableBlocked |
| Dependencies | Microsoft Defender Antivirus, Cloud Protection |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1803 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1802 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Prevalence, age or trusted list: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrUntrustedExecutableAudited",
"AsrUntrustedExecutableBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, SHA256
| order by Hits desc08Block execution of potentially obfuscated scriptsNeeds cloud protection
Blocks scripts whose content shows the properties of obfuscation.
Encoded and string-mangled PowerShell, JavaScript and VBScript droppers and loaders written to defeat both a reader and signature scanning.
Legitimate software obfuscates too, to protect intellectual property or to load faster, which Microsoft calls out. Minified JavaScript in installers and packed vendor scripts are the usual sources.
- Depends on AMSI and cloud-delivered protection.
- Covers PowerShell scripts.
Audit first, then exclude the vendor script by its full path.
| Field | Value |
|---|---|
| GUID | 5beb7efe-fd9a-4556-801d-275e5ffc04cc |
| Intune name | Block execution of potentially obfuscated scripts |
| Configuration Manager name | Block execution of potentially obfuscated scripts |
| Advanced hunting action types | AsrObfuscatedScriptAudited AsrObfuscatedScriptBlocked |
| Dependencies | Microsoft Defender Antivirus, Antimalware Scan Interface (AMSI), Cloud Protection |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Obfuscated scripts: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrObfuscatedScriptAudited",
"AsrObfuscatedScriptBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, InitiatingProcessFileName
| order by Hits desc09Block JavaScript or VBScript from launching downloaded executable content
Stops JavaScript and VBScript from launching content they downloaded.
The .js or .vbs downloader, delivered in an archive or by HTML smuggling, that fetches the real payload and runs it through wscript.exe or cscript.exe.
Login scripts and line-of-business scripts that download and start an installer, which Microsoft says is uncommon but exists.
- Depends on AMSI.
- Not supported on Windows Server 2012 R2 or 2016 (the support table says No for both).
Usually quiet. A hit is worth reading, because the legitimate pattern is rare.
| Field | Value |
|---|---|
| GUID | d3e037e1-3eb8-44c8-a917-57927947596d |
| Intune name | Block JavaScript or VBScript from launching downloaded executable content |
| Configuration Manager name | Block JavaScript or VBScript from launching downloaded executable content |
| Advanced hunting action types | AsrScriptExecutableDownloadAudited AsrScriptExecutableDownloadBlocked |
| Dependencies | Microsoft Defender Antivirus, Antimalware Scan Interface (AMSI) |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes (High plus or Zero tolerance cloud protection only) |
| User notification | Yes (High, High plus or Zero tolerance cloud protection only) |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: No. 2012 R2: No. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Script launching downloads: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrScriptExecutableDownloadAudited",
"AsrScriptExecutableDownloadBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by InitiatingProcessFileName, InitiatingProcessCommandLine, FileName
| order by Hits desc10Block Office applications from creating executable content
Stops Office from being used to write executable components to disk: code the Office app wrote cannot be opened or run, and untrusted files saved by a macro cannot execute.
The macro that writes a DLL, an EXE or a script into the user profile and runs it, or leaves it to run at the next logon.
Add-ins and macros that generate or unpack executable files, such as report generators that write scripts, and templates that ship a helper.
- Depends on RPC.
- Unlike the other Office rules, it does not depend on where Office is installed.
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions.
Audit alongside the Office child process rule; the same few workbooks usually trip both.
| Field | Value |
|---|---|
| GUID | 3b576869-a4ec-4529-8536-b80a7769e899 |
| Intune name | Block Office applications from creating executable content |
| Configuration Manager name | Block Office applications from creating executable content |
| Advanced hunting action types | AsrExecutableOfficeContentAudited AsrExecutableOfficeContentBlocked |
| Dependencies | Microsoft Defender Antivirus, RPC |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Office writing executables: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrExecutableOfficeContentAudited",
"AsrExecutableOfficeContentBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, InitiatingProcessFileName
| order by Hits desc11Block Office applications from injecting code into other processesNo Warn mode
Blocks Word, Excel, OneNote and PowerPoint from injecting code into other processes.
A macro or exploit that migrates its payload into another process so it runs under a clean-looking image name.
Microsoft says there is no known legitimate business purpose for it. It does name two products that are incompatible with the rule: BeyondTrust Privilege Guard and Heimdal security.
- No Warn mode.
- Office apps must be restarted before a change to this rule takes effect.
- Enforced only when Office is installed under Program Files or Program Files (x86).
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions, file IoCs or certificate IoCs.
If neither incompatible product is deployed, a short audit to confirm silence is usually all it needs.
| Field | Value |
|---|---|
| GUID | 75668c1f-73b5-4cf0-bb93-3ecf5cb7cc84 |
| Intune name | Block Office applications from injecting code into other processes |
| Configuration Manager name | Block Office applications from injecting code into other processes |
| Advanced hunting action types | AsrOfficeProcessInjectionAudited AsrOfficeProcessInjectionBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Not supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: No. Certificate IoCs: No. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Office code injection: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrOfficeProcessInjectionAudited",
"AsrOfficeProcessInjectionBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, InitiatingProcessFileName
| order by Hits desc12Block Office communication application from creating child processes
Stops Outlook from starting child processes, while leaving Outlook's own functions working.
Exploits against Outlook itself, and the abuse of Outlook rules and custom forms that an attacker with stolen credentials uses to run code on the user's device.
Outlook add-ins that launch a helper, and links or attachments a business process opens through Outlook into a local application.
- Enforced only when Office is installed under Program Files or Program Files (x86).
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions.
Usually quiet.
| Field | Value |
|---|---|
| GUID | 26190899-1602-49e8-8b27-eb1d0a1ce869 |
| Intune name | Block Office communication application from creating child processes |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrOfficeCommAppChildProcessAudited AsrOfficeCommAppChildProcessBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Outlook child processes: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrOfficeCommAppChildProcessAudited",
"AsrOfficeCommAppChildProcessBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, ProcessCommandLine
| order by Hits desc13Block process creations originating from PSExec and WMI commands
Blocks processes created through PsExec and WMI from running.
Lateral movement and remote execution with PsExec, Impacket's psexec and wmiexec, and wmic process call create, which ransomware operators use to push the encryptor to every host at once.
Anything that manages devices by running commands through WMI or PsExec: Configuration Manager above all, plus remote-management and deployment tools and administrators' own scripts.
- With Configuration Manager in the estate, Microsoft says not to turn this rule on through any other method on managed devices, because the Configuration Manager client relies heavily on WMI. Configuration Manager itself cannot deploy it.
- Limited exclusion support. It does not honor Defender Antivirus file and folder exclusions.
The rule most likely to break IT operations. Audit it for longer than the others, read the hits by parent process, and do not move it to Block on devices that Configuration Manager manages.
| Field | Value |
|---|---|
| GUID | d1e49aac-8f56-4280-b9ba-993a6d77406c |
| Intune name | Block process creations originating from PSExec and WMI commands |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrPsexecWmiChildProcessAudited AsrPsexecWmiChildProcessBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: No. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1803 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// PsExec and WMI process creation: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrPsexecWmiChildProcessAudited",
"AsrPsexecWmiChildProcessBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by InitiatingProcessFileName, FileName, ProcessCommandLine
| order by Hits desc14Block rebooting machine in Safe Mode
Stops commands such as bcdedit and bootcfg from setting Windows to restart in Safe Mode.
Ransomware that reboots into Safe Mode, where most security products do not run, to encrypt without interference.
Administrators and repair scripts that set safeboot for troubleshooting. Safe Mode remains reachable by hand from the Windows Recovery Environment.
- Its audit action type appears in the reference as AsrSafeModeRebootedAudited, and it is one of two rules with a WarnBypassed action type.
Usually quiet. Neither EDR alerts nor pop-ups are generated, so watch its events in hunting.
| Field | Value |
|---|---|
| GUID | 33ddedf1-c6e0-47cb-833e-de6133960387 |
| Intune name | Block rebooting machine in Safe Mode |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrSafeModeRebootedAudited AsrSafeModeRebootBlocked AsrSafeModeRebootWarnBypassed |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | No |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Safe Mode reboot: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrSafeModeRebootedAudited",
"AsrSafeModeRebootBlocked",
"AsrSafeModeRebootWarnBypassed")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by InitiatingProcessFileName, InitiatingProcessCommandLine
| order by Hits desc15Block untrusted and unsigned processes that run from USB
Stops unsigned or untrusted executables (.exe, .dll, .scr) from running from removable USB drives, SD cards included. Copying a file to the disk is not blocked; Learn states the copied file is then also blocked from running.
Malware carried in on removable media, and tools an insider or visitor runs straight from a USB stick.
Portable and unsigned utilities run from a stick, typically by IT staff, engineers and field technicians.
- Covers SD cards as well as USB drives.
Pair it with device control if removable storage should not be used at all; this rule only governs what runs.
| Field | Value |
|---|---|
| GUID | b2b3f03d-6a65-4f7b-a9c7-1c7ef74a9ba4 |
| Intune name | Block untrusted and unsigned processes that run from USB |
| Configuration Manager name | Block untrusted and unsigned processes that run from USB |
| Advanced hunting action types | AsrUntrustedUsbProcessAudited AsrUntrustedUsbProcessBlocked |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1802 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Untrusted processes from USB: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrUntrustedUsbProcessAudited",
"AsrUntrustedUsbProcessBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, SHA256
| order by Hits desc16Block use of copied or impersonated system tools
Treats the executables in System32 and SysWOW64 as system tools, and blocks copies of them, or files with the same name, running from anywhere else, even when signed by Microsoft or another trusted vendor. It can also block a third-party executable that looks like a system tool from its location and behavior.
Renamed or relocated living-off-the-land binaries: rundll32.exe, certutil.exe or powershell.exe copied into a temp folder, or a payload named svchost.exe outside System32.
Software that ships its own copy of a Windows tool, and third-party executables installed in a nondefault path, which Microsoft says the heuristics can catch. Its diagnostics may not say which condition matched.
- A block means the file matched the rule, not that it is malicious.
- For a confirmed legitimate file, Microsoft says to add a global or per-rule ASR exclusion.
- One of two rules with a WarnBypassed action type.
Audit first and read the FolderPath of each hit; a system tool name in a user-writable path is worth a look before it is worth an exclusion.
| Field | Value |
|---|---|
| GUID | c0033c00-d16d-4114-a5a0-dc9b3a7d2ceb |
| Intune name | Block use of copied or impersonated system tools |
| Configuration Manager name | n/a |
| Advanced hunting action types | AsrAbusedSystemToolAudited AsrAbusedSystemToolBlocked AsrAbusedSystemToolWarnBypassed |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Copied or impersonated system tools: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrAbusedSystemToolAudited",
"AsrAbusedSystemToolBlocked",
"AsrAbusedSystemToolWarnBypassed")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, SHA256
| order by Hits desc17Block Webshell creation for Servers
Blocks the creation of web shell scripts on Windows servers running Microsoft Exchange.
The web shell dropped into an Exchange web directory after a server exploit, giving the attacker command execution, file transfer and credential theft through ordinary web requests.
Exchange setup and cumulative updates are the processes expected to write into those directories. Test one server through an update with the rule on before relying on it everywhere.
- Exchange servers only.
- No advanced hunting action type is listed for it, so its blocks are read from the event log on the server.
- Not supported on Windows Server 2012 R2 or 2016 through Intune with the modern unified solution.
- If Defender for Endpoint manages your ASR rules, leave this one Not Configured in Group Policy and local settings: any other value can conflict and stop it applying.
Only relevant if you still run Exchange Server on premises.
| Field | Value |
|---|---|
| GUID | a8f5898e-1dc8-49a9-9878-85004b8a61e6 |
| Intune name | Block Webshell creation for Servers |
| Configuration Manager name | n/a |
| Advanced hunting action types | None listed |
| Dependencies | Microsoft Defender Antivirus |
| Warn mode | Supported |
| EDR alert in Block or Warn | No |
| User notification | No |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: n/a. Windows 10: n/a. |
| Windows Server | 2019 and later: Exchange servers only. 2016: Exchange servers only. 2012 R2: No. |
| Deploy with | Intune: Yes. Configuration Manager: No. MDM CSP: Yes. Group Policy: Yes. |
Microsoft lists no advanced hunting action type for this rule. Read event 1121 and 1122 on the server itself, with the Get-WinEvent script under Monitoring.
18Block Win32 API calls from Office macros
Blocks VBA macros from calling Win32 APIs.
The macro that declares VirtualAlloc, CreateThread or similar and runs shellcode in memory without writing a file.
Old workbooks and add-ins that use VBA Declare statements to call Windows functions, for timers, window handling or file dialogs. Microsoft says most organizations do not need this even when they use macros.
- Depends on AMSI.
- Not applicable to Windows Server.
- It does not honor certificate IoCs.
Audit and search the hits by document name; the owners of the few workbooks that need it are usually easy to find.
| Field | Value |
|---|---|
| GUID | 92e97fa1-2edf-4476-bdd6-9dd0b4dddc7b |
| Intune name | Block Win32 API calls from Office macros |
| Configuration Manager name | Block Win32 API calls from Office macros |
| Advanced hunting action types | AsrOfficeMacroWin32ApiCallsAudited AsrOfficeMacroWin32ApiCallsBlocked |
| Dependencies | Microsoft Defender Antivirus, Antimalware Scan Interface (AMSI) |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes |
| User notification | No |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: No. |
| Windows | Windows 11: Yes. Windows 10: 1709 or later. |
| Windows Server | 2019 and later: n/a. 2016: n/a. 2012 R2: n/a. |
| Deploy with | Intune: Yes. Configuration Manager: 1710 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Win32 API calls from macros: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrOfficeMacroWin32ApiCallsAudited",
"AsrOfficeMacroWin32ApiCallsBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, InitiatingProcessFileName
| order by Hits desc19Use advanced protection against ransomwareNeeds cloud protection
Uses client and cloud heuristics to block files that resemble ransomware. It does not block files the cloud has judged clean, validly signed files, or files prevalent enough not to be ransomware, but it does block files that have no positive reputation yet.
The ransomware binary itself, at the point it runs.
New, unsigned or rarely seen executables, the same population as the prevalence rule. Microsoft says these blocks usually resolve as the file's reputation builds.
- Needs cloud-delivered protection.
- Not supported on Windows Server 2012 R2 or 2016 through Intune with the modern unified solution.
- If a benign file stays blocked, Microsoft suggests a per-rule exclusion or an Allow indicator.
- Its section on Learn says it has limited exclusion support, while Microsoft's exclusions table marks all five exclusion types as honored. Test an exclusion on one device before relying on it.
Audit with the prevalence rule; the same files tend to trip both.
| Field | Value |
|---|---|
| GUID | c1db55ab-c21a-4637-bb3f-a12568109d35 |
| Intune name | Use advanced protection against ransomware |
| Configuration Manager name | Use advanced protection against ransomware |
| Advanced hunting action types | AsrRansomwareAudited AsrRansomwareBlocked |
| Dependencies | Microsoft Defender Antivirus, Cloud Protection |
| Warn mode | Supported |
| EDR alert in Block or Warn | Yes |
| User notification | Yes |
| Honors | Defender AV path exclusions: Yes. Global ASR exclusions: Yes. Per-rule: Yes. File IoCs: Yes. Certificate IoCs: Yes. |
| Windows | Windows 11: Yes. Windows 10: 1803 or later. |
| Windows Server | 2019 and later: Yes. 2016: Yes. 2012 R2: Yes. |
| Deploy with | Intune: Yes. Configuration Manager: 1802 or later. MDM CSP: Yes. Group Policy: Yes. |
Thirty days of the rule's audit, block and Warn events, grouped the way you would read them before deciding on an exclusion.
// Advanced ransomware protection: blocks, audits and Warn bypasses
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType in (
"AsrRansomwareAudited",
"AsrRansomwareBlocked")
| summarize Hits = count(), Devices = dcount(DeviceName),
Modes = make_set(ActionType), LastSeen = max(Timestamp)
by FileName, FolderPath, SHA256
| order by Hits descOperating system support
Server 2016 and 2012 R2 need the modern unified solution package. Y means every supported version.
| Rule | Windows 11 | Windows 10 | Server 2019 and later | Server 2016 | Server 2012 R2 |
|---|---|---|---|---|---|
| Vulnerable signed drivers | Y | 1709 or later | Y | Windows Server 1803 (SAC) or later | Y |
| LSASS credential theft | Y | 1803 or later | Y | Y | Y |
| WMI event subscription persistence | Y | 1903 or later | Windows Server 1903 (SAC) or later | N | N |
| Adobe Reader child processes | Y | 1809 or later | Y | Y | Y |
| Office child processes | Y | 1709 or later | Y | Y | Y |
| Executable content from email | Y | 1709 or later | Y | Y | Y |
| Prevalence, age or trusted list | Y | 1803 or later | Y | Y | Y |
| Obfuscated scripts | Y | 1709 or later | Y | Y | Y |
| Script launching downloads | Y | 1709 or later | Y | N | N |
| Office writing executables | Y | 1709 or later | Y | Y | Y |
| Office code injection | Y | 1709 or later | Y | Y | Y |
| Outlook child processes | Y | 1709 or later | Y | Y | Y |
| PsExec and WMI process creation | Y | 1803 or later | Y | Y | Y |
| Safe Mode reboot | Y | 1709 or later | Y | Y | Y |
| Untrusted processes from USB | Y | 1709 or later | Y | Y | Y |
| Copied or impersonated system tools | Y | 1709 or later | Y | Y | Y |
| Web shell creation on Exchange | n/a | n/a | Exchange servers only | Exchange servers only | N |
| Win32 API calls from macros | Y | 1709 or later | n/a | n/a | n/a |
| Advanced ransomware protection | Y | 1803 or later | Y | Y | Y |
Deployment method support
Configuration Manager entries give the first version that supports the rule; N means it cannot deploy it. PowerShell supports every rule.
| Rule | Intune | Configuration Manager | MDM CSP | Group Policy |
|---|---|---|---|---|
| Vulnerable signed drivers | Y | N | Y | Y |
| LSASS credential theft | Y | 1802 or later | Y | Y |
| WMI event subscription persistence | Y | N | Y | Y |
| Adobe Reader child processes | Y | N | Y | Y |
| Office child processes | Y | 1710 or later | Y | Y |
| Executable content from email | Y | 1710 or later | Y | Y |
| Prevalence, age or trusted list | Y | 1802 or later | Y | Y |
| Obfuscated scripts | Y | 1710 or later | Y | Y |
| Script launching downloads | Y | 1710 or later | Y | Y |
| Office writing executables | Y | 1710 or later | Y | Y |
| Office code injection | Y | 1710 or later | Y | Y |
| Outlook child processes | Y | N | Y | Y |
| PsExec and WMI process creation | Y | N | Y | Y |
| Safe Mode reboot | Y | N | Y | Y |
| Untrusted processes from USB | Y | 1802 or later | Y | Y |
| Copied or impersonated system tools | Y | N | Y | Y |
| Web shell creation on Exchange | Y | N | Y | Y |
| Win32 API calls from macros | Y | 1710 or later | Y | Y |
| Advanced ransomware protection | Y | 1802 or later | Y | Y |
Configuring the rules
Use one method per rule. Configuring the same rule in two places is how a rule ends up in a mode nobody set.
| Source | Precedence |
|---|---|
| Set-MpPreference on the device | Lowest. Any policy overwrites it at startup. |
| Group Policy | Beats local settings. Beats MDM by default, unless MDMWinsOverGP is set to 1. |
| Intune or another MDM | Beats local settings. Beats Group Policy only with MDMWinsOverGP = 1, which can only be set through the Policy CSP (an Intune custom profile: ./Device/Vendor/MSFT/Policy/Config/ControlPolicyConflict/MDMWinsOverGP, integer, 1). There is no Group Policy setting or cmdlet for it. |
| Configuration Manager | Applies the rules through the Policy CSP, so it follows the MDM behavior. |
| Controlled configuration | Enforces Intune or Defender security settings management only, and ignores conflicting Group Policy, Configuration Manager and local settings. |
Intune endpoint security policy (recommended)
- Endpoint security, Attack surface reduction, Create policy. Platform Windows, profile Attack Surface Reduction Rules.
- Assign to Entra ID device groups. Defender for Endpoint management supports device objects only, not users.
- Set each rule to Audit, Block or Warn. Once a rule has a mode, a per-rule exclusion box appears under it.
- Attack surface reduction only exclusions holds the global exclusions; you can type paths or import a CSV with the header AttackSurfaceReductionOnlyExclusions. Double quotes are optional and ignored; single quotes are not allowed.
- In the Defender portal, the Windows policies tab of the Endpoint security policies page (security.microsoft.com/policy-inventory) has the same policy, template Attack surface reduction rules, for devices in security settings management.
Intune custom profile or any MDM (Policy CSP)
| Setting | OMA-URI | Value |
|---|---|---|
| Rules | ./Vendor/MSFT/Policy/Config/Defender/AttackSurfaceReductionRules | String: GUID=mode|GUID=mode, with no spaces |
| Global exclusions | ./Device/Vendor/MSFT/Policy/Config/Defender/AttackSurfaceReductionOnlyExclusions | String: C:\folder|%ProgramFiles%\folder\file.exe |
7674ba52-37eb-4a4f-a9a1-f0f9a1619a2c=2|d4f940ab-401b-4efc-aadc-ad5f3c50688a=2|be9ba2d9-53ea-4cdc-84e5-9b1eeee46550=2Group Policy and the registry
- Computer Configuration, Administrative Templates, Windows Components, Microsoft Defender Antivirus, Microsoft Defender Exploit Guard, Attack Surface Reduction. Older templates (before Windows 10 2004) say Windows Defender Antivirus.
- Configure Attack Surface Reduction rules: Enabled, then Show. Value name is the rule GUID, value is the mode (0, 1, 2, 5 or 6).
- Exclude files and paths from Attack Surface Reduction rules: value name is the path, value is 0. Applies to every rule.
- Apply a list of exclusions to specific attack surface reduction (ASR) rules: value name is the rule GUID, value is a list of paths separated by >, for example C:\Windows\Notepad.exe>C:\Tools\test.exe. It needs the 24H2 or later Administrative Templates in the Central Store.
- No quotation marks, no leading or trailing spaces, no extra characters, anywhere in the values.
- The settings are written under the policy key below (WindowsDefender.admx, value names ExploitGuard_ASR_Rules and ExploitGuard_ASR_ASROnlyExclusions). Read it on a device to see what Group Policy delivered.
reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows Defender\Windows Defender Exploit Guard\ASR" /sPowerShell
Add-MpPreference adds rules or exclusions without touching the rest. Set-MpPreference replaces the whole list with what you pass, so a Set with one rule removes every other locally set rule. Remove-MpPreference removes the entries you name. Management tools overwrite local settings at startup, so on a managed device PowerShell is for testing and reading, not for deployment. There is no per-rule exclusion parameter.
# The rules on this device, with their mode and name
$names = @{
"56a863a9-875e-4185-98a7-b882c64b5ce5" = "Vulnerable signed drivers"
"9e6c4e1f-7d60-472f-ba1a-a39ef669e4b2" = "LSASS credential theft"
"e6db77e5-3df2-4cf1-b95a-636979351e5b" = "WMI event subscription persistence"
"7674ba52-37eb-4a4f-a9a1-f0f9a1619a2c" = "Adobe Reader child processes"
"d4f940ab-401b-4efc-aadc-ad5f3c50688a" = "Office child processes"
"be9ba2d9-53ea-4cdc-84e5-9b1eeee46550" = "Executable content from email"
"01443614-cd74-433a-b99e-2ecdc07bfc25" = "Prevalence, age or trusted list"
"5beb7efe-fd9a-4556-801d-275e5ffc04cc" = "Obfuscated scripts"
"d3e037e1-3eb8-44c8-a917-57927947596d" = "Script launching downloads"
"3b576869-a4ec-4529-8536-b80a7769e899" = "Office writing executables"
"75668c1f-73b5-4cf0-bb93-3ecf5cb7cc84" = "Office code injection"
"26190899-1602-49e8-8b27-eb1d0a1ce869" = "Outlook child processes"
"d1e49aac-8f56-4280-b9ba-993a6d77406c" = "PsExec and WMI process creation"
"33ddedf1-c6e0-47cb-833e-de6133960387" = "Safe Mode reboot"
"b2b3f03d-6a65-4f7b-a9c7-1c7ef74a9ba4" = "Untrusted processes from USB"
"c0033c00-d16d-4114-a5a0-dc9b3a7d2ceb" = "Copied or impersonated system tools"
"a8f5898e-1dc8-49a9-9878-85004b8a61e6" = "Web shell creation on Exchange"
"92e97fa1-2edf-4476-bdd6-9dd0b4dddc7b" = "Win32 API calls from macros"
"c1db55ab-c21a-4637-bb3f-a12568109d35" = "Advanced ransomware protection"
}
$modes = @{ 0 = "Off"; 1 = "Block"; 2 = "Audit"; 5 = "Not configured"; 6 = "Warn" }
$p = Get-MpPreference
$ids = $p.AttackSurfaceReductionRules_Ids
$acts = $p.AttackSurfaceReductionRules_Actions
for ($i = 0; $i -lt $ids.Count; $i++) {
[pscustomobject]@{
Rule = $names[$ids[$i].ToLower()]
Mode = $modes[[int]$acts[$i]]
Id = $ids[$i]
}
}# Every rule in Audit, without touching anything else (run elevated)
$ids = @(
"56a863a9-875e-4185-98a7-b882c64b5ce5",
"9e6c4e1f-7d60-472f-ba1a-a39ef669e4b2",
"e6db77e5-3df2-4cf1-b95a-636979351e5b",
"7674ba52-37eb-4a4f-a9a1-f0f9a1619a2c",
"d4f940ab-401b-4efc-aadc-ad5f3c50688a",
"be9ba2d9-53ea-4cdc-84e5-9b1eeee46550",
"01443614-cd74-433a-b99e-2ecdc07bfc25",
"5beb7efe-fd9a-4556-801d-275e5ffc04cc",
"d3e037e1-3eb8-44c8-a917-57927947596d",
"3b576869-a4ec-4529-8536-b80a7769e899",
"75668c1f-73b5-4cf0-bb93-3ecf5cb7cc84",
"26190899-1602-49e8-8b27-eb1d0a1ce869",
"d1e49aac-8f56-4280-b9ba-993a6d77406c",
"33ddedf1-c6e0-47cb-833e-de6133960387",
"b2b3f03d-6a65-4f7b-a9c7-1c7ef74a9ba4",
"c0033c00-d16d-4114-a5a0-dc9b3a7d2ceb",
"a8f5898e-1dc8-49a9-9878-85004b8a61e6",
"92e97fa1-2edf-4476-bdd6-9dd0b4dddc7b",
"c1db55ab-c21a-4637-bb3f-a12568109d35"
)
$acts = $ids | ForEach-Object { "AuditMode" }
Add-MpPreference -AttackSurfaceReductionRules_Ids $ids -AttackSurfaceReductionRules_Actions $acts# One rule to Block, one to Warn, one back to Audit
Add-MpPreference -AttackSurfaceReductionRules_Ids d4f940ab-401b-4efc-aadc-ad5f3c50688a -AttackSurfaceReductionRules_Actions Enabled
Add-MpPreference -AttackSurfaceReductionRules_Ids 01443614-cd74-433a-b99e-2ecdc07bfc25 -AttackSurfaceReductionRules_Actions Warn
Add-MpPreference -AttackSurfaceReductionRules_Ids d1e49aac-8f56-4280-b9ba-993a6d77406c -AttackSurfaceReductionRules_Actions AuditMode
# Remove a rule's local setting altogether
Remove-MpPreference -AttackSurfaceReductionRules_Ids d1e49aac-8f56-4280-b9ba-993a6d77406c# Global ASR exclusions: they apply to every rule
Add-MpPreference -AttackSurfaceReductionOnlyExclusions "C:\Apps\Finance\report.exe"
(Get-MpPreference).AttackSurfaceReductionOnlyExclusions
Remove-MpPreference -AttackSurfaceReductionOnlyExclusions "C:\Apps\Finance\report.exe"Rolling out: Microsoft's sequence
Microsoft's deployment guide has four stages: plan, test, enable, and manage. Microsoft gives no durations for any of them; the audit period is as long as it takes your audit data to show a full business cycle.
| Stage | What Microsoft says to do |
|---|---|
| Plan | Choose the business units and champions, define roles, and set up deployment rings, starting with a small pilot ring. |
| Test | Disable any rules already in Block or Warn on the ring. Put all the rules in Audit at once on ring 1, so you see which ones everyday work triggers. Review the ASR report, advanced hunting, the device timeline or event 1122. With Plan 2, the security recommendations for each rule show a user impact percentage. Add exclusions with the same method you used for the rules. |
| Enable | Move rules to Block or Warn, starting with the rule with the fewest triggered events. Review activity and champion feedback, refine exclusions. Then repeat for ring n + 1: Audit, review, exclude, Block, review, and disable or return to Audit any rule that causes trouble. |
| Manage | Review the reports and hunting data on a schedule that fits your size: Microsoft suggests hourly, daily or continuously. |
- Standard protection rules: Block or Warn without testing is Microsoft's typical advice.
- LSASS credential theft: Microsoft says you can skip audit and go to Block, starting small.
- PsExec and WMI, and WMI persistence: if Configuration Manager manages the devices, test hard, and do not set the PsExec and WMI rule through another method on those devices.
- Exclusions beat turning a rule off or back to Audit, and Warn beats both where users need a way through.
- The deployment method does not change the reporting, as long as the devices are onboarded.
Ranking the rules for the move to Block, in Microsoft's order:
// Microsoft's order for moving rules from Audit to Block:
// the rule with the fewest triggered events first
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType startswith "Asr" and ActionType endswith "Audited"
| summarize Events = count(), Devices = dcount(DeviceName),
Apps = dcount(InitiatingProcessFileName) by ActionType
| order by Events ascReading the audit data: our decisions
| The audit data shows | Do this |
|---|---|
| No events for a rule after a representative period | Move it to Block (or Warn) in the ring. A rule that never fires costs nothing. |
| Events from one or two known, legitimate files | Add a per-rule exclusion for each file by full path, then Block. Prefer the file to the folder. |
| Events from many unrelated apps | Keep it in Audit for this ring, and find out why before excluding anything: a folder exclusion broad enough to quiet it usually removes most of the protection. |
| Events where the user would be stuck without a way round | Use Warn where the rule supports it, so the user can proceed and you still collect the data. Since platform 4.18.26060, Unblock needs administrator approval. |
| Events from an app you cannot exclude cleanly (a tool run from a user-writable path) | Fix the app, its install location or the process before the rule. An exclusion for a writable path is an exclusion for anyone who can write there. |
| Events that look malicious | Treat it as an incident first and a tuning question second. See Investigating an ASR hit. |
Monitoring
Windows events
| Event | Log | Meaning |
|---|---|---|
| 1121 | Windows Defender/Operational | A rule blocked an operation (Block or Warn mode). |
| 1122 | Windows Defender/Operational | A rule in Audit mode would have blocked an operation. |
| 1129 | Windows Defender/Operational | A user allowed a blocked operation from a Warn mode prompt. |
| 5007 | Windows Defender/Operational | Defender configuration changed, ASR rules and exclusions included. The message has the old and the new value. |
| Field in the 1121 and 1122 message | What it holds |
|---|---|
| ID | The rule GUID. Look it up in the GUID table. |
| Detection time | When the rule fired. |
| User | The account the operation ran as. |
| Path | The file the rule acted on: the report calls it the detected file. |
| Process Name | The process that attempted the operation: the report's source app. |
| Target Commandline, Parent Commandline | Command lines, where the rule records them. |
| Involved File | A second file involved in the operation, where there is one. |
On a device, or across many through Invoke-Command, this gives each block, audit and Warn bypass with the rule name:
# ASR blocks, audits and Warn bypasses from the Defender operational log, by rule and file
$names = @{
"56a863a9-875e-4185-98a7-b882c64b5ce5" = "Vulnerable signed drivers"
"9e6c4e1f-7d60-472f-ba1a-a39ef669e4b2" = "LSASS credential theft"
"e6db77e5-3df2-4cf1-b95a-636979351e5b" = "WMI event subscription persistence"
"7674ba52-37eb-4a4f-a9a1-f0f9a1619a2c" = "Adobe Reader child processes"
"d4f940ab-401b-4efc-aadc-ad5f3c50688a" = "Office child processes"
"be9ba2d9-53ea-4cdc-84e5-9b1eeee46550" = "Executable content from email"
"01443614-cd74-433a-b99e-2ecdc07bfc25" = "Prevalence, age or trusted list"
"5beb7efe-fd9a-4556-801d-275e5ffc04cc" = "Obfuscated scripts"
"d3e037e1-3eb8-44c8-a917-57927947596d" = "Script launching downloads"
"3b576869-a4ec-4529-8536-b80a7769e899" = "Office writing executables"
"75668c1f-73b5-4cf0-bb93-3ecf5cb7cc84" = "Office code injection"
"26190899-1602-49e8-8b27-eb1d0a1ce869" = "Outlook child processes"
"d1e49aac-8f56-4280-b9ba-993a6d77406c" = "PsExec and WMI process creation"
"33ddedf1-c6e0-47cb-833e-de6133960387" = "Safe Mode reboot"
"b2b3f03d-6a65-4f7b-a9c7-1c7ef74a9ba4" = "Untrusted processes from USB"
"c0033c00-d16d-4114-a5a0-dc9b3a7d2ceb" = "Copied or impersonated system tools"
"a8f5898e-1dc8-49a9-9878-85004b8a61e6" = "Web shell creation on Exchange"
"92e97fa1-2edf-4476-bdd6-9dd0b4dddc7b" = "Win32 API calls from macros"
"c1db55ab-c21a-4637-bb3f-a12568109d35" = "Advanced ransomware protection"
}
$kind = @{ 1121 = "Block"; 1122 = "Audit"; 1129 = "Warn bypassed" }
$filter = @{
LogName = "Microsoft-Windows-Windows Defender/Operational"
Id = 1121, 1122, 1129
StartTime = [datetime]::Now.AddDays(-7)
}
Get-WinEvent -FilterHashtable $filter -ErrorAction SilentlyContinue | ForEach-Object {
$id = if ($_.Message -match "ID:\s*\{?([0-9A-Fa-f-]{36})") { $Matches[1].ToLower() }
$path = if ($_.Message -match "Path:\s*(.+)") { $Matches[1].Trim() }
$proc = if ($_.Message -match "Process Name:\s*(.+)") { $Matches[1].Trim() }
[pscustomobject]@{
Time = $_.TimeCreated
Kind = $kind[$_.Id]
Rule = $names[$id]
Path = $path
Process = $proc
}
} | Sort-Object Time -Descending | Format-Table -AutoSize# Configuration changes to Defender, including ASR rules and exclusions
Get-WinEvent -FilterHashtable @{
LogName = "Microsoft-Windows-Windows Defender/Operational"; Id = 5007
} -MaxEvents 50 | Select-Object TimeCreated, Message | Format-ListWithout Plan 2, these events are the only record. Microsoft points to Windows Event Forwarding to collect them centrally; once in Sentinel, the Event table holds them:
// The same events collected to Sentinel from the Defender operational log
Event
| where TimeGenerated > ago(7d)
| where EventLog == "Microsoft-Windows-Windows Defender/Operational"
| where EventID in (1121, 1122, 1129, 5007)
| extend Kind = case(EventID == 1121, "Block", EventID == 1122, "Audit",
EventID == 1129, "Warn bypassed", "Setting changed")
| extend RuleId = extract(@"ID:\s*\{?([0-9A-Fa-f-]{36})", 1,
RenderedDescription)
| summarize Events = count() by Computer, Kind, RuleId
| order by Events descThe ASR report
- Reports, Endpoints, Attack surface reduction rules, or security.microsoft.com/asr. Tabs: Detections, Configuration, Add exclusions.
- Detections defaults to the standard protection rules and the last 30 days, the most it covers. Switch the rules filter to All to see the rest.
- Each detection shows the detected file, the source app, the device, the user, the rule and whether it was audited or blocked. The table lists at most 200 items; Export saves the full list to CSV.
- It needs Security data basics (read) in unified RBAC, or the Security Reader, Global Reader, Security Administrator or Global Administrator role.
- For anything older than 30 days, or joined to other data, use advanced hunting.
Advanced hunting
Every rule except the web shell rule writes to DeviceEvents with an ActionType beginning Asr and ending Audited, Blocked or, for two rules, WarnBypassed. This summarizes all of them by rule and mode:
let Rules = datatable(Prefix: string, Rule: string) [
"AsrVulnerableSignedDriver", "Vulnerable signed drivers",
"AsrLsassCredentialTheft", "LSASS credential theft",
"AsrPersistenceThroughWmi", "WMI event subscription persistence",
"AsrAdobeReaderChildProcess", "Adobe Reader child processes",
"AsrOfficeChildProcess", "Office child processes",
"AsrExecutableEmailContent", "Executable content from email",
"AsrUntrustedExecutable", "Prevalence, age or trusted list",
"AsrObfuscatedScript", "Obfuscated scripts",
"AsrScriptExecutableDownload", "Script launching downloads",
"AsrExecutableOfficeContent", "Office writing executables",
"AsrOfficeProcessInjection", "Office code injection",
"AsrOfficeCommAppChildProcess", "Outlook child processes",
"AsrPsexecWmiChildProcess", "PsExec and WMI process creation",
"AsrSafeModeReboot", "Safe Mode reboot",
"AsrUntrustedUsbProcess", "Untrusted processes from USB",
"AsrAbusedSystemTool", "Copied or impersonated system tools",
"AsrOfficeMacroWin32ApiCalls", "Win32 API calls from macros",
"AsrRansomware", "Advanced ransomware protection"
];
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType startswith "Asr"
| extend Prefix = replace_regex(ActionType,
@"(Rebooted)?(Audited|Blocked|WarnBypassed)$", "")
| extend Prefix = iff(Prefix == "AsrSafeMode", "AsrSafeModeReboot", Prefix)
| extend Mode = case(ActionType endswith "Audited", "Audit",
ActionType endswith "Blocked", "Block", "Warn bypassed")
| lookup kind=leftouter Rules on Prefix
| summarize Events = count(), Devices = dcount(DeviceName),
Apps = dcount(InitiatingProcessFileName) by Rule, Mode
| order by Rule asc, Mode asc// The apps behind most audit events, rule by rule: the exclusion shortlist
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType startswith "Asr" and ActionType endswith "Audited"
| summarize Events = count(), Devices = dcount(DeviceName),
Files = make_set(FileName, 5)
by ActionType, InitiatingProcessFileName, InitiatingProcessFolderPath
| top 50 by Events desc// The fields the ASR report's detection page uses, for one file
DeviceEvents
| where Timestamp >= ago(1d)
| where FileName == "svchost.exe"
| where ActionType startswith "Asr"
| extend ParsedFields = parse_json(AdditionalFields)
| extend Audit = tostring(ParsedFields.IsAudit)
| project Timestamp, DeviceName, ActionType, Audit, FileName, FolderPath,
InitiatingProcessParentFileName, InitiatingProcessFileName,
InitiatingProcessFolderPath, InitiatingProcessCommandLine// Blocks in the last 24 hours against each rule's daily average
let Baseline = DeviceEvents
| where Timestamp between (ago(15d) .. ago(1d))
| where ActionType startswith "Asr" and ActionType endswith "Blocked"
| summarize PerDay = count() / 14.0 by ActionType;
DeviceEvents
| where Timestamp > ago(1d)
| where ActionType startswith "Asr" and ActionType endswith "Blocked"
| summarize Today = count(), Devices = dcount(DeviceName) by ActionType
| join kind=leftouter Baseline on ActionType
| extend Ratio = round(Today / iff(isnull(PerDay), 1.0, PerDay), 1)
| project ActionType, Today, PerDay = round(PerDay, 1), Ratio, Devices
| order by Ratio desc// Users clicking through Warn mode
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType startswith "Asr" and ActionType endswith "WarnBypassed"
| summarize Bypasses = count(), Users = make_set(AccountName, 10)
by ActionType, DeviceName, FileName
| order by Bypasses desc// Onboarded Windows devices with no ASR events at all in 30 days:
// the rules may never have reached them
let Seen = DeviceEvents
| where Timestamp > ago(30d)
| where ActionType startswith "Asr"
| distinct DeviceId;
DeviceInfo
| where Timestamp > ago(1d)
| where OSPlatform startswith "Windows"
| summarize arg_max(Timestamp, DeviceName, OSPlatform) by DeviceId
| where DeviceId !in (Seen)
| project DeviceName, OSPlatform, LastSeen = TimestampAnd the behavior one rule exists to stop, for devices where that rule is still in Audit or off:
// Office spawning shells on devices: what the Office child rule exists for,
// worth watching wherever that rule is still in Audit or off
DeviceProcessEvents
| where Timestamp > ago(7d)
| where InitiatingProcessFileName in~ ("winword.exe", "excel.exe",
"powerpnt.exe", "onenote.exe", "msaccess.exe")
| where FileName in~ ("cmd.exe", "powershell.exe", "pwsh.exe", "mshta.exe",
"wscript.exe", "cscript.exe", "rundll32.exe", "regsvr32.exe")
| project Timestamp, DeviceName, InitiatingProcessFileName, FileName,
ProcessCommandLine, AccountName
| order by Timestamp descInvestigating an ASR hit
- Name the rule. The ActionType in advanced hunting, or the ID in event 1121 and 1122, against the GUID table. The rule tells you which behavior was stopped, which tells you what the attack would have been.
- Separate the two files. The report calls them the detected file and the source app; in hunting they are FileName and FolderPath, and the InitiatingProcess fields. Which file lands in which field depends on the rule, so check one of your own events for that rule before writing a detection on it.
- Audit or block. An audit event means it ran. An audit hit that looks malicious is an incident on a device the rule did not protect.
- Rebuild the chain. The process tree in the thirty minutes around the hit, and where the file came from, with the queries below.
- Check the spread. The same file or hash on other devices, against any rule.
- Decide. Legitimate: a per-rule exclusion for the exact file, or an Allow indicator, and a note of who asked for it. Malicious: isolate, collect, and run it as an incident; the ASR block was one control that worked, and the question is what else the attacker tried.
// The process tree around one ASR block: pick the device and time
let Hit = DeviceEvents
| where Timestamp > ago(7d)
| where ActionType == "AsrOfficeChildProcessBlocked"
| top 1 by Timestamp desc
| project DeviceId, HitTime = Timestamp;
DeviceProcessEvents
| where Timestamp > ago(7d)
| join kind=inner Hit on DeviceId
| where Timestamp between ((HitTime - 30m) .. (HitTime + 30m))
| project Timestamp, DeviceName, InitiatingProcessParentFileName,
InitiatingProcessFileName, FileName, ProcessCommandLine, AccountName
| order by Timestamp asc// Where the file an ASR rule named came from
DeviceFileEvents
| where Timestamp > ago(30d)
| where FileName =~ "invoice_0412.docm"
| project Timestamp, DeviceName, ActionType, FolderPath, SHA256,
FileOriginUrl, FileOriginReferrerUrl, InitiatingProcessFileName
| order by Timestamp asc// One blocked file: how many devices, which rules, which apps
DeviceEvents
| where Timestamp > ago(30d)
| where ActionType startswith "Asr"
| where SHA256 == "<sha256 from the hit>" or FileName =~ "<file name>"
| summarize Devices = dcount(DeviceName), Rules = make_set(ActionType),
Apps = make_set(InitiatingProcessFileName), First = min(Timestamp)
by FileName, SHA256Troubleshooting
| Symptom | Check |
|---|---|
| A rule does not block | Get-MpComputerStatus: AMRunningMode should be Normal, real-time protection on. Then the rule's mode: a rule left in Audit by a test or changed by a script is the common cause, which Microsoft names. |
| The mode on the device is not the one you set | Another source won: see the precedence table. The device page in the Defender portal has an Effective settings tab that shows the value and the source that set it. |
| A Group Policy rule never applies | Quotation marks, leading or trailing spaces, or extra characters in the GUID or value. Group Policy accepts none of them. |
| An Office rule does not fire | Office is installed outside Program Files: three Office rules are enforced only there. The code injection rule also needs Office restarted after a change. |
| Warn behaves like Block | The device is older than Windows 10 1809, or Defender is below platform 4.18.2008.9 or engine 1.1.17400.5, or the rule does not support Warn. Configuration Manager cannot set Warn at all. |
| The rule blocks but there is no alert | Check the EDR alert column for the rule: many rules never alert. Three raise alerts only at the High plus or Zero tolerance cloud protection levels; CloudBlockLevel in Get-MpPreference is 0 for default, 2 for High, 4 for High plus and 6 for Zero tolerance. |
| A rule reports compliant on a server but does nothing | Microsoft lists a known issue where ASR on Server versions is marked compliant without enforcement, with no fix date. Check the server's own events. |
| An exclusion has no effect | The rule may not honor that exclusion type: see the exclusions table. Or Disable local admin merge is on, which stops per-rule and local exclusions from applying. |
| Still wrong after all of that | Report false positives and negatives through the Microsoft Security Intelligence submission form, and collect diagnostics for a support case with the commands below. |
# The prerequisites, on the device
Get-MpComputerStatus |
Select-Object AMRunningMode, RealTimeProtectionEnabled, AMProductVersion, AMEngineVersion
Get-MpPreference | Select-Object MAPSReporting, CloudBlockLevelDiagnostics for a support case, from Microsoft's troubleshooting page: MpCmdRun writes MpSupportFiles.cab to C:\ProgramData\Microsoft\Windows Defender\Support; inside it, MPOperationalEvents.txt is the operational log, MPRegistry.txt the configuration and MPLog.txt the detail. The MDE Client Analyzer with -v collects verbose data; run it while you reproduce the problem.
"%ProgramFiles%\Windows Defender\MpCmdRun.exe" -GetFiles
C:\Work\tools\MDEClientAnalyzer\MDEClientAnalyzer.cmd -vGUID quick lookup
Sorted by GUID, for reading Get-MpPreference output, Group Policy values and event 1121.
| GUID | Rule | Audit action type | Block action type |
|---|---|---|---|
01443614-cd74-433a-b99e-2ecdc07bfc25 | Prevalence, age or trusted list | AsrUntrustedExecutableAudited | AsrUntrustedExecutableBlocked |
26190899-1602-49e8-8b27-eb1d0a1ce869 | Outlook child processes | AsrOfficeCommAppChildProcessAudited | AsrOfficeCommAppChildProcessBlocked |
33ddedf1-c6e0-47cb-833e-de6133960387 | Safe Mode reboot | AsrSafeModeRebootedAudited | AsrSafeModeRebootBlocked |
3b576869-a4ec-4529-8536-b80a7769e899 | Office writing executables | AsrExecutableOfficeContentAudited | AsrExecutableOfficeContentBlocked |
56a863a9-875e-4185-98a7-b882c64b5ce5 | Vulnerable signed drivers | AsrVulnerableSignedDriverAudited | AsrVulnerableSignedDriverBlocked |
5beb7efe-fd9a-4556-801d-275e5ffc04cc | Obfuscated scripts | AsrObfuscatedScriptAudited | AsrObfuscatedScriptBlocked |
75668c1f-73b5-4cf0-bb93-3ecf5cb7cc84 | Office code injection | AsrOfficeProcessInjectionAudited | AsrOfficeProcessInjectionBlocked |
7674ba52-37eb-4a4f-a9a1-f0f9a1619a2c | Adobe Reader child processes | AsrAdobeReaderChildProcessAudited | AsrAdobeReaderChildProcessBlocked |
92e97fa1-2edf-4476-bdd6-9dd0b4dddc7b | Win32 API calls from macros | AsrOfficeMacroWin32ApiCallsAudited | AsrOfficeMacroWin32ApiCallsBlocked |
9e6c4e1f-7d60-472f-ba1a-a39ef669e4b2 | LSASS credential theft | AsrLsassCredentialTheftAudited | AsrLsassCredentialTheftBlocked |
a8f5898e-1dc8-49a9-9878-85004b8a61e6 | Web shell creation on Exchange | None listed | None listed |
b2b3f03d-6a65-4f7b-a9c7-1c7ef74a9ba4 | Untrusted processes from USB | AsrUntrustedUsbProcessAudited | AsrUntrustedUsbProcessBlocked |
be9ba2d9-53ea-4cdc-84e5-9b1eeee46550 | Executable content from email | AsrExecutableEmailContentAudited | AsrExecutableEmailContentBlocked |
c0033c00-d16d-4114-a5a0-dc9b3a7d2ceb | Copied or impersonated system tools | AsrAbusedSystemToolAudited | AsrAbusedSystemToolBlocked |
c1db55ab-c21a-4637-bb3f-a12568109d35 | Advanced ransomware protection | AsrRansomwareAudited | AsrRansomwareBlocked |
d1e49aac-8f56-4280-b9ba-993a6d77406c | PsExec and WMI process creation | AsrPsexecWmiChildProcessAudited | AsrPsexecWmiChildProcessBlocked |
d3e037e1-3eb8-44c8-a917-57927947596d | Script launching downloads | AsrScriptExecutableDownloadAudited | AsrScriptExecutableDownloadBlocked |
d4f940ab-401b-4efc-aadc-ad5f3c50688a | Office child processes | AsrOfficeChildProcessAudited | AsrOfficeChildProcessBlocked |
e6db77e5-3df2-4cf1-b95a-636979351e5b | WMI event subscription persistence | AsrPersistenceThroughWmiAudited | AsrPersistenceThroughWmiBlocked |
From a rule list to a hardened estate
Endpoint Security Engineering takes attack surface reduction through design, rollout and measurement alongside antivirus, device and application control and EDR configuration on Defender for Endpoint and Intune.
Read the first module free →Weekly security engineering insights
Detection techniques, architecture patterns, and operational judgment, every Tuesday.
No spam. Unsubscribe anytime.