Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE REQUEST] Ability to disable LDAP users #750

Open
cmer opened this issue Dec 2, 2023 · 7 comments
Open

[FEATURE REQUEST] Ability to disable LDAP users #750

cmer opened this issue Dec 2, 2023 · 7 comments
Labels
backend Issues that require a backend change enhancement New feature or request frontend Issues that require a frontend change help wanted Extra attention is needed ldap rust Pull requests that update Rust code

Comments

@cmer
Copy link

cmer commented Dec 2, 2023

Motivation
In a small business environment, we occasionally need to disable users after they have departed the company.

Describe the solution you'd like
I'd like to have a way to disable a user at on a specific date in the future, or right now.

Describe alternatives you've considered
Changing their password. But they could just reset it. Removing their email address is also a possibility, but it's kind of dirty and not great in case the person needs to be reactivated in the future.

@cmer cmer added the enhancement New feature or request label Dec 2, 2023
@nitnelave
Copy link
Member

Why can't you delete the user? Why do you need to keep them around? Do you have many cases where a disabled user has to be re-enabled?

I'm a bit skeptical of the use case. If a user leaves the company, their entry should surely be deleted, no? And if they do join again, then you have to consider again which permissions they need, since the business might have evolved and the requirements changed, or even just the group organization.

The closest feature I can think of that could facilitate the bulk addition of permissions is nested/inherited groups. It's planned, but not right now :)

Another thing you can do is to keep their account but remove them from every group: if you have configured your integrations correctly, they won't have access to anything, even though their password is still valid (though that may be a bit riskier).

@nomandera
Copy link

In my home lab it is unlikely I would ever use this but at my day job there are many instances where this can and does happen.

Holidays, maternity or paternity leave, sickness, testing related services stop working when user disabled, first line incident response (it is far less impactful to disable with a view to later reactivation if false positive than deleting a user) etc

@lordratner
Copy link
Contributor

I would suggest removing them from groups if they need to be "disabled." Or add them to a "departed" group that is explicitly blocked in any ldap queries.

Just a thought

@wildcart
Copy link

wildcart commented Jan 8, 2024

We are also interested in this feature. A few month ago a user left the company and we reset the user's password to 'deactivate' the user. The reason why we haven't deleted the user nor removed the user from any groups is that I am not sure how services using (L)LDAP would 'react' if they no longer find the user in the directory. Especially GitLap and OpenProject are critical and any contribution made by the user must remain attributed to that specific user.

Another reason for not deleting the user is: We must never be able to create a user with the same username / email address. Otherwise, attributing contributions to a user becomes difficult because we would always have to consider the date of the contribution and the date a user was active.

@terefang
Copy link

terefang commented Jan 16, 2024

there are two widely used attributes for this used by other servers:

  • userAccountControl – from Active Directory; 512=active, 514=disabled
  • pwdAccountLockedTime – from Sun/iPlanet/OpenLDAP; Timestamp when the account was last locked, where 000001010000Z means the account has been locked permanently.
  • nsAccountLock – Netscape/389/FreeIPA; true=locked, false=unlocked

@nitnelave
Copy link
Member

Just a small update on my position on this feature: I'm not against, but it's not targeting the core user base of the project, small self-hosted homelabs. The feature seems more targetted at companies. As such, I'm open to pull requests, but I probably won't implement it myself.

If you want to contribute, I'd be happy to guide you, provide you with hints and go over the design with you!

@nitnelave nitnelave added help wanted Extra attention is needed backend Issues that require a backend change frontend Issues that require a frontend change ldap rust Pull requests that update Rust code labels Jan 16, 2024
@lllllllillllllillll
Copy link

I've been hoping to get this feature as well, but with the ability to set account expiry dates.
I'd like to be able to grant multiple accounts temporary access without having to monitor and disable them manually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Issues that require a backend change enhancement New feature or request frontend Issues that require a frontend change help wanted Extra attention is needed ldap rust Pull requests that update Rust code
Projects
None yet
Development

No branches or pull requests

7 participants