goauthentik / authentik

The authentication glue you need.
https://goauthentik.io
Other
13.31k stars 889 forks source link

how to map ldap group's custom attribute to Authentik's group "attribute" #5874

Open sw-alpha-romeo opened 1 year ago

sw-alpha-romeo commented 1 year ago

Describe your question How to map a custom attribute set on ldap group can be mapped to Authentik group's attributes property.

Steps I performed 1> In JumpCloud ldap service, I added a custom property "acl" to the group to which users belong. This custom property has json data 2> Configured external LDAP service provider (JumpCloud) using Authentik's Federation & Social login option. 3> While configuring LDAP source in Federation & Social login "LDAP Attribute mapping" for group I selected option "authentik default OpenLDAP Mapping:cn" 4> When sync runs, I can see that LDAP group and users from JumpClound are copied into Authentik under Directory \ groups and Directory \ users. 5> When I check the attributes property of specific ldap group copied in Authentik, the value I get is ldap_uniq: ldap distinguishedName: cn=ldap,ou=Users,o=junkdata,dc=jumpcloud,dc=com

What I want

the attributes property of Authentik group created by copying JumpCloud Ldap group, should contain values of custom property "acl" of Ldap group

What I did

To achieve this I tried to create Property Mapping of type "LDAP Property Mapping" but, I don't understand what to put in field "Object field ", which has comment as "Field of the user object this value is written to", Does this mean that this property mapping only work for user not group ? Second thing what expression should I use to extract the value of custom attribute "acl" of ldap groups and return with this mapping.

Relevant infos JumpCloud Ldap service

Version and Deployment (please complete the following information):

ChenWenBrian commented 5 months ago

+1

majestic-zk commented 5 months ago

me too