mirror of
https://github.com/sirtoobii/vaultwarden_ldap_sync.git
synced 2026-04-26 20:45:54 +03:00
[GH-ISSUE #17] LDAP Sync inconsistency: removed AD user not disabled + active user incorrectly marked as DELETED #12
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vaultwarden_ldap_sync#12
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Sh4dow998 on GitHub (Aug 27, 2025).
Original GitHub issue: https://github.com/sirtoobii/vaultwarden_ldap_sync/issues/17
Hello,
I am running Vaultwarden with vaultwarden_ldap_sync in Docker, and I am facing two issues regarding synchronization with Active Directory:
When I remove a user from the AD group (GRP_Vaultwarden), the user (y.nour@toto.com) is still present in the Vaultwarden database and not disabled. In the sync logs, this user does not appear at all, and the user is also no longer present in the Domain Controller (AD).
Another user is unexpectedly marked as DELETED by the sync process, although the account is still present and enabled in Active Directory. This leads to sync attempts failing with an HTTP 404 error when trying to enable the user again. The error persists even after restarting the container.
What I expected:
Environment:
Additional information:
I would really like to understand why this happens, and any help or guidance would be greatly appreciated.
@sirtoobii commented on GitHub (Sep 13, 2025):
Hi @Sh4dow998 thank you for the report.
Are you using the latest version of this project? And which Vaultwarden version do you use? Because I was unable to reproduce you issue with both the latest Vaultwarden image and latest version of this repo.
Also to further debug such issues, you can run the script with
DUMP_EMAIL_SOURCE=1@casse-boubou commented on GitHub (Oct 4, 2025):
Hello, I have the same second issue.
I'm using an LDAP directory and Vaultwarden v1.34.3.
vaultwarden_ldap_sync has been built since the last commit on June 18, 2025.
This happened after deleting a user from the Vaultwarden admin panel.
For clarification (maybe not useful) this is a user whose invitation had been sent but who had not validated and created his account on vaultwarden
I don't know what additional information I can provide, but please don't hesitate to ask.
Thank you and thank you for your work.
@casse-boubou commented on GitHub (Oct 5, 2025):
Because line 179 in vaultwarden_user_sync/compare.py returns these values
I think it can be corrected by modifying line 179-180 in vaultwarden_user_sync/compare.py
from
to
@Sh4dow998 commented on GitHub (Oct 13, 2025):
Hi @sirtoobii,
Sorry for the late reply.
I’m running Vaultwarden 1.34.2 with the latest version of vaultwarden_ldap_sync, and I already used DUMP_EMAIL_SOURCE=1.
I’m seeing, I think the same behavior described by @casse-boubou, the issue still occurs with these versions.
@sirtoobii commented on GitHub (Oct 25, 2025):
Hey @casse-boubou
When implementing a unit test for reported issue(s), I was wondering what actually is the expected behavior when deleting a user in the VW admin panel while the user is still present in the LDAP result? I can think of two options:
DELETEDin the local state and is blocked from future invitations. In order to "unlock" this user again, the user has to be manually created in VW again.What do you think?
Edit: A third option came to my mind: Since this question is also relevant when it comes to disabling users in VW, an option would be to exclude all users with manual changes from automatic management until their VW-state matches the local-state again.