It's standard OIDC stuff. The way it works is:

* user visits app (first page view)
* app is redirected to Keycloak login page
* user is redirected back to app page (second page view)

Further the javascript adapter assumes the app is a single-page app so it doesn't store the tokens so the above flow is repeated for each request even if the user is already authenticated. You can bypass that if you want by manually storing the tokens in html5 storage and init the javascript adapter with it (see the docs for that). Be aware that's a slight security risk as you're storing the tokens which could potentially be leaked.

On 13 September 2016 at 23:08, Bruno Oliveira <bruno@abstractj.org> wrote:
Hi Erik, could you provide the steps to reproduce or some code?

On 2016-09-13, Eric Matte wrote:
> Hi,
>
> We are using the Javascript Adapter from Keycloak for our client authentication.
> However, when accessing a webpage, we receive the information twice.
>
> Here are the request logs received from the client to the server:
>
> 127.0.0.1 - - [13/Sep/2016 10:23:10] "GET /f/services HTTP/1.1" 200 -
> 127.0.0.1 - - [13/Sep/2016 10:23:10] "GET /f/services?prompt=none HTTP/1.1" 200 -
>
> The client is calling a second GET request for a reason that I don't know. Can you explain?
>
> Thank you

> _______________________________________________
> keycloak-user mailing list
> keycloak-user@lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/keycloak-user


--

abstractj
PGP: 0x84DC9914
_______________________________________________
keycloak-user mailing list
keycloak-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/keycloak-user