Skip to content

Commit 38d684b

Browse files
authored
Update BWA+OIDC BFF app config (#519)
1 parent 57899c3 commit 38d684b

File tree

2 files changed

+14
-22
lines changed
  • 8.0/BlazorWebAppOidcBff/BlazorWebAppOidc
  • 9.0/BlazorWebAppOidcBff/BlazorWebAppOidc

2 files changed

+14
-22
lines changed

8.0/BlazorWebAppOidcBff/BlazorWebAppOidc/Program.cs

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,13 @@
5656
// ........................................................................
5757

5858
// ........................................................................
59-
// The "Weather.Get" scope is configured in the Azure or Entra portal under
60-
// "Expose an API". This is necessary for backend web API (MinimalApiJwt)
61-
// to validate the access token with AddBearerJwt. The following code example
62-
// uses a scope format of the App ID URI for an AAD B2C tenant type. If your
63-
// tenant is an ME-ID tenant, the App ID URI format is different:
64-
// api://{CLIENT ID}, so the full scope with an API name of "Weather.Get" is:
65-
// api://{CLIENT ID}/Weather.Get
66-
// The {CLIENT ID} is the application (client) ID of the MinimalApiJwt app
67-
// registration.
68-
69-
oidcOptions.Scope.Add("https://{DIRECTORY NAME}.onmicrosoft.com/{CLIENT ID}/Weather.Get");
59+
// The "Weather.Get" scope for accessing the external web API for weather
60+
// data. The following example is based on using Microsoft Entra ID in
61+
// an ME-ID tenant domain (the {APP ID URI} placeholder is found in
62+
// the Entra or Azure portal where the web API is exposed). For any other
63+
// identity provider, use the appropriate scope.
64+
65+
oidcOptions.Scope.Add("{APP ID URI}/Weather.Get");
7066
// ........................................................................
7167

7268
// ........................................................................

9.0/BlazorWebAppOidcBff/BlazorWebAppOidc/Program.cs

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -68,17 +68,13 @@
6868
// ........................................................................
6969

7070
// ........................................................................
71-
// The "Weather.Get" scope is configured in the Azure or Entra portal under
72-
// "Expose an API". This is necessary for backend web API (MinimalApiJwt)
73-
// to validate the access token with AddBearerJwt. The following code example
74-
// uses a scope format of the App ID URI for an AAD B2C tenant type. If your
75-
// tenant is an ME-ID tenant, the App ID URI format is different:
76-
// api://{CLIENT ID}, so the full scope with an API name of "Weather.Get" is:
77-
// api://{CLIENT ID}/Weather.Get
78-
// The {CLIENT ID} is the application (client) ID of the MinimalApiJwt app
79-
// registration.
80-
81-
oidcOptions.Scope.Add("https://{DIRECTORY NAME}.onmicrosoft.com/{CLIENT ID}/Weather.Get");
71+
// The "Weather.Get" scope for accessing the external web API for weather
72+
// data. The following example is based on using Microsoft Entra ID in
73+
// an ME-ID tenant domain (the {APP ID URI} placeholder is found in
74+
// the Entra or Azure portal where the web API is exposed). For any other
75+
// identity provider, use the appropriate scope.
76+
77+
oidcOptions.Scope.Add("{APP ID URI}/Weather.Get");
8278
// ........................................................................
8379

8480
// ........................................................................

0 commit comments

Comments
 (0)