In this section

Attack Surface Reduction Rules: Audit Mode, Pilot Blocks and Exclusions in Defender for Endpoint

Module 0

Introduction

Attack surface reduction rules refuse specific behaviors that attacks depend on and ordinary software rarely needs: an Office application starting a child process, a script launching something it downloaded, a process reading LSASS's memory.

Lesson 0.1's intrusion used all three, and on that laptop the rules saw each step and stopped none, because they were in audit mode. This lesson is about getting from audit to block, which is where ASR either protects an estate or breaks it.

Every rule has two modes in practice. In audit it records what it would have refused and refuses nothing. In block it refuses. The engineering is the passage between them: reading the audit data for legitimate software that would break, dealing with it, and then blocking on a small group before blocking everywhere.

This estate ran that passage for three rules from 9 March, and its records show what went right and what the audit data failed to say. Nothing about it is unusual, which is what makes it worth reading closely.

1. Audit on every deviceeach rule records what it would have refused2. Read the audit datawho triggers each rule, and is any of it legitimate work3. Exclude or fixthe legitimate triggers, scoped as narrowly as the tool allows4. Block on a pilota small group, with someone watching the blocks5. Block everywherering by ring, the audit data kept as the record

The audit-first deployment Module 4 teaches, as this estate ran it.

The figure is the sequence Module 4 teaches in full. It is slower than switching rules to block, and much faster than recovering from a rollout that stopped the business on its first morning. Each section below reads one step of it in the estate's records, and the last section sets out what Module 4 builds on it.

01

What Audit Recorded

Five rules watching, three of them then blocking

Every ASR record has an action type that names the rule and the mode, which Microsoft lists for each rule: AsrOfficeChildProcessAudited and AsrOfficeChildProcessBlocked for the Office child-process rule, and so on. Counting the estate's records by action type gives the whole picture at once:

DeviceEvents
| where ActionType startswith 'Asr'
| summarize Events = count(), Devices = dcount(DeviceName) by ActionType
| order by ActionType asc

Run, the count by action type gives eight lines, five of them audit and three block:

ActionType                          Events  Devices
----------------------------------  ------  -------
AsrExecutableEmailContentAudited    25      12
AsrLsassCredentialTheftAudited      20      13
AsrLsassCredentialTheftBlocked      4       1
AsrOfficeChildProcessAudited        25      14
AsrOfficeChildProcessBlocked        8       2
AsrPsexecWmiChildProcessAudited     28      13
AsrScriptExecutableDownloadAudited  23      11
AsrScriptExecutableDownloadBlocked  1       1

Five rules recorded 121 audit events between them, each on eleven to fourteen laptops: the email content rule, the LSASS rule, the Office child-process rule, the PsExec and WMI rule, and the script download rule. Three of them also have block records, on one or two devices each.

Those are the pilot: from 9 March the Office, script download and LSASS rules block on four laptops, NE-FOSTER-LT, NE-DAVIS-LT, NE-ZHANG-LT and NE-KHAN-LT, and keep auditing everywhere else. The four were chosen because none of them had audit records for those three rules after 9 March, which on the face of it made them safe to block first. The next section shows why that reasoning was not enough.

Read the audit counts for what they say about the cost of blocking. Each audit record is a moment when, in block mode, something would have been refused. Some of those moments are attacks, and some are somebody's work.

Two dozen records a month across fourteen laptops is a small number, small enough that every record can be read before anything blocks, and that is the advantage of starting in audit: the data is a list of every decision block mode would have taken, available before it takes any of them.

The disadvantage of audit is that it costs nothing to leave on. An estate that turns rules on in audit and never reads the data has the worst of both: no protection, and a reassuring line in a compliance report that says the rules are deployed.

The first query on this page is the test for that. If an estate has audit records that nobody has read and no block records anywhere, its ASR rules are a list of attacks it watched happen.

The rest of this lesson reads that list the way Module 4 teaches it to be read, rule by rule, asking of each trigger whether it is legitimate, and then checks what the pilot's blocks found that the reading did not.

02

Audit Data That Did Not Warn

The Office rule, and the child it did not name

The Office child-process rule is the one that would have stopped lesson 0.1's intrusion at its first step. Its audit records, grouped by the Office application that triggered it and the child process it would have refused:

DeviceEvents
| where ActionType == 'AsrOfficeChildProcessAudited'
| summarize Events = count() by Office = InitiatingProcessFileName,
    Child = iif(isempty(FileName), '(not recorded)', FileName)

