I have an application (not reactive) with Angular UI, Zuul and a few Services which are integrated with Okta login (OAuth). This works fine but is stuck after the jwt token expires. Some details about the workflow
- The app URL is pointing to Zuul.
- Zuul redirects the request to Okta. User logs in.
- Okta sends a Bearer token (also a refresh token) back.
- This Bearer token is passed to the UI and is stored as a cookie. With every request the UI sends the Authorization header, with the bearer token.
- This process works fine till the jwt token expires in an hour and then Zuul tries to redirect it to the default login page, which has nothing as we use the okta login.
The questions I have
- Where can the loging page be redirected, if needed https://dev1234.okta.com/oauth2/default?
- How to get a new bearer token based on the refresh token?
- Can I get the new bearer token in Zuul automatically based on the refresh token.If this is not possible what is the best approach?
Have posted this on stackoverflow too with some config/code snippets. Any help is appriciated.