Skip to content

[QA] occ user:sync prints wrong diagonstics after disabling/reenabling users #655

Description

@jnweiger

Seen with user_ldap-0.15.3-RC3 at server 10.8.0-beta2

Use the Edit LDAP Query in the User tab to filter down to a few users only. E.g.
(|(&(objectclass=inetOrgPerson)(givenname=Th*))) then run
`occ user:sync -c -m disable -r "OCA\User_LDAP\User_Proxy"

-> Most users become disabled. Only e.g. "Third Ldapuser" can log in. OK

broaden the filter back to normal wiith e.g. (|(&(objectclass=inetOrgPerson)(givenname=*))) and re-run the user sync without(!) the -r flag.
-> No users users become re-enabled. OK
Then re-run the iser sync with the -r flag, -> All users become re-enabled and can log in.

Repeat a few times with and without -r.
At some point occ user:sync -c -m disable -r "OCA\User_LDAP\User_Proxy" prints

...
e77866d0-72f1-103b-8427-9dea2428f1ef, One thousand and ninety-second Ldapuser, u1092@example.org skipped, already disabled
e77a3212-72f1-103b-8428-9dea2428f1ef, One thousand and ninety-third Ldapuser, u1093@example.org skipped, already disabled
e77bec7e-72f1-103b-8429-9dea2428f1ef, One thousand and ninety-fourth Ldapuser, u1094@example.org skipped, already disabled
e77dcde6-72f1-103b-842a-9dea2428f1ef, One thousand and ninety-fifth Ldapuser, u1095@example.org skipped, already disabled
e77f7826-72f1-103b-842b-9dea2428f1ef, One thousand and ninety-sixth Ldapuser, u1096@example.org skipped, already disabled
e780fa0c-72f1-103b-842c-9dea2428f1ef, One thousand and ninety-seventh Ldapuser, u1097@example.org skipped, already disabled
e7827a1c-72f1-103b-842d-9dea2428f1ef, One thousand and ninety-eighth Ldapuser, u1098@example.org skipped, already disabled
e7840a6c-72f1-103b-842e-9dea2428f1ef, One thousand and ninety-ninth Ldapuser, u1099@example.org skipped, already disabled

No existing accounts to re-enable.

Inserting new and updating all known users from OCA\User_LDAP\User_Proxy ...
 1104/1104 [============================] 100%


Sync of users finished, encountered 0 errors.

This indicates that e.g. user u1099@example.org is disabled.
Try log in using that email address, the user can log in correctly.

Expected behaviour: The message should say "... skipped, already enabled"
Switching this back and forth a few times, a

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions