MSAL for SPA -> Server side #3822
Replies: 3 comments 4 replies
-
We don't currently support this scenario. It sounds like your backend is the one that will be both exchanging the code for tokens as well as actually using the tokens. So why not have the backend also generate the authorization url? Can you expand on why you want the SPA to do the work? |
Beta Was this translation helpful? Give feedback.
-
@tnorling Any update on this feature... Is this feature out almost after 2.5 years? |
Beta Was this translation helpful? Give feedback.
-
@tnorling We are also in need of this functionality. We have three areas we are working with. 1) A web site with backend code that populates pages for the logged in user. 2) Web components on each page written in vue js that interact with the API server. 3) An API server written in .net. What is the best way to implement this setup using MSAL within the vue js components? |
Beta Was this translation helpful? Give feedback.
-
Hello,
We are unable to implement case where authentication starts on the front-end and then completes on the backend (what I thought is one of the very common use cases). All the SPA examples and documentation use cases (from what I read) either run everything on a backend or front-end. Nevertheless we want a user to authorize access to their login in an SPA, generating authorization code and then send it to our backend where we exchange it for refresh and access tokens.
Currently the .js library seems (from what I read all over SO and other places) to hide the refresh token and keep it for itself.
How can we handle our scenario? We work with other authentication libraries such as from Google where this is very common use case but I didn't find anything from MS how to get the authorization code and exchange it on a backend.
Beta Was this translation helpful? Give feedback.
All reactions