[Feature]: createLdapUser does not pull group memberships · Issue #5798 · kanboard/kanboard · GitHub
Skip to content

[Feature]: createLdapUser does not pull group memberships #5798

Description

@Anspitzen

Bug Summary

when using the API to create a new user from LDAP username it does not include the group memberships, permissions based on group membership not working

Description

I use an app to push tasks to the kanboard. When the username is not known it creates the user from the LDAP via API before pushing the task.
Kanboard is configured with proxy LDAP user. creating the user does work. The user has not the rights given by the group membership.
After setting the user in the kanboard to a specific role it works. Removing the user permission it works not, even if the same role is given to the one group the user has in the AD.
When the user logs into the kanboard directly the groups are loaded and subsequent API requests work as now the permissions are loaded.

Steps to Reproduce

  1. create a group "shouldhaverights" in AD
  2. assign the group some permissions/custom role in kanboard (like not allowed to create a task except in specific column)
  3. Create a user "newLdapKanboardUser" in AD and assign the group "shouldhaverights"
  4. use API to create a user from LDAP with given username "newLdapKanboardUser" (createLdapUser)
    Get the user id for creating a new task with the user as author (getUserByName)
  5. send a createTask request to API with the creatorId of the newLdapKanboardUser
  6. see response false (missing permissions to create task)

Additional you can test setting newLdapKanboardUser as a user permission to the same custom role/permission that the group membership should give
When sending a createTask API request it works. When removing the user permission it stops working.

When you login to the kanboard with the newLdapKanboardUser (and AD password) the API does work with the group permission

Expected Behavior

When creating the LDAP user it should pull the group memberships and the permissions gased on group membership should work.

Actual Behavior

createLdapUser does create user but user has no group assigned permissions

Version

1.2.46

Database

MySQL

PHP Version

No response

Browser

No response

Operating System

No response

Relevant Logs or Error Output

Additional Context

No response

Checklist

  • I have searched existing issues to ensure this bug hasn't been reported before.
  • I verified that the problem is not caused by a plugin. Please report the issue to the plugin author if applicable.

Activity

  1. added theissue type on Mar 31, 2026
  2. Anspitzen commented on Apr 1, 2026

    @Anspitzen
    Author

    My current solution/workaround is to look up the LDAP user after sending API request to create said user in Kanboard from the LDAP user.

    Get all groups from the LDAP user, get all available groups from the Kanboard.
    Make a list of all (kanboard) group Ids, where the ldap-group DistinguishedName is the same as a kanboard AdGroupPrincipleName.
    Then send a addGroupMember-request for each of these groups with the Id of the newly created LDAP user.

    It's not super performant, as I have to send a request for each single group but works for the time being.
    I haven't checked the group sync after the creation (if I remove a group from LDAP user, does it remove the group/permission in kanboard also?)

  3. fguillot commented on Apr 1, 2026

    @fguillot
    Member

    This behavior was not part of the original intent when the feature was introduced in PR #524 back in 2015.

    If you have a specific enhancement in mind, feel free to open a pull request.

  4. changed the issue type fromtoon Apr 1, 2026
  5. changed the title [-][Bug]: createLdapUser does not pull group memberships[/-] [+][Feature]: createLdapUser does not pull group memberships[/+] on Apr 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions