This is a template project. app-pro -tiered -blazor-server -ef -postgres
I'm sending shiwei.liang@volosoft.com a copy of my project for another issue. Do you want me to send it to you also?
Same results
Start the projects Login Click on Identity Server menu Click on API Scopes menu or any other submenu
Lepton X
Select Api Scopes on the Identity Server submenu.
Blazor project terminal output:
[13:19:46 INF] Sending HTTP request GET https://localhost:44396/api/identity-server/identity-resources/all?api-version=1.0
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 WRN] Could not find the localization resource LeptonX on the remote server!
[13:19:46 INF] Received HTTP response headers after 5.0001ms - 500
[13:19:46 INF] End processing HTTP request after 5.1081ms - 500
[13:19:46 WRN] Unhandled exception rendering component: An internal error occurred during your request!
Volo.Abp.Http.Client.AbpRemoteCallException: An internal error occurred during your request!
at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase1.ThrowExceptionForResponseAsync(HttpResponseMessage response) at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase
1.RequestAsync(ClientProxyRequestContext requestContext)
at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase1.RequestAsync[T](ClientProxyRequestContext requestContext) at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase
1.RequestAsync[T](String methodName, ClientProxyRequestTypeValue arguments)
at Volo.Abp.IdentityServer.ClientProxies.IdentityResourcesClientProxy.GetAllListAsync()
at Volo.Abp.IdentityServer.Blazor.Pages.IdentityServer.ClientManagement.GetAllResources()
at Volo.Abp.IdentityServer.Blazor.Pages.IdentityServer.ClientManagement.OnInitializedAsync()
at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync()
at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle, ComponentState owningComponentState)
[13:19:46 ERR] Unhandled exception in circuit 'tZUrWRPA0VcJtKnV9mD-p1vgstldgJ0U9IrWEt0MWR8'.
Volo.Abp.Http.Client.AbpRemoteCallException: An internal error occurred during your request!
at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase1.ThrowExceptionForResponseAsync(HttpResponseMessage response) at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase
1.RequestAsync(ClientProxyRequestContext requestContext)
at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase1.RequestAsync[T](ClientProxyRequestContext requestContext) at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase
1.RequestAsync[T](String methodName, ClientProxyRequestTypeValue arguments)
at Volo.Abp.IdentityServer.ClientProxies.IdentityResourcesClientProxy.GetAllListAsync()
at Volo.Abp.IdentityServer.Blazor.Pages.IdentityServer.ClientManagement.GetAllResources()
at Volo.Abp.IdentityServer.Blazor.Pages.IdentityServer.ClientManagement.OnInitializedAsync()
at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync()
at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle, ComponentState owningComponentState)
I think the issue is that the OpenIdDict token is not being flushed properly. Just my thoughts.
After I waited about 5 minutes after logging out and logging back it...the page updated. Here is the new output of the Blazor project terminal.
[11:23:45 INF] Request starting HTTP/1.1 GET https://localhost:44369/api/account/profile-picture-file/3a095f24-ad00-19e9-f711-dbdf65903d48?api-version=1.0 - - [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessRequestContext was successfully processed by OpenIddict.Validation.AspNetCore.OpenIddictValidationAspNetCoreHandlers+ResolveRequestUri. [11:23:45 DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+ResolveRequestUri. [11:23:45 DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.OpenIddictServerHandlers+InferEndpointType. [11:23:45 DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by Volo.Abp.Account.Web.Pages.Account.OpenIddictImpersonateInferEndpointType. [11:23:45 DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+ValidateTransportSecurityRequirement. [11:23:45 DBG] The event OpenIddict.Server.OpenIddictServerEvents+ProcessRequestContext was successfully processed by OpenIddict.Server.AspNetCore.OpenIddictServerAspNetCoreHandlers+ValidateHostHeader. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.AspNetCore.OpenIddictValidationAspNetCoreHandlers+ValidateHostHeader. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+ResolveServerConfiguration. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+EvaluateValidatedTokens. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.AspNetCore.OpenIddictValidationAspNetCoreHandlers+ExtractAccessTokenFrom AuthorizationHeader. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.AspNetCore.OpenIddictValidationAspNetCoreHandlers+ExtractAccessTokenFrom BodyForm. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.AspNetCore.OpenIddictValidationAspNetCoreHandlers+ExtractAccessTokenFrom QueryString. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+ValidateRequiredTokens. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ResolveTokenValidationParameters. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ValidateIdentityModelToken. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+NormalizeScopeClaims. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+MapInternalClaims. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ValidatePrincipal. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ValidateExpirationDate. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ValidateAudience. [11:23:45 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+ValidateAccessToken. [11:23:45 DBG] AuthenticationScheme: OpenIddict.Validation.AspNetCore was successfully authenticated. [11:23:45 INF] Executing endpoint 'Volo.Abp.Account.AccountController.GetProfilePictureFileAsync (Volo.Abp.Account.Pro.Public.HttpApi)' [11:23:45 INF] Route matched with {area = "account", action = "GetProfilePictureFile", controller = "Account", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Volo.Abp.Content.IRemoteStreamC ontent] GetProfilePictureFileAsync(System.Guid) on controller Volo.Abp.Account.AccountController (Volo.Abp.Account.Pro.Public.HttpApi). [11:23:45 INF] Executing ObjectResult, writing value of type 'Volo.Abp.Content.RemoteStreamContent'. [11:23:45 INF] Executed action Volo.Abp.Account.AccountController.GetProfilePictureFileAsync (Volo.Abp.Account.Pro.Public.HttpApi) in 3.6278ms [11:23:45 INF] Executed endpoint 'Volo.Abp.Account.AccountController.GetProfilePictureFileAsync (Volo.Abp.Account.Pro.Public.HttpApi)' [11:23:45 INF] Request finished HTTP/1.1 GET https://localhost:44369/api/account/profile-picture-file/3a095f24-ad00-19e9-f711-dbdf65903d48?api-version=1.0 - - - 200 1370 image/jpeg 6.3834ms
Here is the terminal output for the ApiHost server:
[11:19:38 DBG] Getting not cache granted permissions from the repository for this provider name,key: R,admin [11:19:38 DBG] Setting the cache items. Count: 91 [11:19:38 DBG] Finished setting the cache items. Count: 91 [11:19:38 DBG] PermissionStore.GetCacheItemAsync: pn:C,pk:ControlCenter_BlazorServerTiered,n:AbpIdentity.UserLookup [11:19:38 DBG] Not found in the cache: pn:C,pk:ControlCenter_BlazorServerTiered,n:AbpIdentity.UserLookup [11:19:38 DBG] Getting all granted permissions from the repository for this provider name,key: C,ControlCenter_BlazorServerTiered [11:19:38 DBG] Setting the cache items. Count: 138 [11:19:38 DBG] Finished setting the cache items. Count: 138 [11:19:38 DBG] Executed AbpApplicationConfigurationAppService.GetAsync(). [11:19:38 DBG] Added 0 entity changes to the current audit log
I'm also seeing this in the AuthServer terminal.
[11:14:30 INF] The authentication demand was rejected because the token was expired. [11:14:30 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ValidateExpirationDate. [11:14:30 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ValidateTokenContext was marked as rejected by OpenIddict.Validation.OpenIddictValidationHandlers+Protection+ValidateExpirationDate. [11:14:30 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was successfully processed by OpenIddict.Validation.OpenIddictValidationHandlers+ValidateAccessToken. [11:14:30 DBG] The event OpenIddict.Validation.OpenIddictValidationEvents+ProcessAuthenticationContext was marked as rejected by OpenIddict.Validation.OpenIddictValidationHandlers+ValidateAccessToken. [11:14:30 INF] OpenIddict.Validation.AspNetCore was not authenticated. Failure message: An error occurred while authenticating the current request. [11:14:30 INF] OpenIddict.Validation.AspNetCore was not authenticated. Failure message: An error occurred while authenticating the current request. [11:14:30 INF] Executing endpoint 'Volo.Abp.Account.AccountController.GetProfilePictureFileAsync (Volo.Abp.Account.Pro.Public.HttpApi)' [11:14:30 INF] Route matched with {area = "account", action = "GetProfilePictureFile", controller = "Account", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Volo.Abp.Content.IRemoteStreamC ontent] GetProfilePictureFileAsync(System.Guid) on controller Volo.Abp.Account.AccountController (Volo.Abp.Account.Pro.Public.HttpApi). [11:14:30 INF] Executing ObjectResult, writing value of type 'Volo.Abp.Content.RemoteStreamContent'. [11:14:30 INF] Executed action Volo.Abp.Account.AccountController.GetProfilePictureFileAsync (Volo.Abp.Account.Pro.Public.HttpApi) in 4.7523ms [11:14:30 INF] Executed endpoint 'Volo.Abp.Account.AccountController.GetProfilePictureFileAsync (Volo.Abp.Account.Pro.Public.HttpApi)'