Grouped that way, the audit records come down to two lines:

Office       Child           Events
-----------  --------------  ------
EXCEL.EXE    (not recorded)  23
WINWORD.EXE  (not recorded)  2

Excel triggered the rule 23 times and Word twice, and in none of the estate's audit records is the child process recorded. The Word records include lesson 0.1's intrusion, which the process events show was Word starting PowerShell. The Excel records are something Excel does routinely, on laptops across the estate, and the audit data alone does not say what.

On the two Sales laptops that later joined the pilot, the rule had fired in audit before it ever blocked:

DeviceEvents
| where ActionType == 'AsrOfficeChildProcessAudited'
| where DeviceName in ('NE-FOSTER-LT', 'NE-DAVIS-LT')
| project Day = format_datetime(Timestamp, 'yyyy-MM-dd'), DeviceName,
    Office = InitiatingProcessFileName
| order by Day asc

On those two laptops, the audit records before the pilot read:

Day         DeviceName    Office
----------  ------------  ---------
2026-02-18  NE-FOSTER-LT  EXCEL.EXE
2026-02-20  NE-FOSTER-LT  EXCEL.EXE
2026-02-26  NE-FOSTER-LT  EXCEL.EXE
2026-03-02  NE-DAVIS-LT   EXCEL.EXE

Four audit records, all Excel, all before 9 March. Choosing pilot devices by their recent audit silence, as this estate did, picked exactly the laptops where the rule's last warnings were weeks old and easy to overlook. They were the warning, and they were not followed up, because without a child process name there was nothing to write an exclusion for.

The right move at this step was to find out what Excel was starting, from the process events for the same moments, before the rule blocked. That is Module 4's lesson on writing an exclusion from audit data: the audit record says when and on which device, and the process tree says what.

The gap is specific to this estate's records, but the lesson generalizes. Audit data is only as good as the fields it carries, and an audit phase that cannot answer what a rule would have refused for each record is not finished.

The fix is a second query joining the audit record to the process event at the same moment on the same device, which turns an anonymous record into a named child process. Module 4 builds that join as a standing query that every audit review starts from.

03

What Block Mode Broke

The pilot's first week

From 9 March the three rules blocked on the pilot laptops. Every block, grouped by rule, device, the file the rule acted on and the process that started it:

DeviceEvents
| where ActionType startswith 'Asr' and ActionType endswith 'Blocked'
| extend Rule = extract('Asr(.+)Blocked', 1, ActionType)
| summarize Blocks = count(),
    FirstBlock = format_datetime(min(Timestamp), 'MM-dd HH:mm')
    by Rule, DeviceName, Target = FileName
| order by FirstBlock asc

The pilot's blocks, earliest first, come down to four lines:

Rule                      DeviceName    Target            Blocks  FirstBlock
------------------------  ------------  ----------------  ------  -----------
LsassCredentialTheft      NE-KHAN-LT    lsass.exe         4       03-09 07:00
OfficeChildProcess        NE-FOSTER-LT  QuoteGen.exe      5       03-09 09:14
OfficeChildProcess        NE-DAVIS-LT   QuoteGen.exe      3       03-09 13:47
ScriptExecutableDownload  NE-ZHANG-LT   invoice_0310.exe  1       03-10 16:12

Read with the process that started each one, the four lines resolve into three findings and one success:

What the pilot found that audit did not say

Pilot, from 9 March

QuoteGen.exe

blocked 8 times on two Sales laptops: the quoting add-in Excel starts

monagent.exe

blocked 4 times on NE-KHAN-LT: the IT monitoring agent reading LSASS

invoice_0310.exe

blocked once on NE-ZHANG-LT: a script launching a download, the rule doing its job

Why audit missed it

Office records name no child; monagent.exe never appears in audit

Two of the four lines are legitimate software. QuoteGen.exe is the Sales team's quoting add-in, which Excel starts when a user builds a quote: it was blocked 8 times on the two Sales laptops in the first week, and every block was a salesperson unable to produce a quote. monagent.exe is the IT monitoring agent, which reads LSASS every morning at 07:00: it was blocked 4 times on NE-KHAN-LT.

Neither name appears in any audit record on the estate, so the audit phase gave no warning of either.

The third line is the rule doing exactly its job: a script started by wscript.exe launching invoice_0310.exe from a Downloads folder, refused before it ran. One real block and two pieces of broken software is a typical first week, and it is the reason the pilot is small and watched.

