You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/sentinel/playbook-triggers-actions.md
+17-4Lines changed: 17 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,13 +31,13 @@ For the complete specification of the Microsoft Sentinel connector, see the [Log
31
31
32
32
## Microsoft Sentinel triggers summary
33
33
34
-
Though the Microsoft Sentinel connector can be used in a variety of ways, the connector's components can be divided into 2 flows, each triggered by a different Microsoft Sentinel occurrence:
34
+
Though the Microsoft Sentinel connector can be used in a variety of ways, the connector's components can be divided into three flows, each triggered by a different Microsoft Sentinel occurrence:
35
35
36
36
| Trigger (full name in Logic Apps Designer) | When to use it | Known limitations
| **Microsoft Sentinel incident (Preview)** | Recommended for most incident automation scenarios.<br><br>The playbook receives incident objects, including entities and alerts. Using this trigger allows the playbook to be attached to an **Automation rule**, so it can be triggered when an incident is created (and now, updated as well) in Microsoft Sentinel, and all the [benefits of automation rules](./automate-incident-handling-with-automation-rules.md) can be applied to the incident. | Playbooks with this trigger do not support alert grouping, meaning they will receive only the first alert sent with each incident.
39
39
|**Microsoft Sentinel alert (Preview)**| Advisable for playbooks that need to be run on alerts manually from the Microsoft Sentinel portal, or for **scheduled** analytics rules that don't generate incidents for their alerts. | This trigger cannot be used to automate responses for alerts generated by **Microsoft security** analytics rules.<br><br>Playbooks using this trigger cannot be called by **automation rules**. |
40
-
|**Microsoft Sentinel entity (Preview)**| To be used for playbooks that need to be run manually on specific entities from an investigation or threat hunting context, or in scenarios that a SOC does not want to automate. | Playbooks using this trigger cannot be called by **automation rules**. |
40
+
|**Microsoft Sentinel entity (Preview)**| To be used for playbooks that need to be run manually on specific entities from an investigation or threat hunting context. | Playbooks using this trigger cannot be called by **automation rules**. |
41
41
42
42
The schemas used by these flows are not identical. The recommended practice is to use the **Microsoft Sentinel incident trigger** flow, which is applicable to most scenarios.
43
43
@@ -72,7 +72,7 @@ The **Incident** object received from **Microsoft Sentinel incident** includes t
72
72
|**Entities - Get \<*entity type*\>**| In playbooks that work on a specific entity type (**IP**, **Account**, **Host**, **URL** or **FileHash**) which is known at playbook creation time, and you need to be able to parse it and work on its unique fields. |
73
73
|
74
74
75
-
## Work with incidents - Usage Examples
75
+
## Work with incidents - usage examples
76
76
77
77
> [!TIP]
78
78
> The actions **Update Incident** and **Add a Comment to Incident** require the **Incident ARM ID**.
@@ -109,7 +109,20 @@ Basic playbook to send incident details over mail:
> If a playbook created with the **Entity trigger** makes use of the **Incident ARM ID** field, then in the event that this playbook is triggered in a context unconnected to an incident, this field will be populated with a null value. The playbook will still run, but any actions that refer to the incident ID will be skipped.
116
+
>
117
+
> Examples of this situation might be if the playbook was run from an entity page accessed from the **Entity behavior** page, or as the result of a hunting query.
118
+
119
+
### Usage example - disable a user
120
+
121
+
- Playbook is triggered by **Microsoft Sentinel Entity**
122
+
123
+
:::image type="content" source="media/playbook-triggers-actions/entity-trigger-actions.png" alt-text="Screenshot showing actions to take in an entity-trigger playbook to disable a user.":::
124
+
125
+
### Work with specific Entity types
113
126
114
127
The **Entities** dynamic field is an array of JSON objects, each of which represents an entity. Each entity type has its own schema, depending on its unique properties.
Copy file name to clipboardExpand all lines: articles/sentinel/tutorial-respond-threats-playbook.md
+35-11Lines changed: 35 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,8 +10,6 @@ ms.author: yelevin
10
10
11
11
# Tutorial: Use playbooks with automation rules in Microsoft Sentinel
12
12
13
-
[!INCLUDE [Banner for top of topics](./includes/banner.md)]
14
-
15
13
This tutorial shows you how to use playbooks together with automation rules to automate your incident response and remediate security threats detected by Microsoft Sentinel. When you complete this tutorial you will be able to:
16
14
17
15
> [!div class="checklist"]
@@ -76,16 +74,13 @@ Follow these steps to create a new playbook in Microsoft Sentinel:
76
74
77
75
1. From the top menu, select **Create**.
78
76
79
-
1. The drop-down menu that appears under **Create** gives you three choices for creating playbooks:
77
+
1. The drop-down menu that appears under **Create** gives you four choices for creating playbooks:
80
78
81
79
1. If you're creating a **Standard** playbook (the new kind - see [Logic app types](automate-responses-with-playbooks.md#logic-app-types)), select **Blank playbook** and then follow the steps in the **Logic Apps Standard** tab below.
82
80
83
81
1. If you're creating a **Consumption** playbook (the original, classic kind), then, depending on which trigger you want to use, select either **Playbook with incident trigger**, **Playbook with alert trigger**, or **Playbook with entity trigger**. Then, continue following the steps in the **Logic Apps Consumption** tab below.
84
82
85
-
> [!NOTE]
86
-
> Remember that only playbooks based on the **incident trigger** can be called by automation rules. Playbooks based on the **alert trigger** must be defined to run directly in [analytics rules](detect-threats-custom.md#set-automated-responses-and-create-the-rule). Both types can also be run manually.
87
-
>
88
-
> For more about which trigger to use, see [**Use triggers and actions in Microsoft Sentinel playbooks**](playbook-triggers-actions.md)
83
+
For more about which trigger to use, see [**Use triggers and actions in Microsoft Sentinel playbooks**](playbook-triggers-actions.md).
89
84
90
85
# [Logic Apps Consumption](#tab/LAC)
91
86
### Prepare the playbook and Logic App
@@ -229,9 +224,13 @@ Now you can define what happens when you call the playbook. You can add actions,
229
224
230
225
In every one of these steps, clicking on any field displays a panel with two menus: **Dynamic content** and **Expression**. From the **Dynamic content** menu, you can add references to the attributes of the alert or incident that was passed to the playbook, including the values and attributes of all the [mapped entities](map-data-fields-to-entities.md) and [custom details](surface-custom-details-in-alerts.md) contained in the alert or incident. From the **Expression** menu, you can choose from a large library of functions to add additional logic to your steps.
This screenshot shows the actions and conditions you would add in creating the playbook described in the example at the beginning of this document. Learn more about [adding actions to your playbooks](playbook-triggers-actions.md).
228
+
229
+
:::image type="content" source="./media/tutorial-respond-threats-playbook/logic-app.png" alt-text="Screenshot showing the Logic App designer with an incident trigger workflow.":::
230
+
231
+
See [**Use triggers and actions in Microsoft Sentinel playbooks**](playbook-triggers-actions.md) for details about actions you can add to playbooks for different purposes.
233
232
234
-
This screenshot shows the actions and conditions you would add in creating the playbook described in the example at the beginning of this document. The only difference is that in the playbook shown here, you are using the **alert trigger** instead of the **incident trigger**. This means that you'll call this playbook from an analytics rule directly, not from an automation rule. Both ways of calling a playbook will be described below.
233
+
In particular, note this important information about [**working with playbooks based on the entity trigger**](playbook-triggers-actions.md#work-with-entities).
235
234
236
235
## Automate threat responses
237
236
@@ -245,11 +244,11 @@ To create an automation rule:
245
244
246
245
1. From the **Automation** blade in the Microsoft Sentinel navigation menu, select **Create** from the top menu and then **Add new rule**.
247
246
248
-
:::image type="content" source="./media/tutorial-respond-threats-playbook/add-new-rule.png" alt-text="Add a new rule":::
247
+
:::image type="content" source="./media/tutorial-respond-threats-playbook/add-new-rule.png" alt-text="Screenshot showing how to add a new automation rule.":::
249
248
250
249
1. The **Create new automation rule** panel opens. Enter a name for your rule.
251
250
252
-
:::image type="content" source="./media/tutorial-respond-threats-playbook/create-automation-rule.png" alt-text="Create an automation rule":::
251
+
:::image type="content" source="./media/tutorial-respond-threats-playbook/create-automation-rule.png" alt-text="Screenshot showing the automation rule creation wizard.":::
253
252
254
253
1. If you want the automation rule to take effect only on certain analytics rules, specify which ones by modifying the **If Analytics rule name** condition.
255
254
@@ -349,6 +348,31 @@ You can see the run history for playbooks on an alert by selecting the **Runs**
349
348
350
349
You can see the run history for playbooks on an incident by selecting the **Runs** tab on the **Run playbook on incident** panel. It might take a few seconds for any just-completed run to appear in the list. Selecting a specific run will open the full run log in Logic Apps.
351
350
351
+
### Run a playbook manually on an entity
352
+
353
+
1. Select an entity in one of the following ways, depending on your originating context:
354
+
355
+
**If you're in an incident's details page:**
356
+
1. Select the incident's **Entities** tab.
357
+
1. Find an entity from the list (don't select it).
358
+
1. Select the **Run playbook (Preview)** link at the end of its line in the list.
359
+
If you selected the entity and entered its entity page, select the **Run playbook (Preview)** button in the left-hand panel.
360
+
361
+
**If you're in the Investigation graph:**
362
+
1. Select an entity in the graph.
363
+
1. Select the **Run playbook (Preview)** button in the entity side panel.
364
+
For some entity types, you may have to select the **Entity actions** button and from the resulting menu select **Run playbook (Preview)**.
365
+
366
+
**If you're proactively hunting for threats:**
367
+
1. From the **Entity behavior** screen, select an entity from the lists on the page, or search for and select another entity.
368
+
1. In the [entity page](entity-pages.md), select the **Run playbook (Preview)** button in the left-hand panel.
369
+
370
+
1. Regardless of the context you came from, the instructions above will all open the **Run playbook on *\<entity type>*** panel. You'll see a list of all playbooks that you have access to that were configured with the **Microsoft Sentinel Entity** Logic Apps trigger for the selected entity type.
371
+
372
+
1. Select **Run** on the line of a specific playbook to run it immediately.
373
+
374
+
You can see the run history for playbooks on a given entity by selecting the **Runs** tab on the **Run playbook on *\<entity type>*** panel. It might take a few seconds for any just-completed run to appear in the list. Selecting a specific run will open the full run log in Logic Apps.
375
+
352
376
## Next steps
353
377
354
378
In this tutorial, you learned how to use playbooks and automation rules in Microsoft Sentinel to respond to threats.
0 commit comments