-
Notifications
You must be signed in to change notification settings - Fork 975
Description
Hello,
I have implemented the AppAuth library with the Keycloak SSO and I get refresh tokens that expire within 30 minutes after the token request. Therefore, when I try to get a new access token by calling the 'performActionWithFreshTokens' function 30 minutes after calling the 'performTokenRequest' function, I get the following exception :
{"type":2,"code":2002,"error":"invalid_grant","errorDescription":"Refresh token expired","errorUri":""}
I tried to dodge this problem by getting an offline token by specifying 'offline_access' in setScope in the AuthorizationRequest builder but I get the following exception:
AuthorizationException: {"type":0,"code":5,"errorDescription":"JSON deserialization error"}
The "offline_access" is however supported in the SSO configuration.
My questions are :
- do you happen to kwno why do my refresh tokens have a validity time of only 30 minutes?
- why do I get the "JSON deserialization" error even if my Keycloak configuration allows for offline tokens?
Thank you for your time!