Four laptops with a named owner reading the blocks each morning is a manageable cost. The whole estate at once would have been every salesperson unable to quote and every monitoring dashboard missing data on the same day, with no way to tell the real block from the breakage in the noise.

Notice also when each problem showed itself. The monitoring agent was blocked at 07:00 on the first morning, before anyone was at work, so the first person to notice was whoever reads the monitoring dashboard.

The quoting add-in was blocked at 09:14, the first time a salesperson built a quote. A pilot's owner should expect breakage to arrive on the schedule of the work it breaks, and check the blocks at the start of each day rather than waiting for a ticket.

The script download block, by contrast, arrived in the afternoon of the second day and needed nothing from anyone: it is the kind of block a pilot hopes to see, and the reason the other two are worth the trouble.

04

The Attacks Hidden in the Audit Data

The LSASS rule's noise, and its signal

Audit data is not only a list of what would break. It is also a record of attacks the rule saw and let through. The LSASS rule's audit records, grouped by the process that read LSASS:

DeviceEvents
| where ActionType == 'AsrLsassCredentialTheftAudited'
| summarize Events = count(), Devices = dcount(DeviceName)
    by Initiator = InitiatingProcessFileName
| order by Events desc

Two processes account for every LSASS audit record on the estate:

Initiator     Events  Devices
------------  ------  -------
taskmgr.exe   18      12
rundll32.exe  2       2

Task Manager accounts for 18 records on 12 laptops: users opening it, which reads process details including LSASS's. That is the rule's normal noise, and it is the reason this rule audits loudly on most estates. The other two records are rundll32.exe:

DeviceEvents
| where ActionType == 'AsrLsassCredentialTheftAudited'
| where InitiatingProcessFileName == 'rundll32.exe'
| project Time = format_datetime(Timestamp, 'yyyy-MM-dd HH:mm'), DeviceName

Two rundll32.exe reads of LSASS, on two different laptops a day apart:

Time              DeviceName
----------------  --------------
2026-03-11 09:14  NE-LEWIS-LT
2026-03-10 10:36  NE-THOMPSON-LT

The first is lesson 0.1's intrusion on NE-THOMPSON-LT, the comsvcs.dll dump.

The second is on NE-LEWIS-LT the next morning, and is part of a different intrusion in the estate's records, against Active Directory. Both were recorded by the rule in audit, both were let through, and both sat in a list of twenty records where eighteen were Task Manager. Neither was hidden by anything clever; they were hidden by being in a list nobody read with an attacker's eye.

This is the strongest argument for moving the LSASS rule to block quickly. Its legitimate triggers are few and recognizable, its noise is one process, and the cost of leaving it in audit is visible in this estate twice.

Module 4 covers the rules whose audit data needs weeks of reading and the rules, like this one, where the data says to block as soon as the known exceptions are dealt with.

There is a second lesson in the LSASS records, about who reads audit data. An engineer reading it for breakage looks for legitimate software and sees Task Manager. An analyst reading it for attacks looks for the unusual initiator and sees rundll32.exe twice. Both readings are needed, and an audit phase that only does the first throws away the second.

On this estate the analyst's reading would have found the 10 March intrusion from the audit data alone, the same day. It would also have found the second, the next morning, on a laptop in a different department, which is the first sign that two intrusions, not one, were under way.

05

The Exclusion Each Rule Needs

Narrow, scoped, and owned

The pilot leaves two pieces of legitimate software that the rules break, and each needs a decision before the rules block more widely. The decision is not whether to protect the estate; it is how narrowly to make room for the software:

The two decisions the pilot left

Before the next ring

QuoteGen.exe

exact path, Office rule only, Sales group; or an add-in that stays inside Excel

monagent.exe

ask the vendor first; exact path on the LSASS rule only if it must read LSASS

Never

exclude EXCEL.EXE, or return the rule to audit for the group

Always

an owner, a review date, and a path users cannot write to

In more detail, the reasoning for each:

  • For QuoteGen.exe, an exclusion for the add-in's exact path, applied only to the Office child-process rule if the management tool supports per-rule exclusions, and to the Sales group that uses it. Better still, a version of the add-in that runs inside Excel rather than starting a separate process, which removes the need for an exclusion at all.
  • For monagent.exe, an exclusion for the agent's path on the LSASS rule, after confirming with the vendor that the agent needs to read LSASS at all. A monitoring agent that only needs inventory data may have a setting that stops it touching LSASS, which is a better fix than an exclusion. The question for the vendor is specific: which of the agent's features reads LSASS, and can it be turned off without losing the data the IT team uses.

