|
1 | 1 | ---
|
2 |
| -title: Secure Azure AD B2C with Microsoft Sentinel |
| 2 | +title: Configure security analytics for Azure Active Directory B2C data with Microsoft Sentinel |
3 | 3 | titleSuffix: Azure AD B2C
|
4 |
| -description: In this tutorial, you use Microsoft Sentinel to perform security analytics for Azure Active Directory B2C data. |
| 4 | +description: Use Microsoft Sentinel to perform security analytics for Azure Active Directory B2C data. |
5 | 5 | services: active-directory-b2c
|
6 | 6 | author: gargi-sinha
|
7 |
| -manager: CelesteDG |
| 7 | +manager: martinco |
8 | 8 | ms.reviewer: kengaderdus
|
9 |
| - |
10 | 9 | ms.service: active-directory
|
11 | 10 | ms.workload: identity
|
12 | 11 | ms.topic: tutorial
|
13 |
| -ms.date: 08/17/2021 |
| 12 | +ms.date: 03/06/2023 |
14 | 13 | ms.author: gasinh
|
15 | 14 | ms.subservice: B2C
|
16 |
| -#Customer intent: As an IT professional, I want to gather logs and audit data by using Microsoft Sentinel and Azure Monitor so that I can secure my applications that use Azure Active Directory B2C. |
| 15 | +#Customer intent: As an IT professional, I want to gather logs and audit data using Microsoft Sentinel and Azure Monitor to secure applications that use Azure Active Directory B2C. |
17 | 16 | ---
|
18 | 17 |
|
19 | 18 | # Tutorial: Configure security analytics for Azure Active Directory B2C data with Microsoft Sentinel
|
20 | 19 |
|
21 |
| -You can further secure your Azure Active Directory B2C (Azure AD B2C) environment by routing logs and audit information to Microsoft Sentinel. Microsoft Sentinel is a cloud-native SIEM (security information and event management) and SOAR (security orchestration, automation, and response) solution. Microsoft Sentinel provides alert detection, threat visibility, proactive hunting, and threat response for Azure AD B2C. |
| 20 | +Increase the security of your Azure Active Directory B2C (Azure AD B2C) environment by routing logs and audit information to Microsoft Sentinel. The scalable Microsoft Sentinel is a cloud-native, security information and event management (SIEM) and security orchestration, automation, and response (SOAR) solution. Use the solution for alert detection, threat visibility, proactive hunting, and threat response for Azure AD B2C. |
| 21 | + |
| 22 | +Learn more: |
22 | 23 |
|
23 |
| -By using Microsoft Sentinel with Azure AD B2C, you can: |
| 24 | +* [What is Microsoft Sentinel?](../sentinel/overview.md) |
| 25 | +* [What is SOAR?](https://www.microsoft.com/security/business/security-101/what-is-soar) |
24 | 26 |
|
25 |
| -- Detect previously undetected threats and minimize false positives by using Microsoft's analytics and threat intelligence. |
26 |
| -- Investigate threats with AI. Hunt for suspicious activities at scale, and tap into years of cybersecurity-related work at Microsoft. |
27 |
| -- Respond to incidents rapidly with built-in orchestration and automation of common tasks. |
28 |
| -- Meet security and compliance requirements for your organization. |
| 27 | +More uses for Microsoft Sentinel, with Azure AD B2C, are: |
29 | 28 |
|
30 |
| -In this tutorial, you'll learn how to: |
| 29 | +* Detect previously undetected threats and minimize false positives with analytics and threat intelligence features |
| 30 | +* Investigate threats with artificial intelligence (AI) |
| 31 | + * Hunt for suspicious activities at scale, and benefit from the experience of years of cybersecurity work at Microsoft |
| 32 | +* Respond to incidents rapidly with common task orchestration and automation |
| 33 | +* Meet your organization's security and compliance requirements |
31 | 34 |
|
32 |
| -> [!div class="checklist"] |
33 |
| -> * Transfer Azure AD B2C logs to a Log Analytics workspace. |
34 |
| -> * Enable Microsoft Sentinel in a Log Analytics workspace. |
35 |
| -> * Create a sample rule in Microsoft Sentinel that will trigger an incident. |
36 |
| -> * Configure an automated response. |
| 35 | +In this tutorial, learn how to: |
| 36 | + |
| 37 | +* Transfer Azure AD B2C logs to a Log Analytics workspace |
| 38 | +* Enable Microsoft Sentinel in a Log Analytics workspace |
| 39 | +* Create a sample rule in Microsoft Sentinel to trigger an incident |
| 40 | +* Configure an automated response |
37 | 41 |
|
38 | 42 | ## Configure Azure AD B2C with Azure Monitor Log Analytics
|
39 | 43 |
|
40 |
| -To define where logs and metrics for a resource should be sent, enable **Diagnostic settings** in Azure AD within your Azure AD B2C tenant. Then, [configure Azure AD B2C to send logs to Azure Monitor](./azure-monitor.md). |
| 44 | +To define where logs and metrics for a resource are sent, |
41 | 45 |
|
42 |
| -## Deploy a Microsoft Sentinel instance |
| 46 | +1. Enable **Diagnostic settings** in Azure AD, in your Azure AD B2C tenant. |
| 47 | +2. Configure Azure AD B2C to send logs to Azure Monitor. |
43 | 48 |
|
44 |
| -After you've configured your Azure AD B2C instance to send logs to Azure Monitor, you need to enable a Microsoft Sentinel instance. |
| 49 | +Learn more, [Monitor Azure AD B2C with Azure Monitor](./azure-monitor.md). |
45 | 50 |
|
46 |
| ->[!IMPORTANT] |
47 |
| ->To enable Microsoft Sentinel, you need contributor permissions to the subscription in which the Microsoft Sentinel workspace resides. To use Microsoft Sentinel, you need either contributor or reader permissions on the resource group that the workspace belongs to. |
| 51 | +## Deploy a Microsoft Sentinel instance |
48 | 52 |
|
49 |
| -1. Go to the [Azure portal](https://portal.azure.com). Select the subscription where the Log Analytics workspace is created. |
| 53 | +After you configure your Azure AD B2C instance to send logs to Azure Monitor, enable an instance of Microsoft Sentinel. |
50 | 54 |
|
51 |
| -2. Search for and select **Microsoft Sentinel**. |
| 55 | + >[!IMPORTANT] |
| 56 | + >To enable Microsoft Sentinel, obtain Contributor permissions to the subscription in which the Microsoft Sentinel workspace resides. To use Microsoft Sentinel, use Contributor or Reader permissions on the resource group to which the workspace belongs. |
52 | 57 |
|
53 |
| -  |
| 58 | +1. Go to the [Azure portal](https://portal.azure.com). |
| 59 | +2. Select the subscription where the Log Analytics workspace is created. |
| 60 | +3. Search for and select **Microsoft Sentinel**. |
54 | 61 |
|
55 |
| -3. Select **Add**. |
| 62 | +  |
56 | 63 |
|
57 |
| -4. Select the new workspace. |
| 64 | +3. Select **Add**. |
| 65 | +4. In the **search workspaces** field, select the new workspace. |
58 | 66 |
|
59 |
| -  |
| 67 | +  |
60 | 68 |
|
61 | 69 | 5. Select **Add Microsoft Sentinel**.
|
62 | 70 |
|
63 |
| ->[!NOTE] |
64 |
| ->You can [run Microsoft Sentinel](../sentinel/quickstart-onboard.md) on more than one workspace, but the data is isolated to a single workspace. |
| 71 | + >[!NOTE] |
| 72 | + >It's possible to run Microsoft Sentinel on more than one workspace, however data is isolated in a single workspace.</br> See, [Quickstart: Onboard Microsoft Sentinel](../sentinel/quickstart-onboard.md) |
65 | 73 |
|
66 | 74 | ## Create a Microsoft Sentinel rule
|
67 | 75 |
|
68 |
| -Now that you've enabled Microsoft Sentinel, get notified when something suspicious occurs in your Azure AD B2C tenant. |
| 76 | +After you enable Microsoft Sentinel, get notified when something suspicious occurs in your Azure AD B2C tenant. |
69 | 77 |
|
70 |
| -You can create [custom analytics rules](../sentinel/detect-threats-custom.md) to discover threats and anomalous behaviors in your environment. These rules search for specific events or sets of events and alert you when certain event thresholds or conditions are reached. Then they generate incidents for further investigation. |
| 78 | +You can create custom analytics rules to discover threats and anomalous behaviors in your environment. These rules search for specific events, or event sets, and alert you when event thresholds or conditions are met. Then incidents are generated for investigation. |
71 | 79 |
|
72 |
| ->[!NOTE] |
73 |
| ->Microsoft Sentinel provides built-in templates to help you create threat detection rules designed by Microsoft's team of security experts and analysts. Rules created from these templates automatically search across your data for any suspicious activity. There are no native Azure AD B2C connectors available at this time. For the example in this tutorial, we'll create our own rule. |
| 80 | +See, [Create custom analytics rules to detect threats](../sentinel/detect-threats-custom.md) |
74 | 81 |
|
75 |
| -In the following example, you receive a notification if someone tries to force access to your environment but isn't successful. It might mean a brute-force attack. You want to get notified for two or more unsuccessful logins within 60 seconds. |
| 82 | + >[!NOTE] |
| 83 | + >Microsoft Sentinel has templates to create threat detection rules that search your data for suspicious activity. For this tutorial, you create a rule. |
76 | 84 |
|
77 |
| -1. From the left menu in Microsoft Sentinel, select **Analytics**. |
| 85 | +### Notification rule for unsuccessful forced access |
78 | 86 |
|
79 |
| -2. On the action bar at the top, select **+ Create** > **Scheduled query rule**. |
| 87 | +Use the following steps to receive notification about two or more unsuccessful, forced access attempts into your environment. An example is brute-force attack. |
80 | 88 |
|
81 |
| -  |
| 89 | +1. In Microsoft Sentinel, from the left menu, select **Analytics**. |
| 90 | +2. On the top bar, select **+ Create** > **Scheduled query rule**. |
82 | 91 |
|
83 |
| -3. In the Analytics Rule wizard, go to the **General** tab and enter the following information: |
| 92 | +  |
84 | 93 |
|
85 |
| - | Field | Value | |
86 |
| - |:--|:--| |
87 |
| - |**Name** | Enter a name that's appropriate for Azure AD B2C unsuccessful logins. | |
88 |
| - |**Description** | Enter a description that says the rule will notify on two or more unsuccessful logins within 60 seconds. | |
89 |
| - | **Tactics** | Choose from the categories of attacks by which to classify the rule. These categories are based on the tactics of the [MITRE ATT&CK](https://attack.mitre.org/) framework.<BR>For our example, we'll choose **PreAttack**. <BR> MITRE ATT&CK is a globally accessible knowledge base of adversary tactics and techniques based on real-world observations. This knowledge base is used as a foundation for the development of specific threat models and methodologies. |
90 |
| - | **Severity** | Select an appropriate severity level. | |
91 |
| - | **Status** | When you create the rule, its status is **Enabled** by default. That status means the rule will run immediately after you finish creating it. If you don't want it to run immediately, select **Disabled**. The rule will then be added to your **Active rules** tab, and you can enable it from there when you need it.| |
| 94 | +3. In the Analytics Rule wizard, go to **General**. |
| 95 | +4. For **Name**, enter a name for unsuccessful logins. |
| 96 | +5. For **Description**, indicate the rule notifies for two or more unsuccessful sign-ins, within 60 seconds. |
| 97 | +6. For **Tactics**, select a category. For example, select **PreAttack**. |
| 98 | +7. For **Severity**, select a severity level. |
| 99 | +8. **Status** is **Enabled** by default. To change a rule, go to the **Active rules** tab. |
92 | 100 |
|
93 |
| -  |
| 101 | +  |
94 | 102 |
|
95 |
| -4. To define the rule query logic and configure settings, on the **Set rule logic** tab, write a query directly in the |
96 |
| -**Rule query** box. |
| 103 | +9. Select the **Set rule logic** tab. |
| 104 | +10. Enter a query in the **Rule query** field. The query example organizes the sign-ins by `UserPrincipalName`. |
97 | 105 |
|
98 |
| -  |
| 106 | +  |
99 | 107 |
|
100 |
| - This query will alert you when there are two or more unsuccessful logins within 60 seconds to your Azure AD B2C tenant. It will organize the logins by `UserPrincipalName`. |
| 108 | +11. Go to **Query scheduling**. |
| 109 | +12. For **Run query every**, enter **5** and **Minutes**. |
| 110 | +13. For **Lookup data from the last**, enter **5** and **Minutes**. |
| 111 | +14. For **Generate alert when number of query results**, select **Is greater than**, and **0**. |
| 112 | +15. For **Event grouping**, select **Group all events into a single alert**. |
| 113 | +16. For **Stop running query after alert is generated**, select **Off**. |
| 114 | +17. Select **Next: Incident settings (Preview)**. |
101 | 115 |
|
102 |
| -5. In the **Query scheduling** section, set the following parameters: |
| 116 | +  |
103 | 117 |
|
104 |
| -  |
| 118 | +18. Go to the **Review and create** tab to review rule settings. |
| 119 | +19. When the **Validation passed** banner appears, select **Create**. |
105 | 120 |
|
106 |
| -6. Select **Next: Incident settings (Preview)**. You'll configure and add the automated response later. |
| 121 | +  |
107 | 122 |
|
108 |
| -7. Go to the **Review and create** tab to review all the settings for your new alert rule. When the **Validation passed** message appears, select **Create** to initialize your alert rule. |
| 123 | +#### View a rule and related incidents |
109 | 124 |
|
110 |
| -  |
| 125 | +View the rule and the incidents it generates. Find your newly created custom rule of type **Scheduled** in the table under the **Active rules** tab on the main |
111 | 126 |
|
112 |
| -8. View the rule and the incidents that it generates. Find your newly created custom rule of type **Scheduled** in the table under the **Active rules** tab on the main **Analytics** screen. From this list, you can edit, enable, disable, or delete rules by using the corresponding buttons. |
| 127 | +1. Go to the **Analytics** screen. |
| 128 | +2. Select the **Active rules** tab. |
| 129 | +3. In the table, under **Scheduled**, find the rule. |
113 | 130 |
|
114 |
| -  |
| 131 | +You can edit, enable, disable, or delete the rule. |
115 | 132 |
|
116 |
| -9. View the results of your new rule for Azure AD B2C unsuccessful logins. Go to the **Incidents** page, where you can triage, investigate, and remediate the threats. |
| 133 | +  |
117 | 134 |
|
118 |
| - An incident can include multiple alerts. It's an aggregation of all the relevant evidence for a specific investigation. You can set properties such as severity and status at the incident level. |
| 135 | +#### Triage, investigate, and remediate incidents |
119 | 136 |
|
120 |
| - > [!NOTE] |
121 |
| - > A key feature of Microsoft Sentinel is [incident investigation](../sentinel/investigate-cases.md). |
122 |
| - |
123 |
| -10. To begin an investigation, select a specific incident. |
| 137 | +An incident can include multiple alerts, and is an aggregation of relevant evidence for an investigation. At the incident level, you can set properties such as Severity and Status. |
124 | 138 |
|
125 |
| - On the right, you can see detailed information for the incident. This information includes severity, entities involved, the raw events that triggered the incident, and the incident's unique ID. |
| 139 | +Learn more: [Investigate incidents with Microsoft Sentinel](../sentinel/investigate-cases.md). |
| 140 | + |
| 141 | +1. Go to the **Incidents** page. |
| 142 | +2. Select an incident. |
| 143 | +3. On the right, detailed incident information appears, including severity, entities, events, and the incident ID. |
126 | 144 |
|
127 | 145 | 
|
128 | 146 |
|
129 |
| -11. Select **View full details** on the incident pane. Review the tabs that summarize the incident information and provide more details. |
| 147 | +4. On the **Incidents** pane, elect **View full details**. |
| 148 | +5. Review tabs that summarize the incident. |
130 | 149 |
|
131 |
| -  |
| 150 | +  |
132 | 151 |
|
133 |
| -12. Select **Evidence** > **Events** > **Link to Log Analytics**. The result displays the `UserPrincipalName` value of the identity that's trying to log in with the number of attempts. |
| 152 | +6. Select **Evidence** > **Events** > **Link to Log Analytics**. |
| 153 | +7. In the results, see the identity `UserPrincipalName` value attempting sign-in. |
134 | 154 |
|
135 |
| -  |
| 155 | +  |
136 | 156 |
|
137 | 157 | ## Automated response
|
138 | 158 |
|
139 |
| -Microsoft Sentinel provides a [robust SOAR capability](../sentinel/automation-in-azure-sentinel.md). Automated actions, called a *playbook* in Microsoft Sentinel, can be attached to analytics rules to suit your requirements. |
| 159 | +Microsoft Sentinel has security orchestration, automation, and response (SOAR) functions. Attach automated actions, or a playbook, to analytics rules. |
140 | 160 |
|
141 |
| -In this example, we add an email notification for an incident that the rule creates. To accomplish this task, use an [existing playbook from the Microsoft Sentinel GitHub repository](https://github.com/Azure/Azure-Sentinel/tree/master/Playbooks/Incident-Email-Notification). After the playbook is configured, edit the existing rule and select the playbook on the **Automated response** tab. |
| 161 | +See, [What is SOAR?](https://www.microsoft.com/security/business/security-101/what-is-soar) |
142 | 162 |
|
143 |
| - |
| 163 | +### Email notification for an incident |
144 | 164 |
|
145 |
| -## Related information |
| 165 | +For this task, use a playbook from the Microsoft Sentinel GitHub repository. |
146 | 166 |
|
147 |
| -For more information about Microsoft Sentinel and Azure AD B2C, see: |
| 167 | +1. Go to a configured playbook. |
| 168 | +2. Edit the rule. |
| 169 | +3. On the **Automated response** tab, select the playbook. |
| 170 | + |
| 171 | +Learn more: [Incident-Email-Notification](https://github.com/Azure/Azure-Sentinel/tree/master/Playbooks/Incident-Email-Notification) |
148 | 172 |
|
149 |
| -- [Sample workbooks](https://github.com/azure-ad-b2c/siem#workbooks) |
| 173 | +  |
| 174 | + |
| 175 | +## Resources |
| 176 | + |
| 177 | +For more information about Microsoft Sentinel and Azure AD B2C, see: |
150 | 178 |
|
151 |
| -- [Microsoft Sentinel documentation](../sentinel/index.yml) |
| 179 | +* [Azure AD B2C Reports & Alerts, Workbooks](https://github.com/azure-ad-b2c/siem#workbooks) |
| 180 | +* [Microsoft Sentinel documentation](../sentinel/index.yml) |
152 | 181 |
|
153 |
| -## Next steps |
| 182 | +## Next step |
154 | 183 |
|
155 |
| -> [!div class="nextstepaction"] |
156 |
| -> [Handle false positives in Microsoft Sentinel](../sentinel/false-positives.md) |
| 184 | +[Handle false positives in Microsoft Sentinel](../sentinel/false-positives.md) |
0 commit comments