[keycloak-user] Login without Keycloak Login Page

ruiwp13 ruiwp_93 at hotmail.com
Mon Dec 19 11:32:36 EST 2016


Bill Burke wrote
> I looked at the image, specifically the @Path("/login") JAX-RS method.  
> What you are attempting will just not work.  Period.  I don't think you 
> understand how basic servlet, JAX-RS, and HTTP works along with how Open 
> ID Connection works.  OpenID Connect (and SAML) require browser 
> redirects.  In looking at your code, you're expecting authenticate() to 
> redirect the browser to keycloak, have the user login, then redirect 
> back.  This just doesn't do what you expect.  And it shouldn't.   
> Calling servletRequest.authenticate() sets a 302 response with a 
> Location header pointing back to the server.   That's it...  You 
> actually override what authenticate() did by returning a JAX-RS response.
> _______________________________________________
> keycloak-user mailing list

> keycloak-user at .jboss

> https://lists.jboss.org/mailman/listinfo/keycloak-user

Thank you for the answer Bill,

It does redirect me to keycloak login page and then back to my login page.
The redirect back is managed by keycloak. It redirects back to the
application after login. It may have something wrong when I do the
authenticate(), but it does redirect me to Keycloak login page. If I knew
how everything worked I wasn't here asking for help eheh. I came here to
know what I was doing wrong or if it was a keycloak problem.

What is the correct way to do it then? 



--
View this message in context: http://keycloak-user.88327.x6.nabble.com/Login-without-Keycloak-Login-Page-tp1974p2045.html
Sent from the keycloak-user mailing list archive at Nabble.com.


More information about the keycloak-user mailing list