<div dir="ltr">Thank you very much, it works! At least I have one question: How do I know which identity provider is used? Lets say I log in with facebook, how does my Java code know that it must send the rest-call to the facebook-endpoint?<div><br></div><div>Thanks,</div><div>Andreas</div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-03-04 11:11 GMT+01:00 Stian Thorgersen <span dir="ltr"><<a href="mailto:sthorger@redhat.com" target="_blank">sthorger@redhat.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">To read the token the user has to have the broker.read-token permission. The client also needs a scope on it. Please take a look at <a href="http://keycloak.github.io/docs/userguide/keycloak-server/html/identity-broker.html#d4e2198" target="_blank">http://keycloak.github.io/docs/userguide/keycloak-server/html/identity-broker.html#d4e2198</a></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On 3 March 2016 at 20:28, Andreas Cserinko <span dir="ltr"><<a href="mailto:a.cserinko@gmail.com" target="_blank">a.cserinko@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><font color="#000000" face="arial, helvetica, sans-serif">Hey guys!</font><div><font color="#000000" face="arial, helvetica, sans-serif"><br></font></div><div><font color="#000000" face="arial, helvetica, sans-serif">I've been trying since a few days to make a rest-call to '/realms/myrealm/broker/google/token'</font></div><div><font color="#000000" face="arial, helvetica, sans-serif">from my Java-code. But when I send the request, the response says that the token is invalid. I have no clue what token to use. </font></div><div><font color="#000000" face="arial, helvetica, sans-serif"><br></font></div><div><font color="#000000" face="arial, helvetica, sans-serif">Can anybody please describe the flow of how to obtain the right tokens, or post some examples how to solve the problem. I looked at the example on GitHub (<a href="https://github.com/keycloak/keycloak/tree/master/examples/broker/facebook-authentication" target="_blank">https://github.com/keycloak/keycloak/tree/master/examples/broker/facebook-authentication</a>) but this example don't fit my needs because it is client-side.</font></div><div><font color="#000000" face="arial, helvetica, sans-serif"><br></font></div><div><font color="#000000" face="arial, helvetica, sans-serif">Any help would be appreciated, thanks!</font></div><div><font color="#000000" face="arial, helvetica, sans-serif"><br></font></div><div><font color="#000000" face="arial, helvetica, sans-serif">Thank you,</font></div><div><font color="#000000" face="arial, helvetica, sans-serif">Andreas</font></div></div>
<br></div></div>_______________________________________________<br>
keycloak-user mailing list<br>
<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/keycloak-user" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-user</a><br></blockquote></div><br></div>
</blockquote></div><br></div>