Skip to content

Commit d24b333

Browse files
committed
2 parents d6b58e2 + e07534a commit d24b333

File tree

2,423 files changed

+65086
-21548
lines changed

Some content is hidden

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

2,423 files changed

+65086
-21548
lines changed

.openpublishing.publish.config.json

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@
194194
{
195195
"path_to_root": "samples-cognitive-services-speech-sdk",
196196
"url": "https://github.com/Azure-Samples/cognitive-services-speech-sdk",
197-
"branch": "docs-201809"
197+
"branch": "rhurey/quickstart.refactor"
198198
},
199199
{
200200
"path_to_root": "media-services-v3-dotnet-quickstarts",
@@ -342,6 +342,11 @@
342342
"url": "https://github.com/Azure-Samples/azure-cosmos-db-sql-api-nodejs-getting-started",
343343
"branch": "master"
344344
},
345+
{
346+
"path_to_root": "azure-cosmos-db-python-getting-started",
347+
"url": "https://github.com/Azure-Samples/azure-cosmos-db-python-getting-started",
348+
"branch": "master"
349+
},
345350
{
346351
"path_to_root": "cognitive-services-content-moderator-samples",
347352
"url": "https://github.com/Azure-Samples/cognitive-services-content-moderator-samples",
@@ -392,6 +397,11 @@
392397
"path_to_root": "azure-cosmosdb-java-v2",
393398
"url": "https://github.com/Azure/azure-cosmosdb-java",
394399
"branch": "master"
400+
},
401+
{
402+
"path_to_root": "azure-cosmosdb-java-v4-getting-started",
403+
"url": "https://github.com/Azure-Samples/azure-cosmos-java-getting-started",
404+
"branch": "master"
395405
}
396406
],
397407
"branch_target_mapping": {

.openpublishing.redirection.json

Lines changed: 371 additions & 4 deletions
Large diffs are not rendered by default.

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Not currently. This feature is on our roadmap. Verifying your domain in the **Do
128128

129129
Follow these steps to delete your Azure AD B2C tenant.
130130

131-
You can use the current **Applications** experience or our new unified **App registrations (Preview)** experience. [Learn more about the preview experience](http://aka.ms/b2cappregintro).
131+
You can use the current **Applications** experience or our new unified **App registrations (Preview)** experience. [Learn more about the preview experience](https://aka.ms/b2cappregintro).
132132

133133
#### [Applications](#tab/applications/)
134134

Lines changed: 55 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,113 +1,108 @@
11
---
2-
title: Application Insights to troubleshoot Custom Policies in Azure Active Directory B2C | Microsoft Docs
3-
description: how to setup Application Insights to trace the execution of custom policies.
2+
title: Troubleshoot custom policies with Application Insights - Azure Active Directory B2C
3+
description: How to set up Application Insights to trace the execution of your custom policies.
44
services: active-directory-b2c
55
author: mmacy
66
manager: celestedg
77

88
ms.service: active-directory
99
ms.workload: identity
1010
ms.topic: conceptual
11-
ms.date: 08/04/2017
11+
ms.date: 11/04/2019
1212
ms.author: marsma
1313
ms.subservice: B2C
1414
---
1515

16-
# Azure Active Directory B2C: Collecting Logs
16+
# Collect Azure Active Directory B2C logs with Application Insights
1717

18-
This article provides steps for collecting logs from Azure AD B2C so that you can diagnose problems with your custom policies.
18+
This article provides steps for collecting logs from Active Directory B2C (Azure AD B2C) so that you can diagnose problems with your custom policies. Application Insights provides a way to diagnose exceptions and visualize application performance issues. Azure AD B2C includes a feature for sending data to Application Insights.
1919

20-
>[!NOTE]
21-
>Currently, the detailed activity logs described here are designed **ONLY** to aid in development of custom policies. Do not use development mode in production. Logs collect all claims sent to and from the identity providers during development. If used in production, the developer assumes responsibility for PII (Privately Identifiable Information) collected in the App Insights log that they own. These detailed logs are only collected when the policy is placed on **DEVELOPMENT MODE**.
20+
The detailed activity logs described here should be enabled **ONLY** during the development of your custom policies.
2221

22+
> [!WARNING]
23+
> Do not enable development mode in production. Logs collect all claims sent to and from identity providers. You as the developer assume responsibility for any personal data collected in your Application Insights logs. These detailed logs are collected only when the policy is placed in **DEVELOPER MODE**.
2324
24-
## Use Application Insights
25+
## Set up Application Insights
2526

26-
Azure AD B2C supports a feature for sending data to Application Insights. Application Insights provides a way to diagnose exceptions and visualize application performance issues.
27+
If you don't already have one, create an instance of Application Insights in your subscription.
2728

28-
### Setup Application Insights
29+
1. Sign in to the [Azure portal](https://portal.azure.com).
30+
1. Select the **Directory + subscription** filter in the top menu, and then select the directory that contains your Azure subscription (not your Azure AD B2C directory).
31+
1. Select **Create a resource** in the left-hand navigation menu.
32+
1. Search for and select **Application Insights**, then select **Create**.
33+
1. Complete the form, select **Review + create**, and then select **Create**.
34+
1. Once the deployment has been completed, select **Go to resource**.
35+
1. Under **Configure** in Application Insights menu, select **Properties**.
36+
1. Record the **INSTRUMENTATION KEY** for use in a later step.
2937

30-
1. Go to the [Azure portal](https://portal.azure.com). Ensure you are in the tenant with your Azure subscription (not your Azure AD B2C tenant).
31-
1. Click **+ New** in the left-hand navigation menu.
32-
1. Search for and select **Application Insights**, then click **Create**.
33-
1. Complete the form and click **Create**. Select **General** for the **Application Type**.
34-
1. Once the resource has been created, open the Application Insights resource.
35-
1. Find **Properties** in the left-menu, and click on it.
36-
1. Copy the **Instrumentation Key** and save it for the next section.
38+
## Configure the custom policy
3739

38-
### Set up the custom policy
39-
40-
1. Open the RP file (for example, SignUpOrSignin.xml).
40+
1. Open the relying party (RP) file, for example *SignUpOrSignin.xml*.
4141
1. Add the following attributes to the `<TrustFrameworkPolicy>` element:
4242

4343
```XML
4444
DeploymentMode="Development"
4545
UserJourneyRecorderEndpoint="urn:journeyrecorder:applicationinsights"
4646
```
4747

48-
1. If it doesn't exist already, add a child node `<UserJourneyBehaviors>` to the `<RelyingParty>` node. It must be located immediately after the `<DefaultUserJourney ReferenceId="UserJourney Id from your extensions policy, or equivalent (for example:SignUpOrSigninWithAAD" />`
49-
2. Add the following node as a child of the `<UserJourneyBehaviors>` element. Make sure to replace `{Your Application Insights Key}` with the **Instrumentation Key** that you obtained from Application Insights in the previous section.
48+
1. If it doesn't already exist, add a `<UserJourneyBehaviors>` child node to the `<RelyingParty>` node. It must be located immediately after `<DefaultUserJourney ReferenceId="UserJourney Id" from your extensions policy, or equivalent (for example:SignUpOrSigninWithAAD" />`.
49+
1. Add the following node as a child of the `<UserJourneyBehaviors>` element. Make sure to replace `{Your Application Insights Key}` with the Application Insights **Instrumentation Key** that you recorded earlier.
5050

51-
```XML
52-
<JourneyInsights TelemetryEngine="ApplicationInsights" InstrumentationKey="{Your Application Insights Key}" DeveloperMode="true" ClientEnabled="false" ServerEnabled="true" TelemetryVersion="1.0.0" />
53-
```
51+
```XML
52+
<JourneyInsights TelemetryEngine="ApplicationInsights" InstrumentationKey="{Your Application Insights Key}" DeveloperMode="true" ClientEnabled="false" ServerEnabled="true" TelemetryVersion="1.0.0" />
53+
```
5454

55-
* `DeveloperMode="true"` tells ApplicationInsights to expedite the telemetry through the processing pipeline, good for development, but constrained at high volumes.
56-
* `ClientEnabled="true"` sends the ApplicationInsights client-side script for tracking page view and client-side errors (not needed).
57-
* `ServerEnabled="true"` sends the existing UserJourneyRecorder JSON as a custom event to Application Insights.
58-
Sample:
55+
* `DeveloperMode="true"` tells ApplicationInsights to expedite the telemetry through the processing pipeline. Good for development, but constrained at high volumes.
56+
* `ClientEnabled="true"` sends the ApplicationInsights client-side script for tracking page view and client-side errors. You can view these in the **browserTimings** table in the Application Insights portal. By setting `ClientEnabled= "true"`, you add Application Insights to your page script and you get timings of page loads and AJAX calls, counts, details of browser exceptions and AJAX failures, and user and session counts. This field is **optional**, and is set to `false` by default.
57+
* `ServerEnabled="true"` sends the existing UserJourneyRecorder JSON as a custom event to Application Insights.
5958

60-
```XML
61-
<TrustFrameworkPolicy
62-
...
63-
TenantId="fabrikamb2c.onmicrosoft.com"
64-
PolicyId="SignUpOrSignInWithAAD"
65-
DeploymentMode="Development"
66-
UserJourneyRecorderEndpoint="urn:journeyrecorder:applicationinsights"
67-
>
59+
For example:
60+
61+
```XML
62+
<TrustFrameworkPolicy
63+
...
64+
TenantId="fabrikamb2c.onmicrosoft.com"
65+
PolicyId="SignUpOrSignInWithAAD"
66+
DeploymentMode="Development"
67+
UserJourneyRecorderEndpoint="urn:journeyrecorder:applicationinsights"
68+
>
6869
...
6970
<RelyingParty>
7071
<DefaultUserJourney ReferenceId="UserJourney ID from your extensions policy, or equivalent (for example: SignUpOrSigninWithAzureAD)" />
7172
<UserJourneyBehaviors>
7273
<JourneyInsights TelemetryEngine="ApplicationInsights" InstrumentationKey="{Your Application Insights Key}" DeveloperMode="true" ClientEnabled="false" ServerEnabled="true" TelemetryVersion="1.0.0" />
7374
</UserJourneyBehaviors>
7475
...
75-
</TrustFrameworkPolicy>
76-
```
76+
</TrustFrameworkPolicy>
77+
```
7778

78-
3. Upload the policy.
79+
1. Upload the policy.
7980

80-
### See the logs in Application Insights
81+
## See the logs in Application Insights
8182

82-
>[!NOTE]
83-
> There is a short delay (less than five minutes) before you can see new logs in Application Insights.
83+
There is a short delay, typically less than five minutes, before you can see new logs in Application Insights.
8484

8585
1. Open the Application Insights resource that you created in the [Azure portal](https://portal.azure.com).
86-
1. In the **Overview** menu, click on **Analytics**.
86+
1. In the **Overview** menu, select **Analytics**.
8787
1. Open a new tab in Application Insights.
88-
1. Here is a list of queries you can use to see the logs
88+
89+
Here is a list of queries you can use to see the logs:
8990

9091
| Query | Description |
9192
|---------------------|--------------------|
92-
traces | See all of the logs generated by Azure AD B2C |
93-
traces \| where timestamp > ago(1d) | See all of the logs generated by Azure AD B2C for the last day
94-
95-
The entries may be long. Export to CSV for a closer look.
96-
97-
You can learn more about the Analytics tool [here](https://docs.microsoft.com/azure/application-insights/app-insights-analytics).
98-
99-
>[!NOTE]
100-
>The community has developed a user journey viewer to help identity developers. It is not supported by Microsoft and made available strictly as-is. It reads from your Application Insights instance and provides a well-structured view of the user journey events. You obtain the source code and deploy it in your own solution.
93+
`traces` | See all of the logs generated by Azure AD B2C |
94+
`traces | where timestamp > ago(1d)` | See all of the logs generated by Azure AD B2C for the last day
10195

102-
The version of the viewer that reads events from Application Insights is located [here](https://github.com/Azure-Samples/active-directory-b2c-advanced-policies/tree/master/wingtipgamesb2c/src/WingTipUserJourneyPlayerWebApplication)
96+
The entries may be long. Export to CSV for a closer look.
10397

104-
>[!NOTE]
105-
>Currently, the detailed activity logs described here are designed **ONLY** to aid in development of custom policies. Do not use development mode in production. Logs collect all claims sent to and from the identity providers during development. If used in production, the developer assumes responsibility for PII (Privately Identifiable Information) collected in the App Insights log that they own. These detailed logs are only collected when the policy is placed on **DEVELOPMENT MODE**.
98+
For more information about querying, see [Overview of log queries in Azure Monitor](../azure-monitor/log-query/log-query-overview.md).
10699

107-
[GitHub Repository for Unsupported Custom Policy Samples and Related tools](https://github.com/Azure-Samples/active-directory-b2c-advanced-policies)
100+
## Next steps
108101

102+
The community has developed a user journey viewer to help identity developers. It reads from your Application Insights instance and provides a well-structured view of the user journey events. You obtain the source code and deploy it in your own solution.
109103

104+
The user journey player is not supported by Microsoft, and is made available strictly as-is.
110105

111-
## Next Steps
106+
You can find the version of the viewer that reads events from Application Insights on GitHub, here:
112107

113-
Explore the data in Application Insights to help you understand how the Identity Experience Framework underlying B2C works to deliver your own identity experiences.
108+
[Azure-Samples/active-directory-b2c-advanced-policies](https://github.com/Azure-Samples/active-directory-b2c-advanced-policies/tree/master/wingtipgamesb2c/src/WingTipUserJourneyPlayerWebApplication)

articles/active-directory-b2c/active-directory-b2c-tutorials-spa.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ Additionally, you need the following in your local development environment:
4444

4545
In the second tutorial that you completed as part of the prerequisites, you registered a web application in Azure AD B2C. To enable communication with the sample in the tutorial, you need to add a redirect URI to the application in Azure AD B2C.
4646

47-
You can use the current **Applications** experience or our new unified **App registrations (Preview)** experience to update the application. [Learn more about the preview experience](http://aka.ms/b2cappregintro).
47+
You can use the current **Applications** experience or our new unified **App registrations (Preview)** experience to update the application. [Learn more about the preview experience](https://aka.ms/b2cappregintro).
4848

4949
#### [Applications](#tab/applications/)
5050

articles/active-directory-b2c/active-directory-b2c-tutorials-web-app.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ In the tutorial that you completed as part of the prerequisites, you registered
3737

3838
### Add a redirect URI (reply URL)
3939

40-
You can use the current **Applications** experience or our new unified **App registrations (Preview)** experience to update the application. [Learn more about the preview experience](http://aka.ms/b2cappregintro).
40+
You can use the current **Applications** experience or our new unified **App registrations (Preview)** experience to update the application. [Learn more about the preview experience](https://aka.ms/b2cappregintro).
4141

4242
#### [Applications](#tab/applications/)
4343

articles/active-directory-b2c/active-directory-b2c-user-migration.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,12 +173,12 @@ To validate the migration, use one of the following two methods:
173173
1. Open **Azure AD B2C**, and then select **Users**.
174174
1. In the search box, type the user's display name, and then view the user's profile.
175175

176-
- To retrieve a user by sign-in email address, use this sample application:
176+
- To retrieve a user by sign-in email address, use the sample application:
177177

178178
1. Run the following command:
179179

180180
```Console
181-
UserMigration.exe 3 {email address}
181+
UserMigration.exe 3 {email address} > UserProfile.json
182182
```
183183

184184
> [!TIP]

articles/active-directory-b2c/saml-technical-profile.md

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: Define a SAML technical profile in a custom policy in Azure Active Directory B2C | Microsoft Docs
2+
title: Define a SAML technical profile in a custom policy in Azure Active Directory B2C
33
description: Define a SAML technical profile in a custom policy in Azure Active Directory B2C.
44
services: active-directory-b2c
55
author: mmacy
@@ -8,7 +8,7 @@ manager: celestedg
88
ms.service: active-directory
99
ms.workload: identity
1010
ms.topic: reference
11-
ms.date: 12/21/2018
11+
ms.date: 11/04/2019
1212
ms.author: marsma
1313
ms.subservice: B2C
1414
---
@@ -54,7 +54,6 @@ The following diagram shows the metadata and certificate exchange:
5454

5555
![metadata and certificate exchange](media/saml-technical-profile/technical-profile-idp-saml-metadata.png)
5656

57-
5857
## Digital encryption
5958

6059
To encrypt the SAML response assertion, the identity provider always uses a public key of an encryption certificate in an Azure AD B2C technical profile. When Azure AD B2C needs to decrypt the data, it uses the private portion of the encryption certificate.
@@ -129,7 +128,7 @@ The technical profile also returns claims that aren't returned by the identity p
129128
| NameIdPolicyFormat | No | Specifies constraints on the name identifier to be used to represent the requested subject. If omitted, any type of identifier supported by the identity provider for the requested subject can be used. For example, `urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified`. **NameIdPolicyFormat** can be used with **NameIdPolicyAllowCreate**. Look at your identity provider’s documentation for guidance about which name ID policies are supported. |
130129
| NameIdPolicyAllowCreate | No | When using **NameIdPolicyFormat**, you can also specify the `AllowCreate` property of **NameIDPolicy**. The value of this metadata is `true` or `false` to indicate whether the identity provider is allowed to create a new account during the sign-in flow. Look at your identity provider’s documentation for guidance on how to do so. |
131130
| AuthenticationRequestExtensions | No | Optional protocol message extension elements that are agreed on between Azure AD BC and the identity provider. The extension is presented in XML format. You add the XML data inside the CDATA element `<![CDATA[Your IDP metadata]]>`. Check your identity provider’s documentation to see if the extensions element is supported. |
132-
| IncludeAuthnContextClassReferences | No | Specifies one or more URI references identifying authentication context classes. For example, to allow a user to sign in with username and password only, set the value to `urn:oasis:names:tc:SAML:2.0:ac:classes:Password`. To allow sign-in through username and password over a protected session (SSL/TLS), specify `PasswordProtectedTransport`. Look at your identity provider’s documentation for guidance about the **AuthnContextClassRef** URIs that are supported. |
131+
| IncludeAuthnContextClassReferences | No | Specifies one or more URI references identifying authentication context classes. For example, to allow a user to sign in with username and password only, set the value to `urn:oasis:names:tc:SAML:2.0:ac:classes:Password`. To allow sign-in through username and password over a protected session (SSL/TLS), specify `PasswordProtectedTransport`. Look at your identity provider’s documentation for guidance about the **AuthnContextClassRef** URIs that are supported. Specify multiple URIs as a comma-delimited list. |
133132
| IncludeKeyInfo | No | Indicates whether the SAML authentication request contains the public key of the certificate when the binding is set to `HTTP-POST`. Possible values: `true` or `false`. |
134133

135134
## Cryptographic keys
@@ -142,20 +141,9 @@ The **CryptographicKeys** element contains the following attributes:
142141
| SamlAssertionDecryption |Yes | The X509 certificate (RSA key set) to use to decrypt SAML messages. This certificate should be provided by the identity provider. Azure AD B2C uses this certificate to decrypt the data sent by the identity provider. |
143142
| MetadataSigning |No | The X509 certificate (RSA key set) to use to sign SAML metadata. Azure AD B2C uses this key to sign the metadata. |
144143

145-
## Examples
144+
## Next steps
145+
146+
See the following articles for examples of working with SAML identity providers in Azure AD B2C:
146147

147148
- [Add ADFS as a SAML identity provider using custom policies](active-directory-b2c-custom-setup-adfs2016-idp.md)
148149
- [Sign in by using Salesforce accounts via SAML](active-directory-b2c-setup-sf-app-custom.md)
149-
150-
151-
152-
153-
154-
155-
156-
157-
158-
159-
160-
161-

0 commit comments

Comments
 (0)