Activities of "bqabani"

Updated:

https://drive.google.com/file/d/1vQTsEMRmB9gVlrf1OqAYlnfw-K0WyU3u/view?usp=sharing

Done:

Updated Log:

https://drive.google.com/file/d/1Uwib25_aYeCnefpyUzAS2crUDT39vpUT/view?usp=sharing

Waiting for your response

  • ABP Framework version: v9.0.2
  • UI Type: Angular
  • Database System: EF Core (SQL Server)
  • Tiered: yes
  • Auth Server Separated (for Angular): no
  • Exception message and full stack trace:

The token request was successfully extracted: { "grant_type": "authorization_code", "code": "[redacted]", "client_id": "AppName_Swagger", "redirect_uri": "https://my-domain/swagger/oauth2-redirect.html" }

The response was successfully returned as a JSON document: { "error": "invalid_grant", "error_description": "The specified token is invalid.", "error_uri": "https://documentation.openiddict.com/errors/ID2004" }.

  • Steps to reproduce the issue:
  • Create a new Abp app
  • Deploy it to IIS
  • Add SSL
  • Configure urls + run DbMigrator + configure appSettings
  • Test Login on HostApp : worked
  • Logout : worked
  • Open Swagger: try Authorize (Login) : select scope (appname) ,
  • Then redirected to login page automatically, then input credentials
  • redirected back to swagger with error: auth errorError: response status is 400, error: invalid_grant, description: The specified token is invalid.
  • the same scenario for angular : error : infinite redirection between Host and angular , with same error above
  • but login directly using MVC app : worked

Please note that there is no changes on code has been made

for more info, I added log here: https://drive.google.com/file/d/1KVqn0XN3wjbAsq4oPMxAiH3QrzfVzSOb/view?usp=sharing

Yes It was solved, Thank you

The solution was to create a reference for identity service module (not the administration service module)

using : https://docs.abp.io/en/commercial/latest/startup-templates/microservice/synchronous-interservice-communication

The solution was to create a reference for identity service module (not the administration service module)

using : https://docs.abp.io/en/commercial/latest/startup-templates/microservice/synchronous-interservice-communication

Thank you for your prompt answer!

Please provide me with more details, I cannot find IPermissionIntegrationService I searched for it all my solution, Not sure which dependency should I use,

And finally Plaese provide with a blog or documentation reference for that is possible

Thank you

  • ABP Framework version: v7.3.0
  • UI Type: Angular
  • Database System: EF Core (SQL Server)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes **Micro service **

I have a micro service (for example called Products Microservice) in that microservice I would like to check if a specific user has a permission, this user is not the current user, (I have his email only)

Kindly suggest all available solutions, the best solution that does not make me made connection to administration.

I think I need to use: var rs = await authorizationService.AuthorizeAsync(ClaimsPrincipal, requiredPolicy); but I do not have the (ClaimsPrincipal) and how can I get an instance of it related a specific user ? and is this good solution ?

Kindly advice

Thank you

  • ABP Framework version: v5.0.0
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Instances cannot be resolved and nested lifetimes cannot be created from this LifetimeScope as it (or one of its parent scopes) has already been disposed.
  • Steps to reproduce the issue:"

I have a customer scenario, so the application when it starts, it waiting for external event (using a third party), when the event is happend, But when the event is triggered, I should be able to use dependency injection, When I try to access the Service Provider, I get the error above, here is a code sample:

public override void OnApplicationInitialization(ApplicationInitializationContext context)
        {
            var configuration = context.GetConfiguration();  
            var SelfUrl = configuration["App:SelfUrl"];
            var app = context.GetApplicationBuilder();
            var env = context.GetEnvironment();
            var buses = context.ServiceProvider.GetServices<ServiceBusProcessor>();
            foreach (var processor1 in buses)
            {
                processor1.ProcessMessageAsync += (ProcessMessageEventArgs args) => ProcessMessageHandler(context, args);
                processor1.ProcessErrorAsync += ErrorHandler;
                processor1.StartProcessingAsync().GetAwaiter().GetResult();
            }
    }
    private async Task ProcessMessageHandler(ApplicationInitializationContext context, ProcessMessageEventArgs args) { 
       var serviceProvider = context.ServiceProvider ; 
       using (var scope = serviceProvider.CreateScope())
       {
           var handler = serviceProvider.GetService<TraineeProfileUpdateJobHandler>(); // this is throws an error
           var handler2 = scope.ServiceProvider.GetService<TraineeProfileUpdateJobHandler>(); // this is throws an error
            await handler.ExecuteAsync(parsed);
        }
    }
  • ABP Framework version: v5.0.0
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:

2023-05-21 17:07:47.946 +03:00 [ERR] An exception was thrown while deserializing the token. Microsoft.AspNetCore.Antiforgery.AntiforgeryValidationException: The antiforgery token could not be decrypted. ---> System.Security.Cryptography.CryptographicException: The key {d8fbc7f5-259b-455a-b1f4-89121eb1d364} was not found in the key ring. For more information go to http://aka.ms/dataprotectionwarning at Microsoft.AspNetCore.DataProtection.KeyManagement.KeyRingBasedDataProtector.UnprotectCore(Byte[] protectedData, Boolean allowOperationsOnRevokedKeys, UnprotectStatus& status) at Microsoft.AspNetCore.DataProtection.KeyManagement.KeyRingBasedDataProtector.DangerousUnprotect(Byte[] protectedData, Boolean ignoreRevocationErrors, Boolean& requiresMigration, Boolean& wasRevoked) at Microsoft.AspNetCore.DataProtection.KeyManagement.KeyRingBasedDataProtector.Unprotect(Byte[] protectedData) at Microsoft.AspNetCore.Antiforgery.DefaultAntiforgeryTokenSerializer.Deserialize(String serializedToken) --- End of inner exception stack trace --- at Microsoft.AspNetCore.Antiforgery.DefaultAntiforgeryTokenSerializer.Deserialize(String serializedToken) at Microsoft.AspNetCore.Antiforgery.DefaultAntiforgery.GetCookieTokenDoesNotThrow(HttpContext httpContext)

Showing 1 to 10 of 46 entries
Made with ❤️ on ABP v9.2.0-preview. Updated on January 20, 2025, 07:44