- ABP Framework version: v6.0.0_rc.2
- UI type: Angular
- DB provider: EF Core
- Tiered (MVC) or Identity Server Separated (Angular): no
Trying to authorize from the Swagger UI is giving errors which I have not seen before. If I launch the angular project and login, I can eventually get the swagger UI to authenticate but only because I am already logged in.
This is the first error I received.
This is the second issue I encountered. Notice the windows login prompt for accessing the site. If I am already logged in via Angular, I can hit cancel on this and I have access to the authorized endpoints. However, nothing I enter in the prompted authentication works so far.
6 Answer(s)
-
0
As a follow up, I made a couple of changes to the Swagger application configuration and it now works. I am not sure why this change removed the windows authentication prompt, but the result now matches the user experience we had with identity server.
I changed the client type to confidential and added a configuration variable to set the secret. With this in place, things now work just like they did in 5.x for me.
-
0
It looks like you are using both basic and OAuth authentication, I don't think you can use both
-
0
@liangshiwei I am not following your answer. The default code provided in the template application exhibited the problem described above in my initial post. Are you saying that the initial application has a problem or the changes I highlighted are a problem. Please note, it was not working until I made the changes I highlighted. It is working as expected after those changes.
-
0
I will check it out.
-
0
Hi,
Could you share the steps to reproduce? thanks.
-
0
Hi,
After my check, you don't need to type the secret on the swagger UI.
Because the swagger client type is public. this is designed by Openiddict.
Of course, you can change it just like you did if you want use the client secret,