> For the complete documentation index, see [llms.txt](https://docs.expel.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.expel.io/workbench-setup/auto-remediations/block-bad-hashes/microsoft-defender-for-endpoint-block-bad-hashes.md).

# Microsoft Defender for Endpoint: Block Bad Hashes

*This guide is the first step of a larger process to enable auto remediations. After completing the steps on this page, you will be instructed to return to the* [*Enable an Auto Remediation in Workbench*](/workbench-setup/auto-remediations/enable-an-auto-remediation-in-workbench.md) *guide to finish your setup.*

## How It Works <a href="#h_01jgydp2j2h80jh6z0z91at9ne" id="h_01jgydp2j2h80jh6z0z91at9ne"></a>

If our SOC identifies a hash that must be blocked, Workbench completes the action automatically unless it is specifically called out as a "Never block" asset (these hashes must be added as context and then configured in Workbench; see [Step 3](#h_01jgyc8wpyhctwv9qstbsatmnq)).

## Prerequisites <a href="#h_01jh0vcwgakvzn6ss6mxtwcgy4" id="h_01jh0vcwgakvzn6ss6mxtwcgy4"></a>

* Your organization uses Microsoft Defender Antivirus in Active Mode and Cloud-based protection is enabled.
* The Anti-malware client version must be 4.18.1901.x or later.
* Devices are on Windows 10, version 1703 or later, or Windows Server 2016 and 2019.

## Step 1: Allow Appropriate Permissions in Your EDR Console <a href="#h_01jh0w8t5faasa8yvezv0vv17v" id="h_01jh0w8t5faasa8yvezv0vv17v"></a>

1. Make sure you assign all API permissions in the [Microsoft Defender for Endpoint Setup for Workbench](/connect-your-technology/l-p-integrations/microsoft/microsoft-defender-for-endpoint-setup-for-workbench.md) guide.
2. Select **Settings > Endpoints > Advanced features**.
3. Turn on **Allow or block file**.<br>

   <div align="left"><figure><img src="/files/KY3t3WAidB0pTmIn11GL" alt="The Microsoft Defender UI indicates Allow of block file is enabled." width="375"><figcaption></figcaption></figure></div>
4. Select **Save preferences**.

## Step 2: Update API Permissions <a href="#h_01hx9ee0ykrs3z64h169bz8e1h" id="h_01hx9ee0ykrs3z64h169bz8e1h"></a>

### **Option 1: Enable the Defender for Enterprise Application** <a href="#h_01jh1h31m7t91jp4e4cgfm4ngj" id="h_01jh1h31m7t91jp4e4cgfm4ngj"></a>

1. Select **Grant admin consent** in the **Expel Defender for Endpoint Integration > API permissions** tab and consent to the new API permissions.

### **Option 2: Create a Custom Microsoft Entra ID Application** <a href="#h_01jh1h21c3s2146jjk9nneywy3" id="h_01jh1h21c3s2146jjk9nneywy3"></a>

1. Follow the previous API permissions steps.
2. Add the following WindowsDefenderATP permissions:
   * Ti.ReadWrite
   * Ti.ReadWrite.All
3. Grant admin consent.

   <div align="left"><figure><img src="/files/PlOnH2shamGrR8a8CAR8" alt="Microsoft Defender UI indicates Ti.ReadWrite and Ti.ReadWrite.All permissions are Granted for Expel." width="375"><figcaption></figcaption></figure></div>

## Step 3: Update Your Context <a href="#h_01jgyc8wpyhctwv9qstbsatmnq" id="h_01jgyc8wpyhctwv9qstbsatmnq"></a>

**If you do not want to specify any hashes for a "do not block" list, skip to** [**Step 4**](#h_01jgycgywj4m9tc7j443dvsmf1)**.**

Working with your Customer Success Manager, add any hashes that should be on the "do not block" list as [context](https://support.expel.io/hc/en-us/articles/34624474608275-Expel-Terminology#h_01JAR4HC55JYAWVBVT7XTXP850) for your environment. You will then be able to select those hashes as "Never block" assets when you enable the auto remediation in Workbench.&#x20;

{% hint style="info" %}
If our SOC identifies a hash that must be blocked, any hashes added as "Never block" assets are assigned to you as actions rather than being blocked automatically.
{% endhint %}

## Step 4: Return to the Main Setup Guide <a href="#h_01jgycgywj4m9tc7j443dvsmf1" id="h_01jgycgywj4m9tc7j443dvsmf1"></a>

Your Microsoft Defender for Endpoint device is now ready for the Block Bad Hashes auto remediation. You should now do one of the following:

* **If you do not need to set up any other devices for this auto remediation**, you can return to the [Enable an Auto Remediation in Workbench](/workbench-setup/auto-remediations/enable-an-auto-remediation-in-workbench.md) guide to finish Step 2 of the process.
* **If you need to set up additional devices for this auto remediation, or wish to use this device with multiple auto remediations**, be sure to [complete those setup guides as well](/workbench-setup/auto-remediations.md) before returning to the [Enable an Auto Remediation in Workbench](/workbench-setup/auto-remediations/enable-an-auto-remediation-in-workbench.md) guide to finish Step 2 of the process. *Make sure to follow the setup guide that is specific to your auto remediation, as device setup instructions are unique to each auto remediation and device.*


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.expel.io/workbench-setup/auto-remediations/block-bad-hashes/microsoft-defender-for-endpoint-block-bad-hashes.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
