Any updates on this issue?
lepton-x
Trying to replace the logo component using the ReplaceableComponentsService but not working, don't see any change. Replacing other components work fine.
I want to implement a background job using the framework (abp) default implementation. I created a Domain service and I'm passing the tenantid as a parameter and then changing the CurrentTenant. I'm also getting the DbContext from the repository to query the database, but getting an exception saying that it cannot access a disposed context. What is the right approach to be able to create multitenant aware background jobs? I would need to get the user ingo that submitted the job too.
Where do I need to add that code?
I have tried it, and the only way it is working is if I add the tenant's subdomains to the database, otherwise, when I log out I keep getting a 400 error.
CompuCare_App | [ "http://localhost:4200" , "https://ccalp.net" , "https://tenanta.ccalp.net" , "https://westchester.ccalp.net" ]
PreConfigure<AbpOpenIddictWildcardDomainOptions>(options =>
{
options.EnableWildcardDomainSupport = true;
options.WildcardDomainsFormat.Add("https://ccalp.net");
options.WildcardDomainsFormat.Add("https://api.ccalp.net");
options.WildcardDomainsFormat.Add("https://{0}.ccalp.net");
options.WildcardDomainsFormat.Add("https://{0}.ccalp.net/signin-oidc");
options.WildcardDomainsFormat.Add("https://{0}.ccalp.net/signout-callback-oidc");
options.WildcardDomainsFormat.Add("https://{0}.api.ccalp.net");
options.WildcardDomainsFormat.Add("https://{0}.api.ccalp.net/signin-oidc");
options.WildcardDomainsFormat.Add("https://{0}.api.ccalp.net/signout-callback-oidc");
});
2023-03-22 00:35:50.926 +00:00 [INF] Request starting HTTP/1.1 GET http://tenanta.api.ccalp.net/connect/logout?id_token_hint=eyJhbGciOiJSUzI1NiIsImtpZCI6IjBCRUIwRkE3QkJDQ0IwMEM1NDhDRkMxQUQwQkYxMUE0OERCMEZGN0QiLCJ4NXQiOiJDLXNQcDd2TXNBeFVqUHdhMEw4UnBJMndfMzAiLCJ0eXAiOiJKV1QifQ.eyJzdWIiOiJiMGJkNjdlYS01N2UwLWU3ZDEtNTIwOC0zYTBhMGE2ZGQ1OTYiLCJ0ZW5hbnRpZCI6Ijc1MTlmZjEwLTE1MDQtNWQ1Ny1kYTNkLTNhMGEwYTZkYjdjNSIsIm9pX2F1X2lkIjoiYWEyZGJlNjEtOGNmNS1jMDQxLWFkOTAtM2EwYTE4OTM0OGFhIiwiYXpwIjoiQ29tcHVDYXJlX0FwcCIsIm5vbmNlIjoiTkVaUmVuWjJiRkpFZUVWWlRtdEJaRVUwUVVkb00wRjZVVTB4ZEY5dWRsOURjSHBuV1VKd1JqbHlUelZFIiwiYXRfaGFzaCI6IlU4V0FvSTBqUTFOeGNEZHA0bXJic2ciLCJvaV90a25faWQiOiJmNDVhNzBiOS0yZTY0LTJhOTQtN2Y3My0zYTBhMThlYjBiM2IiLCJhdWQiOiJDb21wdUNhcmVfQXBwIiwiZXhwIjoxNjc5NDQ2NTQwLCJpc3MiOiJodHRwczovL3RlbmFudGEuYXBpLmNjYWxwLm5ldC8iLCJpYXQiOjE2Nzk0NDUzNDB9.IxqT1V0i71NTLrWujtDvIWLy9E-BIi6x278Q1m-ztGFJefi4TzoKYb0VgLNWy6GSGjTHsW6t_Dd0DaSuLg5Ulit6hWZEELOCwkKxA3-EiUCjaXQwKcRAJXLYyS6pAfptJTOOe_5LME-rYtbIYYrnGAc2efekGuO1FeayxJaFFACJ77AnySgssUUii3BmkhFRyhTyuiBCU-oH_SaZ7okVvMx2bUBeV05MM8NvjU3Q41PsbRPUnOEwwiukoyH7UTCV6MiHkzqREurtMVOa5bfE76D_ocupqLXdFqcjK-qnoXK2H4tgWhsfAvoAz93_Xb3yCXRXQCvc2nlBTFeuekb0FQ&post_logout_redirect_uri=https%3A%2F%2Ftenanta.ccalp.net&culture=en&ui-culture=en - - 2023-03-22 00:35:50.926 +00:00 [INF] No cached response available for this request. 2023-03-22 00:35:50.927 +00:00 [INF] The request URI matched a server endpoint: "Logout". 2023-03-22 00:35:50.927 +00:00 [INF] The logout request was successfully extracted: { "id_token_hint": "[redacted]", "post_logout_redirect_uri": "https://tenanta.ccalp.net", "culture": "en", "ui-culture": "en" }. 2023-03-22 00:35:51.001 +00:00 [WRN] The logout request was rejected because the identity token used as a hint was issued to a different client. 2023-03-22 00:35:51.001 +00:00 [INF] The response could not be cached for this request. 2023-03-22 00:35:51.019 +00:00 [INF] Request finished HTTP/1.1 GET http://tenanta.api.ccalp.net/connect/logout?id_token_hint=eyJhbGciOiJSUzI1NiIsImtpZCI6IjBCRUIwRkE3QkJDQ0IwMEM1NDhDRkMxQUQwQkYxMUE0OERCMEZGN0QiLCJ4NXQiOiJDLXNQcDd2TXNBeFVqUHdhMEw4UnBJMndfMzAiLCJ0eXAiOiJKV1QifQ.eyJzdWIiOiJiMGJkNjdlYS01N2UwLWU3ZDEtNTIwOC0zYTBhMGE2ZGQ1OTYiLCJ0ZW5hbnRpZCI6Ijc1MTlmZjEwLTE1MDQtNWQ1Ny1kYTNkLTNhMGEwYTZkYjdjNSIsIm9pX2F1X2lkIjoiYWEyZGJlNjEtOGNmNS1jMDQxLWFkOTAtM2EwYTE4OTM0OGFhIiwiYXpwIjoiQ29tcHVDYXJlX0FwcCIsIm5vbmNlIjoiTkVaUmVuWjJiRkpFZUVWWlRtdEJaRVUwUVVkb00wRjZVVTB4ZEY5dWRsOURjSHBuV1VKd1JqbHlUelZFIiwiYXRfaGFzaCI6IlU4V0FvSTBqUTFOeGNEZHA0bXJic2ciLCJvaV90a25faWQiOiJmNDVhNzBiOS0yZTY0LTJhOTQtN2Y3My0zYTBhMThlYjBiM2IiLCJhdWQiOiJDb21wdUNhcmVfQXBwIiwiZXhwIjoxNjc5NDQ2NTQwLCJpc3MiOiJodHRwczovL3RlbmFudGEuYXBpLmNjYWxwLm5ldC8iLCJpYXQiOjE2Nzk0NDUzNDB9.IxqT1V0i71NTLrWujtDvIWLy9E-BIi6x278Q1m-ztGFJefi4TzoKYb0VgLNWy6GSGjTHsW6t_Dd0DaSuLg5Ulit6hWZEELOCwkKxA3-EiUCjaXQwKcRAJXLYyS6pAfptJTOOe_5LME-rYtbIYYrnGAc2efekGuO1FeayxJaFFACJ77AnySgssUUii3BmkhFRyhTyuiBCU-oH_SaZ7okVvMx2bUBeV05MM8NvjU3Q41PsbRPUnOEwwiukoyH7UTCV6MiHkzqREurtMVOa5bfE76D_ocupqLXdFqcjK-qnoXK2H4tgWhsfAvoAz93_Xb3yCXRXQCvc2nlBTFeuekb0FQ&post_logout_redirect_uri=https%3A%2F%2Ftenanta.ccalp.net&culture=en&ui-culture=en - - - 302 0 - 75.1705ms 2023-03-22 00:35:51.071 +00:00 [INF] Request starting HTTP/1.1 GET http://tenanta.api.ccalp.net/Error?httpStatusCode=400 - -
I don't think the following is working:
PreConfigure<AbpOpenIddictWildcardDomainOptions>(options =>
{
options.EnableWildcardDomainSupport = true;
options.WildcardDomainsFormat.Add("https://ccalp.net");
options.WildcardDomainsFormat.Add("https://api.ccalp.net");
options.WildcardDomainsFormat.Add("https://{0}.ccalp.net/signin-oidc");
options.WildcardDomainsFormat.Add("https://{0}.api.ccalp.net/signin-oidc");
options.WildcardDomainsFormat.Add("https://{0}.ccalp.net/signout-callback-oidc");
options.WildcardDomainsFormat.Add("https://{0}.api.ccalp.net/signout-callback-oidc");
});
We have over 50 tenants (subdomains) and I can't add them all here or in the database, it is just not maintainable. We need the wildcard to work.
What would be the right configuration both for the database and for the code?
The client (angular) application domain is: "ccalp.net" (localhost:4200) The API domain is: "api.ccalp.net" (localhost:44349)
And each tenant will be in their own subdomain: [tenant-database].ccalp.net [tenant-database].api.ccalp.net
Please we need this resolved ASAP.
Thank you.
Is this what you are looking for? IS there a way I can upload the entire log file?
2023-03-20 16:45:38.303 +00:00 [INF] Request finished HTTP/1.1 GET http://api.ccalp.net/api/abp/application-localization?cultureName=en&onlyDynamics=false - - - 200 - application/json;+charset=utf-8 33.4436ms 2023-03-20 16:45:38.894 +00:00 [INF] Request starting HTTP/1.1 GET http://api.ccalp.net/connect/authorize?response_type=code&client_id=CompuCare_App&state=SXozejByamcxam9ibGMxUndueUtPdmdlekpLSDlzeExGUmMySFBhX3RxbV9H&redirect_uri=https%3A%2F%2Fccalp.net&scope=openid%20offline_access%20CompuCare&code_challenge=mby31qqbtuatfUUDCR6Llb2izIroRqr6qE-jj8Ggoos&code_challenge_method=S256&nonce=SXozejByamcxam9ibGMxUndueUtPdmdlekpLSDlzeExGUmMySFBhX3RxbV9H&culture=en&ui-culture=en - - 2023-03-20 16:45:38.894 +00:00 [INF] No cached response available for this request. 2023-03-20 16:45:38.922 +00:00 [INF] The request URI matched a server endpoint: "Authorization". 2023-03-20 16:45:38.923 +00:00 [INF] The authorization request was successfully extracted: { "response_type": "code", "client_id": "CompuCare_App", "state": "SXozejByamcxam9ibGMxUndueUtPdmdlekpLSDlzeExGUmMySFBhX3RxbV9H", "redirect_uri": "https://ccalp.net", "scope": "openid offline_access CompuCare", "code_challenge": "mby31qqbtuatfUUDCR6Llb2izIroRqr6qE-jj8Ggoos", "code_challenge_method": "S256", "nonce": "SXozejByamcxam9ibGMxUndueUtPdmdlekpLSDlzeExGUmMySFBhX3RxbV9H", "culture": "en", "ui-culture": "en" }. 2023-03-20 16:45:38.950 +00:00 [INF] Client validation failed because 'https://ccalp.net' was not a valid redirect_uri for CompuCare_App. 2023-03-20 16:45:38.950 +00:00 [INF] The authorization request was rejected because the redirect_uri was invalid: 'https://ccalp.net'. 2023-03-20 16:45:38.972 +00:00 [INF] The response could not be cached for this request. 2023-03-20 16:45:38.982 +00:00 [INF] Request finished HTTP/1.1 GET http://api.ccalp.net/connect/authorize?response_type=code&client_id=CompuCare_App&state=SXozejByamcxam9ibGMxUndueUtPdmdlekpLSDlzeExGUmMySFBhX3RxbV9H&redirect_uri=https%3A%2F%2Fccalp.net&scope=openid%20offline_access%20CompuCare&code_challenge=mby31qqbtuatfUUDCR6Llb2izIroRqr6qE-jj8Ggoos&code_challenge_method=S256&nonce=SXozejByamcxam9ibGMxUndueUtPdmdlekpLSDlzeExGUmMySFBhX3RxbV9H&culture=en&ui-culture=en - - - 302 0 - 88.2534ms 2023-03-20 16:45:39.028 +00:00 [INF] Request starting HTTP/1.1 GET http://api.ccalp.net/Error?httpStatusCode=400 - - 2023-03-20 16:45:39.028 +00:00 [INF] No cached response available for this request. 2023-03-20 16:45:39.056 +00:00 [INF] Executing endpoint 'Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared)' 2023-03-20 16:45:39.056 +00:00 [INF] Route matched with {action = "Index", controller = "Error", area = "", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Microsoft.AspNetCore.Mvc.IActionResult] Index(Int32) on controller Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared). 2023-03-20 16:45:39.066 +00:00 [INF] Executing ViewResult, running view ~/Views/Error/Default.cshtml. 2023-03-20 16:45:39.161 +00:00 [INF] Executed ViewResult - view ~/Views/Error/Default.cshtml executed in 94.2435ms. 2023-03-20 16:45:39.161 +00:00 [INF] Executed action Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared) in 104.8771ms 2023-03-20 16:45:39.161 +00:00 [INF] Executed endpoint 'Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared)' 2023-03-20 16:45:39.161 +00:00 [INF] The response could not be cached for this request. 2023-03-20 16:45:39.161 +00:00 [INF] Request finished HTTP/1.1 GET http://api.ccalp.net/Error?httpStatusCode=400 - - - 400 - text/html;+charset=utf-8 133.2881ms