If you're creating a bug report, please include the followings:
- ABP Framework version: v7.2.2
- UI type: Angular
- DB provider: EF Core
- Identity Server Separated (Angular): Yes
- Exception message and stack trace:
We picked up the below error:
which seems to originate from here:
is there a configuration to maybe set the return URL? we tried setting the identity post-logout URL but that also does not work. - Steps to reproduce the issue:"
- Open the home page on http://localhost:4200/
- Click on the login lint which navigates the user to http://localhost:4200/account/login
- Enter the user name and password then click login which navigates the user back to http://localhost:4200/
- Click logout which navigates the user to https://localhost:44336/Account/Login instead of http://localhost:4200/account/login
environment.ts file sample
import { Environment } from '@abp/ng.core';
const baseUrl = 'http://localhost:4200';
const oAuthConfig = {
issuer: 'https://localhost:44336/',
redirectUri: baseUrl,
clientId: 'MyApp_App',
dummyClientSecret: '1q2w3e*',
scope: 'offline_access MyApp',
showDebugInformation: true,
oidc: false,
requireHttps: true,
};
export const environment = {
production: false,
application: {
baseUrl,
name: 'MyApp',
},
oAuthConfig,
apis: {
default: {
url: 'https://localhost:44360',
rootNamespace: 'MyApp',
},
AbpAccountPublic: {
url: oAuthConfig.issuer,
rootNamespace: 'MyApp',
},
},
} as Environment;
29 Answer(s)
-
0
Hi @krapholo, Let me have a look at this.
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
-
0
Hi @Long.Nguyen,
We are still using Identity server we have not yet migrated to OpenIddict.
our client redirect links have been set on the IDENTITYSERVERCLIENTREDIRECTURIS and IDENTITYSERVERCLIENTPOSTLOGOUTREDIRECTURIS see below images.

However, we are still being redirected to the incorrect login page.
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi, In the provided environment.ts: clientId: 'MyApp_App',
In the database, the ClientId looks different. Could you please double check ?
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
-
0
Hi @Long.Nguyen yes that is correct the environment app name on our side is different in the environment file was just to display the setting that we are using on our side. The client_id all correlates on our side between what we have on the Db as well as what we have on the settings page.
this is the actual client id in our environemnt.ts
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi, Could you please double check connectionstrings in appsettings of both Host and IdentityServer project to see if they connect to the same db ?
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi @Long.Nguyen,
anything else we could possibly try?
also, we upgraded from version 5.2.1 to version 7.2.2 using the migration guides in the documentation.
The redirect used to work on version 5.2.1.
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hmm, everything seems to be fine. Did you try to refresh page, clear any caches ?
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi Long.Nguyen,
I have tried refreshes even doing a hard refresh(ctrl + f5) and also clearing the browser cache as well and that still does not work
could the have been an update in the latest version of ABP that maybe introduced a new configuration that we need to add?
Because we did not make any identity server changes other than upgrading to the latest version of ABP.
Also, why can't identity server find the post logout URL, when it is already being set in the environment.ts file or configure the signout URL on the identity clients page/or use db migrations? currently, none of these options are working at the moment and they worked on the previous version we were on. Please see the logs attached above and below here.
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
hi krapholo
The logs seem to be incomplete.
Please delete Logs.txt first, then run the backend and angular. End the application after reproducing the problem and share Logs.txt.
Try to set log level to Debug.
public class Program { public async static Task<int> Main(string[] args) { Log.Logger = new LoggerConfiguration() .MinimumLevel.Debug() .MinimumLevel.Override("Microsoft.EntityFrameworkCore", LogEventLevel.Warning) .Enrich.FromLogContext() .WriteTo.Async(c => c.File("Logs/logs.txt")) .WriteTo.Async(c => c.Console()) .CreateLogger();Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
-
0
Hi @mahmut.gundogdu,
that is strange can you please send us a sample of the environment.ts file that was used to compare with our one?
also please send us the db logs for identity server tables for the redirect/post-redirect link configuration.
I'm also assuming that the solution uses Identity server instead of openiddict?
Oh, also we are not using the new LeptonX theme yet.
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi @mahmut.gundogdu,
that is strange can you please send us a sample of the environment.ts file that was used to compare with our one?
also please send us the db logs for identity server tables for the redirect/post-redirect link configuration.
I'm also assuming that the solution uses Identity server instead of openiddict?
Oh, also we are not using the new LeptonX theme yet.
- sure. You can create DemoApp with cli (a demo applications don't affect your credit). My Env https://gist.github.com/mahmut-gundogdu/0b5e8facbb106bfd9f7ce46af5fca8ff
I will try with identity-server. I guess,You don't have to set redirect link. just comment the response code. it should works. isn't it @maliming?
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi @mahmut.gundogdu,
I have had a look at the environment.ts file and we have the same configuration but the redirect is still not working as expected.
Please let me know how the identity-server test goes, also please try and use the normal lepton theme we have not migrated to lepton x yet.
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post) -
0
Hi @mahmut.gundogdu,
that is strange can you please send us a sample of the environment.ts file that was used to compare with our one?
also please send us the db logs for identity server tables for the redirect/post-redirect link configuration.
I'm also assuming that the solution uses Identity server instead of openiddict?
Oh, also we are not using the new LeptonX theme yet.
- sure. You can create DemoApp with cli (a demo applications don't affect your credit). My Env https://gist.github.com/mahmut-gundogdu/0b5e8facbb106bfd9f7ce46af5fca8ff
I will try with identity-server. I guess,You don't have to set redirect link. just comment the response code. it should works. isn't it @maliming?
Hi @mahmut.gundogdu, any feedback on the Identity server using the normal Lepton theme test?
Markdown supported.Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)



