<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">There are few steps here and the result
will work only if all steps success. So it might help to try which
step could be wrong here:<br>
<br>
1) You can doublecheck if your user really has 'applications'
attribute in LDAP<br>
<br>
2) If (1) is ok, you can enable TRACE logging for
"org.keycloak.federation.ldap" category in standalone.xml . With
it, you should see some trace messages with the names and values
of all LDAP attributes, which are loaded in user record. You
should see the 'applications' attribute loaded<br>
<br>
3) If (2) is ok, you can browse keycloak database and check if
attribute 'applications' is really here. The user attributes are
saved in table USER_ATTRIBUTES. Currently it's not possible to
browse user attributes generically in admin console (unless you do
custom theme) so browse DB seems to be the only possibility.<br>
<br>
4) If (3) is ok, the issue is not in LDAP interaction, but in
protocol mapper configuration. Make sure you use correct protocol
mapper (In your case it should be "User attributes" mapper, not
"User property" mapper). Also if your application is Java based,
the value of 'applications' claim is saved in accessToken in
'otherClaims' map and can be retrieved with something like:
accessToken.getOtherClaims().get("applications");<br>
<br>
Marek<br>
<br>
<br>
On 18.6.2015 17:50, Kevin Thorpe wrote:<br>
</div>
<blockquote
cite="mid:CAFMa6BZSatfB38r892f0JEu9j57Sv09JqgiT=oFyQfpttQNsFA@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>Thanks to the team for 1.3.1. We were eagerly waiting for
that to add LDAP attribute mappings which I see has now been
done. Unfortunately I can't seem to get it to work.</div>
<div><br>
</div>
<div>I have added a user attribute mapper to my ldap federation.
This maps the LDAP atribute 'applications' which exists on my
LDAP user record to 'applications' in Keycloak. </div>
<div><br>
</div>
<div>I have also added a user attribute token mapper to my
Keycloak client definition to map user attribute
'applications' to token claim 'applications'. I've also asked
to add to both id and access token.</div>
<div><br>
</div>
<div>However this attribute is not present in either the ID or
access token when testing. Is there something I've missed? </div>
<div><br>
</div>
<div>Something that may be an issue though is that I'm using a
home written openid-connect Lua client based on your
javascript one. This uses the endpoint
/auth/realms/master/protocol/openid-connect/token. Is it that
the openid-connect endpoint doesn't support these attributes
yet?</div>
<br clear="all">
<div>
<div class="gmail_signature">
<div dir="ltr">
<div dir="ltr">
<div><font color="#000000"><b>Kevin Thorpe<br>
</b></font></div>
<div>CTO, PI ltd<br>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
keycloak-user mailing list
<a class="moz-txt-link-abbreviated" href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/keycloak-user">https://lists.jboss.org/mailman/listinfo/keycloak-user</a></pre>
</blockquote>
<br>
</body>
</html>