Skip to content

Commit 7de6a86

Browse files
committed
Merge branch 'master' of https://github.com/MicrosoftDocs/azure-docs-pr into 1597213-Part1
2 parents 66582c3 + acbd303 commit 7de6a86

File tree

455 files changed

+7710
-3050
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

455 files changed

+7710
-3050
lines changed

articles/active-directory-b2c/active-directory-b2c-apps.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,12 +128,12 @@ This chained web API scenario can be supported by using the OAuth 2.0 JWT bearer
128128

129129
Do not edit Azure AD B2C applications in these ways:
130130

131-
- On other application management portals such as the [Application Registration Portal](https://apps.dev.microsoft.com/).
131+
- On other application management portals such as the [Application Registration Portal](https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationsListBlade).
132132
- Using Graph API or PowerShell.
133133

134134
If you edit the Azure AD B2C application outside of the Azure portal, it becomes a faulted application and is no longer usable with Azure AD B2C. Delete the application and create it again.
135135

136-
To delete the application, go to the [Application Registration Portal](https://apps.dev.microsoft.com/) and delete the application there. In order for the application to be visible, you need to be the owner of the application (and not just an admin of the tenant).
136+
To delete the application, go to the [Application Registration Portal](https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationsListBlade) and delete the application there. In order for the application to be visible, you need to be the owner of the application (and not just an admin of the tenant).
137137

138138
## Next steps
139139

articles/active-directory-b2c/active-directory-b2c-overview-custom.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ The customer identity and access management (CIAM) service in Azure includes:
5151

5252
Azure AD B2C interacts with identity providers, users, other systems, and with the local user directory in sequence to achieve an identity task. For example, sign in a user, register a new user, or reset a password. The Identity Experience Framework and a policy (also called a user journey or a trust framework policy) establishes multi-party trust and explicitly defines the actors, the actions, the protocols, and the sequence of steps to complete.
5353

54-
The Identity Experience Framework is a fully configurable, policy-driven, cloud-based Azure platform that orchestrates trust between entities in standard protocol formats such as OpenID Connect, OAuth, SAML, WSFed, and a few non-standard ones, for example REST API-based system-to-system claims exchanges. The framework creates user-friendly, white-labeled experiences that support HTML and CSS.
54+
The Identity Experience Framework is a fully configurable, policy-driven, cloud-based Azure platform that orchestrates trust between entities in standard protocol formats such as OpenID Connect, OAuth, SAML, and a few non-standard ones, for example REST API-based system-to-system claims exchanges. The framework creates user-friendly, white-labeled experiences that support HTML and CSS.
5555

5656
A custom policy is represented as one or several XML-formatted files that refer to each other in a hierarchical chain. The XML elements define the claims schema, claims transformations, content definitions, claims providers, technical profiles, and user journey orchestration steps, among other elements. A custom policy is accessible as one or several XML files that are executed by the Identity Experience Framework when invoked by a relying party. Developers configuring custom policies must define the trusted relationships in careful detail to include metadata endpoints, exact claims exchange definitions, and configure secrets, keys, and certificates as needed by each identity provider.
5757

articles/active-directory-b2c/active-directory-b2c-reference-audit-logs.md

Lines changed: 139 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -16,95 +16,124 @@ ms.custom: fasttrack-edit
1616

1717
# Accessing Azure AD B2C audit logs
1818

19-
Azure Active Directory B2C (Azure AD B2C) emits audit logs containing activity information about B2C resources, issued tokens, and administrator access. This article provides a brief overview of the information available through audit logs and instructions on how to access this data for your Azure AD B2C tenant.
19+
Azure Active Directory B2C (Azure AD B2C) emits audit logs containing activity information about B2C resources, tokens issued, and administrator access. This article provides a brief overview of the information available in audit logs and instructions on how to access this data for your Azure AD B2C tenant.
2020

21-
> [!IMPORTANT]
22-
> Audit logs are only retained for seven days. Plan to download and store your logs using one of the methods shown below if you require a longer retention period.
21+
Audit log events are only retained for **seven days**. Plan to download and store your logs using one of the methods shown below if you require a longer retention period.
2322

2423
> [!NOTE]
25-
> You cannot see user sign-ins for individual Azure AD B2C applications under the **Users** section of the **Azure Active Directory** or **Azure AD B2C** blades. The sign-ins there will show user activity, but cannot be correlated back to the B2C application that the user signed in to. You must use the audit logs for that, as explained further in this article.
24+
> You can't see user sign-ins for individual Azure AD B2C applications under the **Users** section of the **Azure Active Directory** or **Azure AD B2C** pages in the Azure portal. The sign-in events there show user activity, but can't be correlated back to the B2C application that the user signed in to. You must use the audit logs for that, as explained further in this article.
2625
2726
## Overview of activities available in the B2C category of audit logs
2827

2928
The **B2C** category in audit logs contains the following types of activities:
3029

3130
|Activity type |Description |
3231
|---------|---------|
33-
|Authorization |Activities concerning the authorization of a user to access B2C resources (for example, an administrator accessing a list of B2C policies) |
34-
|Directory |Activities related to directory attributes retrieved when an administrator signs in using the Azure portal |
35-
|Application | CRUD operations on B2C applications |
36-
|Key |CRUD operations on keys stored in B2C key container |
37-
|Resource |CRUD operations on B2C resources (for example, policies and identity providers)
38-
|Authentication |Validation of user credentials and token issuance|
32+
|Authorization |Activities concerning the authorization of a user to access B2C resources (for example, an administrator accessing a list of B2C policies). |
33+
|Directory |Activities related to directory attributes retrieved when an administrator signs in using the Azure portal. |
34+
|Application | Create, read, update, and delete (CRUD) operations on B2C applications. |
35+
|Key |CRUD operations on keys stored in a B2C key container. |
36+
|Resource |CRUD operations on B2C resources. For example, policies and identity providers.
37+
|Authentication |Validation of user credentials and token issuance.|
3938

40-
> [!NOTE]
41-
> For user object CRUD activities, refer to the **Core Directory** category.
39+
For user object CRUD activities, refer to the **Core Directory** category.
4240

4341
## Example activity
4442

45-
The example below shows the data captured when a user signs in with an external identity provider:
46-
![Example of Audit Log Activity Details page in Azure portal](./media/active-directory-b2c-reference-audit-logs/audit-logs-example.png)
43+
This example image from the Azure portal shows the data captured when a user signs in with an external identity provider, in this case, Facebook:
44+
45+
![Example of Audit Log Activity Details page in Azure portal](./media/active-directory-b2c-reference-audit-logs/audit-logs-example.png)
4746

4847
The activity details panel contains the following relevant information:
4948

5049
|Section|Field|Description|
5150
|-------|-----|-----------|
52-
| Activity | Name | Which activity took place. For example, "Issue an id_token to the application" (which concludes the actual user sign-in). |
53-
| Initiated By (Actor) | ObjectId | The **Object ID** of the B2C application that the user is signing in to (this identifier is not visible in the Azure portal but it's accessible via the Graph API for example). |
51+
| Activity | Name | Which activity took place. For example, *Issue an id_token to the application*, which concludes the actual user sign-in. |
52+
| Initiated By (Actor) | ObjectId | The **Object ID** of the B2C application that the user is signing in to. This identifier is not visible in the Azure portal, but is accessible via the Microsoft Graph API. |
5453
| Initiated By (Actor) | Spn | The **Application ID** of the B2C application that the user is signing in to. |
5554
| Target(s) | ObjectId | The **Object ID** of the user that is signing in. |
5655
| Additional Details | TenantId | The **Tenant ID** of the Azure AD B2C tenant. |
5756
| Additional Details | PolicyId | The **Policy ID** of the user flow (policy) being used to sign the user in. |
5857
| Additional Details | ApplicationId | The **Application ID** of the B2C application that the user is signing in to. |
5958

60-
## Accessing audit logs through the Azure portal
59+
## View audit logs in the Azure portal
6160

62-
1. Go to the [Azure portal](https://portal.azure.com). Make sure you are in your B2C directory.
63-
2. Click on **Azure Active Directory** in the favorites bar on the left
61+
The Azure portal provides access to the audit log events in your Azure AD B2C tenant.
6462

65-
![Azure Active Directory button highlighted in left-hand portal menu](./media/active-directory-b2c-reference-audit-logs/audit-logs-portal-aad.png)
63+
1. Sign in to the [Azure portal](https://portal.azure.com)
64+
1. Switch to the directory that contains your Azure AD B2C tenant, and then browse to **Azure AD B2C**.
65+
1. Under **Activities** in the left menu, select **Audit logs**.
6666

67-
1. Under **Activity**, click on **Audit Logs**
67+
A list of activity events logged over the last seven days is displayed.
6868

69-
![Audit Logs button highlighted in Activity section of menu](./media/active-directory-b2c-reference-audit-logs/audit-logs-portal-section.png)
69+
![Example filter with two activity events in Azure portal](media/active-directory-b2c-reference-audit-logs/audit-logs-example-filter.png)
7070

71-
2. In the **Category** dropbox, select **B2C**
72-
3. Click on **Apply**
71+
Several filtering options are available, including:
7372

74-
![Category and Apply button highlighted in Audit Log filter](./media/active-directory-b2c-reference-audit-logs/audit-logs-portal-category.png)
73+
* **Activity Resource Type** - Filter by the activity types shown in the table in the [Overview of activities available](#overview-of-activities-available-in-the-b2c-category-of-audit-logs) section.
74+
* **Date** - Filter the date range of the activities shown.
7575

76-
You will see a list of activities logged over the last seven days.
76+
If you select a row in the list, the activity details for the event are displayed.
7777

78-
- Use the **Activity Resource Type** dropdown to filter by the activity types outlined above
79-
- Use the **Date Range** dropdown to filter the date range of the activities shown
80-
- If you click on a specific row in the list, a contextual box on the right will show you additional attributes associated with the activity
81-
- Click on **Download** to download the activities as a csv file
78+
To download the list of activity events in a comma-separated values (CSV) file, select **Download**.
8279

83-
> [!NOTE]
84-
> You can also see the audit logs by navigating to **Azure AD B2C** rather than **Azure Active Directory** in the favorites bar on the left. Under **Activities**, click on **Audit logs**, where you will find the same logs with similar filtering capabilities.
85-
86-
## Accessing audit logs through the Azure AD reporting API
80+
## Get audit logs with the Azure AD reporting API
8781

8882
Audit logs are published to the same pipeline as other activities for Azure Active Directory, so they can be accessed through the [Azure Active Directory reporting API](https://docs.microsoft.com/graph/api/directoryaudit-list). For more information, see [Get started with the Azure Active Directory reporting API](../active-directory/reports-monitoring/concept-reporting-api.md).
8983

90-
### Prerequisites
84+
### Enable reporting API access
85+
86+
To allow script- or application-based access to the Azure AD reporting API, you need an Azure Active Directory application registered in your Azure AD B2C tenant with the following API permissions:
87+
88+
* Microsoft Graph
89+
* Application: Read all audit log data
90+
91+
You can enable these permissions on an existing Azure Active Directory application registration within your B2C tenant, or create a new one specifically for use with audit log automation.
92+
93+
To create a new application, assign the required API permissions, and create a client secret, perform the following steps:
94+
95+
1. Register application in Azure Active Directory
96+
1. Sign in to the [Azure portal](https://portal.azure.com) and switch to the directory that contains your Azure AD B2C tenant.
97+
1. Select **Azure Active Directory** (*not* Azure AD B2C) from the left menu. Or, select **All services**, then search for and select **Azure Active Directory**.
98+
1. Under **Manage** in the left menu, select **App registrations (Legacy)**.
99+
1. Select **New application registration**
100+
1. Enter a name for the application. For example, *Audit Log App*.
101+
1. Enter any valid URL in **Sign-on URL**. For example, *https://localhost*. This endpoint does not need to be reachable, but needs to be a valid URL.
102+
1. Select **Create**.
103+
1. Record the **Application ID** that appears on the **Registered app** page. You need this value for authentication in automation scripts like the example PowerShell script shown in a later section.
104+
1. Assign API access permissions
105+
1. On the **Registered app** overview page, select **Settings**.
106+
1. Under **API ACCESS**, select **Required permissions**.
107+
1. Select **Add**, and then **Select an API**.
108+
1. Select **Microsoft Graph**, and then **Select**.
109+
1. Under **APPLICATION PERMISSIONS**, select **Read all audit log data**.
110+
1. Select the **Select** button, and then select **Done**.
111+
1. Select **Grant permissions**, and then select **Yes**.
112+
1. Create client secret
113+
1. Under **API ACCESS**, select **Keys**.
114+
1. Enter a description for the key in the **Key description** box. For example, *Audit Log Key*.
115+
1. Select a validity **Duration**, then select **Save**.
116+
1. Record the key's **VALUE**. You need this value for authentication in automation scripts like the example PowerShell script shown in a later section.
91117

92-
To authenticate to the Azure AD reporting API you first need to register an application. Make sure to follow the steps in [Prerequisites to access the Azure AD reporting APIs](https://azure.microsoft.com/documentation/articles/active-directory-reporting-api-getting-started/).
118+
You now have an application with the required API access, an application ID, and a key that you can use in your automation scripts. See the PowerShell script section later in this article for an example of how you can get activity events with a script.
93119

94-
### Accessing the API
120+
### Access the API
95121

96-
To download the Azure AD B2C audit logs via the API, you'll want to filter the logs to the **B2C** category. To filter by category, use the query string parameter when calling the Azure AD reporting API endpoint, as shown below:
122+
To download Azure AD B2C audit log events via the API, filter the logs on the `B2C` category. To filter by category, use the `filter` query string parameter when you call the Azure AD reporting API endpoint.
97123

98124
```HTTP
99-
https://graph.microsoft.com/v1.0/auditLogs/directoryAudits?filter=loggedByService eq 'B2C' and activityDateTime gt 2019-09-10T02:28:17Z
125+
https://graph.microsoft.com/v1.0/auditLogs/directoryAudits?$filter=loggedByService eq 'B2C' and activityDateTime gt 2019-09-10T02:28:17Z
100126
```
101127

102128
### PowerShell script
103129

104-
The following script provides an example of using PowerShell to query the Azure AD reporting API and outputting the results to a JSON file:
130+
The following PowerShell script shows an example of how to query the Azure AD reporting API. After querying the API, it prints the logged events to standard output, then writes the JSON output to a file.
131+
132+
You can try this script in the [Azure Cloud Shell](../cloud-shell/overview.md). Be sure to update it with your application ID, key, and the name of your Azure AD B2C tenant.
105133

106134
```powershell
107-
# This script requires the registration of a Web Application in Azure Active Directory (see https://docs.microsoft.com/azure/active-directory/reports-monitoring/concept-reporting-api)
135+
# This script requires the registration of a Web Application in Azure Active Directory:
136+
# https://docs.microsoft.com/azure/active-directory/reports-monitoring/concept-reporting-api
108137
109138
# Constants
110139
$ClientID = "your-client-application-id-here" # Insert your application's Client ID, a GUID (registered by Global Admin)
@@ -144,3 +173,72 @@ if ($oauth.access_token -ne $null) {
144173
Write-Host "ERROR: No Access Token"
145174
}
146175
```
176+
177+
Here's the JSON representation of the example activity event shown earlier in the article:
178+
179+
```JSON
180+
{
181+
"id": "B2C_DQO3J_4984536",
182+
"category": "Authentication",
183+
"correlationId": "00000000-0000-0000-0000-000000000000",
184+
"result": "success",
185+
"resultReason": "N/A",
186+
"activityDisplayName": "Issue an id_token to the application",
187+
"activityDateTime": "2019-09-14T18:13:17.0618117Z",
188+
"loggedByService": "B2C",
189+
"operationType": "",
190+
"initiatedBy": {
191+
"user": null,
192+
"app": {
193+
"appId": "00000000-0000-0000-0000-000000000000",
194+
"displayName": null,
195+
"servicePrincipalId": null,
196+
"servicePrincipalName": "00000000-0000-0000-0000-000000000000"
197+
}
198+
},
199+
"targetResources": [
200+
{
201+
"id": "00000000-0000-0000-0000-000000000000",
202+
"displayName": null,
203+
"type": "User",
204+
"userPrincipalName": null,
205+
"groupType": null,
206+
"modifiedProperties": []
207+
}
208+
],
209+
"additionalDetails": [
210+
{
211+
"key": "TenantId",
212+
"value": "test.onmicrosoft.com"
213+
},
214+
{
215+
"key": "PolicyId",
216+
"value": "B2C_1A_signup_signin"
217+
},
218+
{
219+
"key": "ApplicationId",
220+
"value": "00000000-0000-0000-0000-000000000000"
221+
},
222+
{
223+
"key": "Client",
224+
"value": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.132 Safari/537.36"
225+
},
226+
{
227+
"key": "IdentityProviderName",
228+
"value": "facebook"
229+
},
230+
{
231+
"key": "IdentityProviderApplicationId",
232+
"value": "0000000000000000"
233+
},
234+
{
235+
"key": "ClientIpAddress",
236+
"value": "127.0.0.1"
237+
}
238+
]
239+
}
240+
```
241+
242+
## Next steps
243+
244+
You can automate other administration tasks, for example, [manage users with .NET](active-directory-b2c-devquickstarts-graph-dotnet.md).

articles/active-directory-b2c/claimsschema.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ The **Protocol** element contains the following attributes:
6767

6868
| Attribute | Required | Description |
6969
| --------- | -------- | ----------- |
70-
| Name | Yes | The name of a valid protocol supported by Azure AD B2C. Possible values are: OAuth1, OAuth2, SAML2, OpenIdConnect, WsFed, or WsTrust. |
70+
| Name | Yes | The name of a valid protocol supported by Azure AD B2C. Possible values are: OAuth1, OAuth2, SAML2, OpenIdConnect. |
7171
| PartnerClaimType | Yes | The claim type name to be used. |
7272

7373
In the following example, when the Identity Experience Framework interacts with a SAML2 identity provider or relying party application, the **surname** claim is mapped to `http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname`, with OpenIdConnect and OAuth2, the claim is mapped to `family_name`.
42.6 KB
Loading
-89.6 KB
Loading

articles/active-directory-b2c/technical-profiles-overview.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ A technical profile enables these types of scenarios:
3333
- [RESTful provider](restful-technical-profile.md) - Call to REST API services, such as validate user input, enrich user data, or integrate with line-of-business applications.
3434
- [SAML2](saml-technical-profile.md) - Federation with any SAML protocol identity provider.
3535
- [Self-Asserted](self-asserted-technical-profile.md) - Interact with the user. For example, collect the user's credential to sign in, render the sign-up page, or password reset.
36-
- **WsFed** - Federation with any WsFed protocol identity provider.
3736
- [Session management](active-directory-b2c-reference-sso-custom.md) - Handle different types of sessions.
3837
- **Application insights**
3938

0 commit comments

Comments
 (0)