[keycloak-user] AJAX(xhr) calls

Thomas Darimont thomas.darimont at googlemail.com
Wed May 11 11:28:09 EDT 2016


Hi Gregory,

have a look at this:
https://issues.jboss.org/browse/KEYCLOAK-2962?jql=project%20%3D%20KEYCLOAK%20AND%20text%20~%20JSF

Cheers,
Thomas

2016-05-11 16:35 GMT+02:00 Gregory Orciuch <g.orciuch at gmail.com>:

> Hi,
>
> we do protect our app with the KeyCloak wildfly adapter. Generally it's
> jee app + JSF (primefaces).
>
> The case is, when SSO session is expired, the user on the webpage can
> still try to make AJAX call to JSF application. In same time, adapter
> intercepts and wants the request to go to keycloack page for redirection to
> relogin (http 302).
>
> From what I read, ajax does not well support the 302 response and in order
> to make browser to really redirect response should contain an XML with
> something like
>
> <?xml version=\"1.0\" encoding=\"UTF-8\"?>
> <partial-response>
>   <redirect url="http://keycloak:8080/auth/..."></redirect>
> </partial-response>
>
> Is there a way to make KeyCloak aware of AJAX calls ? and not produce 302 ?
> I could even contribute and write some code in order to support such
> configuration. Just name the class where I should look for.
>
> Cheers,
> Gregory
>
> _______________________________________________
> keycloak-user mailing list
> keycloak-user at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/keycloak-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/keycloak-user/attachments/20160511/c58f15f5/attachment.html 


More information about the keycloak-user mailing list