You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have created our own authentication strategy in order to automatically renew JWT, details can be see here. However, it appears that if the original token does contain some additional payload, the additional fields are lost in the newly generated token.
It seems to be caused by getPayload() because even if the input authentication result contains the payload it is not taken into account when generating the new token.
I've tested the approach by extending the AuthenticationService class, it appears to work but I needed to remove from the result payload ['aud', 'iss'] otherwise it conflicts with default token options in config I guess. Here is the error message: create: Bad "options.expiresIn" option the payload already has an "exp" property.
We have created our own authentication strategy in order to automatically renew JWT, details can be see here. However, it appears that if the original token does contain some additional payload, the additional fields are lost in the newly generated token.
It seems to be caused by getPayload() because even if the input authentication result contains the payload it is not taken into account when generating the new token.
May we suggest to do something like this:
The text was updated successfully, but these errors were encountered: