Closed HofmT closed 5 years ago
@HofmT This is not the correct approach. You can't set the idToken that you got from outside in adal. If you already have an id_token, what is you are trying to achieve from adal? You may use the login_hint/sid from the id_token to get the access token. Can you please elaborate your use case?
@nehaagrawal Ok, I think I had a wrong understanding of ADAL and therefore tried to misuse it. I will therefore close it.
Dear all,
for our SPA we are using ADAL for authentication. Now we have a scenario where we get a valid JWT from another service (meaning outside of the ADAL login procedure). I would like to set this token manually into the ADAL library so that we can take advantage of the other methods provided by ADAL, such as getCachedToken()
So I tried the following. I set the token inside the URL like this: http://127.0.0.1:8081/#id_token=eyJhbGciOiJSUzI1NiIsInR(..)ZF3QtQNA
and inside JavaScript I then execute the handleWindowCallback by ADAL assuming that ADAL would retrieve the token from the URL and store it locally inside the locatStorage. Unfortunately that did not work. So my question is: Is the approach in general correct or do I have to take another one?
Thanks for any help! Kind regards Tobias