Automatic deletion of users if deleted from AD #3826

Open
opened 2026-02-05 07:35:50 +03:00 by OVERLORD · 3 comments
Owner

Originally created by @TineUser on GitHub (May 26, 2023).

Describe the feature you'd like

Is there a possibility to get an option for an automtic deletion of users in BookStack when they're deleted from AD?

I know that then it's important to have an automatic migration of the ownership to another user. Here we could set up a dummy user to take over the ownership from the deleted users.

Describe the benefits this would bring to existing BookStack users

With an automatic deletion of user accounts there are no more orphanned accounts in BookStack.

Can the goal of this request already be achieved via other means?

Don't know if there's already another solution.

Have you searched for an existing open/closed issue?

  • I have searched for existing issues and none cover my fundemental request

How long have you been using BookStack?

6 months to 1 year

Additional context

No response

Originally created by @TineUser on GitHub (May 26, 2023). ### Describe the feature you'd like Is there a possibility to get an option for an automtic deletion of users in BookStack when they're deleted from AD? I know that then it's important to have an automatic migration of the ownership to another user. Here we could set up a dummy user to take over the ownership from the deleted users. ### Describe the benefits this would bring to existing BookStack users With an automatic deletion of user accounts there are no more orphanned accounts in BookStack. ### Can the goal of this request already be achieved via other means? Don't know if there's already another solution. ### Have you searched for an existing open/closed issue? - [X] I have searched for existing issues and none cover my fundemental request ### How long have you been using BookStack? 6 months to 1 year ### Additional context _No response_
OVERLORD added the 🔨 Feature Request label 2026-02-05 07:35:50 +03:00
Author
Owner

@ssddanbrown commented on GitHub (May 26, 2023):

Thanks for the request @TineUser.

Somewhat related to this issue: https://github.com/BookStackApp/BookStack/issues/2701#issuecomment-1032883852

You mentioned AD but could you confirm the auth method in use with AD? (There are 4 auth methods in BookStack that can be used with AD).

Generally though, this probably wouldn't be something I'd look to support as it would require either use of service specific APIs/mechanisms or use of complex enterprise standards but there may be something I can suggest using the APIs or methods of extension that BookStack provides.

@ssddanbrown commented on GitHub (May 26, 2023): Thanks for the request @TineUser. Somewhat related to this issue: https://github.com/BookStackApp/BookStack/issues/2701#issuecomment-1032883852 You mentioned AD but could you confirm the auth method in use with AD? (There are 4 auth methods in BookStack that can be used with AD). Generally though, this probably wouldn't be something I'd look to support as it would require either use of service specific APIs/mechanisms or use of complex enterprise standards but there may be something I can suggest using the APIs or methods of extension that BookStack provides.
Author
Owner

@TineUser commented on GitHub (May 26, 2023):

It isn't equal to that what I asked for. We are happy with the user provisioning by AD groups. So the user has to login for the first time to get an account in BookStack that is related to his AD account. And with logiign in every time the AD groups will be checked for matching the roles in BookStack.

We have implemented the LDAPS auth method ageinst our local AD.

@TineUser commented on GitHub (May 26, 2023): It isn't equal to that what I asked for. We are happy with the user provisioning by AD groups. So the user has to login for the first time to get an account in BookStack that is related to his AD account. And with logiign in every time the AD groups will be checked for matching the roles in BookStack. We have implemented the LDAPS auth method ageinst our local AD.
Author
Owner

@ssddanbrown commented on GitHub (May 26, 2023):

It isn't equal to that what I asked for.

Sure, I just meant to indicate that issue was quite related.

We have implemented the LDAPS auth method ageinst our local AD.

Okay, so LDAP auth. You could script something external in you language of choice, using the BookStack user API to fetch and delete user accounts. Alternatively you could build a command within BookStack using the logical theme system, making use of unofficial/unsupported yet direct access to user data and built-in LDAP services.

@ssddanbrown commented on GitHub (May 26, 2023): > It isn't equal to that what I asked for. Sure, I just meant to indicate that issue was quite related. > We have implemented the LDAPS auth method ageinst our local AD. Okay, so LDAP auth. You could script something external in you language of choice, using the BookStack user API to fetch and delete user accounts. Alternatively you could build a command within BookStack using the [logical theme system](https://github.com/BookStackApp/BookStack/blob/development/dev/docs/logical-theme-system.md), making use of unofficial/unsupported yet direct access to user data and built-in LDAP services.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#3826