So do I need to create two applications for the realm then? One for the
JAX-RS part with "Access Type" of "Bearer Only" and one for the
Angular UI
with type "Public"?
2015-04-16 11:18 GMT+02:00 Stian Thorgersen <stian(a)redhat.com>:
----- Original Message -----
> From: "Thorsten" <thorsten315(a)gmx.de>
> To: keycloak-user(a)lists.jboss.org
> Sent: Thursday, April 16, 2015 11:05:46 AM
> Subject: [keycloak-user] Get user roles in AngularJS from WildFly adapter
>
> I have a WAR application that packages some JAX-RS services and an
AngularJS
> UI talking to them. No classic HTML/JSF stuff at all.
>
> The app is running on WildFly and the Keycloak adapter with
authentication is
> already working and I can e.g. secure the JAX-RS endpoints with
> @RolesAllowed etc.
>
> My question is now what the recommended way is to get user role
information
> in the AngularJS part of the app? Since the authentication is not done
in JS
> I don't think keycloak.js would work? Can/should the keycloak.js adapter
get
> combined with the WildFly adapter or is there a different way to get
> something like kc.hasRealmRole() to work?
Use keycloak.js to authenticate your AngularJS app
>
> Thanks
>
> _______________________________________________
> keycloak-user mailing list
> keycloak-user(a)lists.jboss.org
>
https://lists.jboss.org/mailman/listinfo/keycloak-user