The answer to avoid is the one that is easiest under pressure: taking the rule back to audit for the affected group, or excluding the parent process.

Excluding EXCEL.EXE from the Office rule would let every Excel document start any process, which is the attack the rule exists to stop. Returning the rule to audit for Sales would leave the laptops of the people most likely to open a quote-themed attachment protected by nothing.

Every exclusion also needs an owner and a review date, for the reason lesson 0.3 gave: an exclusion is a place an attacker can stand. The review asks whether the software still needs it: an add-in that is upgraded to run inside Excel, or a monitoring agent reconfigured to stop reading LSASS, makes its exclusion an unnecessary hole, and only a review finds that out.

The path of an excluded executable has to be one a user cannot write to, or the exclusion becomes a way round the rule for anything copied there. An add-in installed under Program Files is writable only by administrators, which is the property that makes its path safe to exclude; the same add-in copied to a user's profile would not be.

06

What Module 4 Builds On It

Attack surface reduction in full

Module 4 starts with what the rules actually block, then the audit-first deployment this lesson followed, and writing exclusions from audit data. It works through the standard protection set every estate should block, the rules that need careful audit reading, and the rules most estates never enable.

It covers the gap between the mode a policy sets and the mode a device actually enforces, standing arrangements for line-of-business software like QuoteGen, controlled folder access, and keeping the posture true over time. The gap between set and enforced mode matters for everything above: a pilot is only a pilot if the four laptops actually enforce block, and the block records are the proof that they do.

What Module 4 builds

Module 4

4.1 to 4.3

what ASR rules actually block, the audit-first deployment, writing an exclusion from audit data

4.4 to 4.6

the standard protection set, the rules that need the audit, the rules most estates never enable

4.7 to 4.9

the mode you set against the mode you get, line-of-business software, controlled folder access

4.10 to 4.11

keeping the posture true over time, and a deployment in five steps and three decisions

It ends with a deployment run in five steps with three decisions along the way, which is this lesson's pilot taken through to the whole estate. Each step uses records like the ones above to decide whether to go on.

The decisions in that case are the ones this lesson met in small: what to do with an add-in a rule breaks, when to stop a ring, and which rules to leave in audit for longer.

The habits to carry into it are the ones this lesson used. Count the audit records per rule before deciding anything about any of them. Find out what each trigger was from the process events when the audit record does not say. Read the audit data for attacks as well as for breakage, because the attacks are in it whether anyone looks or not.

Pilot on a small group with an owner watching, and expect the breakage to arrive on the schedule of the work it breaks: the first morning, the first quote, the first monthly report. And make room for legitimate software with the narrowest exclusion that works, never by excluding the parent process or returning the rule to audit.

One more is worth holding on to from the LSASS rule. Audit data has two readers, the engineer looking for breakage and the analyst looking for attacks, and an audit phase that only serves the first discards evidence the estate already paid for.

Module 4 builds the review so both readings happen every week, and so a rule moves to block as soon as its data says it is safe rather than when somebody remembers it.

Do

Practice

Sort the pilot's blocks
prepared evidence

The prepared evidence below is every block the pilot produced, one row per rule, device, target and initiating process, with the number of blocks and the first.

Decide which rows are the rule protecting the estate, which are legitimate software it broke, and what should happen before the Office rule blocks for Sales again. Each answer comes with its reasoning, so check it against the rows rather than only the choice.

The Initiator column carries most of the answer: a rule acting on the right target can still be breaking the wrong program, and the program that triggered it is what tells you which.

For the third question, think about what each wrong answer would cost on the day the next quote-themed attachment arrives, which is the test every exclusion has to pass. Then check your exclusion against the rows once more: it should make the QuoteGen and monagent lines disappear and leave the invoice line exactly as it is.

Then run the Office rule query on this page against the process events instead: find what EXCEL.EXE started on NE-FOSTER-LT at the times of its audit records before 9 March. If the add-in appears there, that is the follow-up the audit phase needed. Write the exclusion you would ask for in one line: the path, the rule and the group, with the owner who will review it.

ASR rules start in audit, and audit data is a list of every decision block mode would take. Read it per rule, find what each trigger was when the record does not say, and expect it to contain attacks as well as legitimate software. Pilot the block on a small, watched group, and make room for what breaks with the narrowest exclusion that works.

The next lesson moves from ASR to antivirus, and asks how to tell an engine that detected something from one that stopped it, which is the same distinction between recording and preventing that this lesson drew for the rules.