0

I need to log in to an external idp using keycloak. The initiator of the authorization chain is the frontend. To test this chain I request the endpoint:

https://keycloak_uri/realms/realm/protocol/openid-connect/auth?client_id=my-client&redirect_uri=web_page_uri&response_type=code&scope=openid

where the web_page_uri is the uri on the site from which we came to keycloak -> then to the sso login form of the external idp.

The problem is that as a result of authentication, Keycloak creates a session, but in my project the frontend and backend work with the token.

Question: How do I return my keycloak token? How can I return it to the frontend after SSO authentication? I want to know where to find the token immediately after the redirect to the frontend and how to return the Bearer token in the Authorization header.

asked Mar 11, 2024 at 12:20
2
  • Your reproduction steps seems to be missing your frontend and backend steps. You don't access Keycloak directly but first with your frontend. Commented Mar 18, 2024 at 23:17
  • @Franck I have made adjustments to the description. Commented Apr 2, 2024 at 23:43

0

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.