The ITfoxtec.Identity.BlazorWebAssembly.OpenidConnect blazor sample fails to retrieve metadata

141 Views Asked by At

I was trying to get the ITfoxtec.Identity.BlazorWebAssembly.OpenidConnect module to work. The sample compiles but does not work because the metadata request is resected due to a CORS violation. I was using the samples provided. the server metadata seems good but the client gets rejected.

1

There are 1 best solutions below

0
Anders Revsgaard On

The OIDC/Identity Server you are using need to accept calls from the domain on which the Blazor client application is hosted. The OIDC code insight the Blazor client calls both the OIDC Discovery endpoint and Token endpoint on the OIDC/Identity Server. These calls need to be enabled by the CORS configuration.

You should be able to run the sample locally and login using a FoxIDs test user. Thereby, you should be able to see the authentication flow.