Replies: 1 comment
-
Refit-using OC API client: https://github.com/Lombiq/Orchard-Core-API-Client. Perhaps you can take some inspiration? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
For one of our company application, with some of my colleagues, we try we setup an application with these requirements:
An OC instance used as Authentication Autority, with OpenId module enabled and OpenId Application setup.
An ASP.NET REST api with authorization using OpenIddict and Code flow (Client Id coming from OC).
Swagger configured to redirect to login page and obtain authentication.
Now, we struggle a bit to merge it all in an application that mixes everything.
How does the current User auth is passed to Refit calling the api?
I would have liked some of your insights, if someone already had to do this kind of communications between client and api, passing Access token with Refit and AuthroizationMessageHandler.
I found some interesting docs and articles, but none using Refit:
https://learn.microsoft.com/en-us/aspnet/core/blazor/security/blazor-web-app-with-oidc
https://github.com/openiddict/openiddict-samples/tree/dev/samples/Balosar
https://damienbod.com/2024/04/15/implement-a-secure-blazor-web-application-using-openid-connect-and-security-headers/
I also found some discussions on the .NET Discord and the aspnet repo : dotnet/aspnetcore#56779
Thank you for your help.
/cc @kevinchalet
Beta Was this translation helpful? Give feedback.
All reactions