File tree Expand file tree Collapse file tree 1 file changed +0
-6
lines changed Expand file tree Collapse file tree 1 file changed +0
-6
lines changed Original file line number Diff line number Diff line change @@ -102,23 +102,17 @@ public static IServiceCollection AddProtectedWebApi(
102102 /// </summary>
103103 /// <param name="services">Service collection to which to add authentication</param>
104104 /// <param name="configuration">Configuration</param>
105- /// <param name="scopes">Optional parameters. If not specified, the token used to call the protected API
106- /// will be kept with the user's claims until the API calls a downstream API. Otherwise the account for the
107- /// user is immediately added to the token cache</param>
108105 /// <returns></returns>
109106 public static IServiceCollection AddProtectedApiCallsWebApis (
110107 this IServiceCollection services ,
111108 IConfiguration configuration ,
112- IEnumerable < string > scopes = null ,
113109 string configSectionName = "AzureAd" )
114110 {
115111 services . AddTokenAcquisition ( ) ;
116112 services . AddHttpContextAccessor ( ) ;
117113 services . Configure < ConfidentialClientApplicationOptions > ( options => configuration . Bind ( configSectionName , options ) ) ;
118114 services . Configure < JwtBearerOptions > ( AzureADDefaults . JwtBearerAuthenticationScheme , options =>
119115 {
120- // If you don't pre-provide scopes when adding calling AddProtectedApiCallsWebApis, the On behalf of
121- // flow will be delayed (lazy construction of MSAL's application
122116 options . Events . OnTokenValidated = async context =>
123117 {
124118 context . HttpContext . StoreTokenUsedToCallWebAPI ( context . SecurityToken as JwtSecurityToken ) ;
You can’t perform that action at this time.
0 commit comments