I'm trying to implement SSO for an app using Angular & .NET 2.2. I'm kind of stuck with the refresh token though. The login works and I can see that the service is sending lots if login info, but without the refresh token.
loginAD() {
this._authService.loginPopup()
.subscribe({
next: (r) => {
console.log('Microsofot Login successful');
console.log(r);
this._settings.authorization = {
access_token: r.accessToken,
access_token_expiration: r.expiresOn,
access_token_decoded:undefined,
refresh_token: undefined,
token_type:r.tokenType,
refresh_token_expiration: undefined,
refresh_token_decoded:undefined
};
this.redirectAfterLogin();
},
error: (error) => {
console.error(error)
}
});
}
The app crashes when trying to assign the refresh token, because it's calling jwt_decode on an undefined value. I can see in the network traffic that the refresh token is being sent, but how can I access it from this MSAL AuthenticationResult?