Côme Chilliet
7a59d2ec07
Remove deprectated ILogger uses from user_ldap application
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-09-19 15:22:45 +02:00
Julius Härtl
97dd09c434
Merge pull request #39128 from nextcloud/fix/35319/ldap-missing-avatar
2023-09-11 19:43:18 +02:00
Côme Chilliet
2c8b415c55
Move new methods to a new interface in OCP
...
This avoids breaking compatibility for group backends not based on
ABackend abstract class.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-09-05 16:56:48 +02:00
Côme Chilliet
a5fa1e7715
Fix psalm errors about groupExists return type
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-09-05 16:56:48 +02:00
Carl Schwan
3270b7f12e
Add batch methods in user backends
...
This allows for faster group search with significantly less DB traffic
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2023-09-05 16:56:47 +02:00
Anna Larch
5d5134e615
Do not log passwords in debug mode
...
Signed-off-by: Anna Larch <anna@nextcloud.com>
2023-08-24 10:39:27 +02:00
Côme Chilliet
a0808111b4
Add unique index for user_ldap group memberships
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:37 +02:00
Côme Chilliet
b8a0954f55
Fix check-group --update for deleted groups
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:37 +02:00
Côme Chilliet
5425f7d3bd
Use BIGINT for new table id field
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:36 +02:00
Côme Chilliet
7732de75ee
Removed GroupCreatedEvent/GroupDeletedEvent from UpdateGroupsService
...
This should be handled when mapping groups, not when registering their
members. An empty group may still exist.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:36 +02:00
Côme Chilliet
ad1e487f67
Dispatch UserRemovedEvents for removed groups
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:35 +02:00
Côme Chilliet
c33c40f677
[user_ldap] Small perf improvements suggestion from review
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:35 +02:00
Côme Chilliet
1026b2131c
Fix check-group command for new groups
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:34 +02:00
Côme Chilliet
42448c0d78
Fix getKnownGroups return value
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:34 +02:00
Côme Chilliet
7a14aa748e
Add output to check-group --update command
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:34 +02:00
Côme Chilliet
ce5a4e5b66
Always empty cache before updating a group
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:34 +02:00
Côme Chilliet
1b102ca9b3
Fix errors in UpdateGroupsService.php
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:33 +02:00
Côme Chilliet
ec13f22ae3
Add missing primary key for ldap_group_membership
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:33 +02:00
Côme Chilliet
f9ed48eab9
Add check-group command
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:33 +02:00
Côme Chilliet
2c19aac9e1
Move UpdateGroups methods to a service
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:33 +02:00
Côme Chilliet
34fa4138fb
Add group events to UpdateGroups
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:32 +02:00
Côme Chilliet
d8142b6a5a
Refactor user_ldap group membership to use flat DB
...
Move away from serialized arrays. Also use a QBMapper class for the new table.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-10 10:57:25 +02:00
Côme Chilliet
b155f87a84
Merge pull request #39058 from nextcloud/fix/fix-ldap-filters-for-empty-search
...
Avoid adding (attribute=) part to filter which will confuse LDAP servers
2023-08-08 09:21:20 +02:00
jld3103
61a13bed4d
user_ldap: Add OpenAPI spec
...
Signed-off-by: jld3103 <jld3103yt@gmail.com>
2023-07-31 12:17:42 +02:00
Joas Schilling
77bc6c32d8
fix(dispatcher): Move remaining simple cases in apps/ folder to IEventDispatcher
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-07-25 11:19:26 +02:00
Arthur Schiwon
4054a7ddc8
fix(LDAP): add return type hint and description
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2023-07-07 10:46:00 +02:00
Arthur Schiwon
92a082d823
fix(ldap): avatar is not being fetched
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2023-07-05 17:13:43 +02:00
Côme Chilliet
b2f01b72fe
Merge pull request #34443 from nextcloud/feat/add-enabled-user-backend
...
Add IProvideEnabledStateBackend interface
2023-07-03 10:19:32 +02:00
Côme Chilliet
189ccc2d72
Add method to list disabled users to IProvideEnabledStateBackend
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-06-29 16:15:12 +02:00
Côme Chilliet
4a0351878c
Avoid adding (attribute=) part to filter which will confuse LDAP servers
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-06-29 10:42:59 +02:00
Arthur Schiwon
2e81a1d839
Merge pull request #38457 from nextcloud/fix/improve-ldap-offset-search-perf
...
Use default page size for jumping to desired offset
2023-06-22 21:46:03 +02:00
Côme Chilliet
b980722e89
Fix paged search when offset is not a multiple of default page size
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-06-20 16:13:59 +02:00
Côme Chilliet
1603cdc8d2
Fix since annotations and add boolean return type for setUserEnabled
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-06-20 15:10:39 +02:00
Faraz Samapoor
b0938b9083
Refactors "strpos" calls in /apps/user_ldap to improve code readability.
...
Signed-off-by: Faraz Samapoor <f.samapoor@gmail.com>
2023-06-02 15:26:55 +03:30
Côme Chilliet
add59d2309
Use DI for DeletedUsersIndex and fix tests
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-05-25 12:18:28 +02:00
Côme Chilliet
b186cffdbe
Use default page size for jumping to desired offset
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-05-25 11:31:29 +02:00
Côme Chilliet
50ccfb4f5b
[user_ldap] Add per-connection setting for marking remnants as disabled
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-05-23 16:03:17 +02:00
Côme Chilliet
684a81e4bd
Use the new IProvideEnabledStateBackend interface in user_ldap
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-05-23 11:25:22 +02:00
Côme Chilliet
c995428431
Merge pull request #37903 from nextcloud/fix/user_ldap-fix-multiple-ldap-support
...
Fix multiple LDAP configuration support by fixing AccessFactory
2023-05-02 17:11:01 +02:00
Côme Chilliet
b6c17c6ce7
Clear up return types
...
usersInGroup index by int for BC, searchInGroup index by uid (string).
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-04-27 12:00:45 +02:00
Côme Chilliet
6385a5af36
Let OC\Group\Group handle the fallback and remove default implementation from ABackend
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-04-27 12:00:43 +02:00
Carl Schwan
35dc223500
Optimize retrieving display name when searching for users in a group
...
This is recurrent scenario that we are searching for users and then for
each users we fetch the displayName. This is inefficient, so instead try
to do one query to fetch everything (e.g. Database backend) or use the
already existing DisplayNameCache helper.
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2023-04-27 11:57:45 +02:00
Côme Chilliet
967955358c
Add comment about Manager instance not being shared
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-04-27 11:21:53 +02:00
Daniel
2abefff289
Merge pull request #36784 from nextcloud/fix/user_ldap-update-groups-fail-get
...
Properly test and log when a group is not found
2023-04-24 16:26:30 +02:00
Côme Chilliet
429db14a00
Fix multiple LDAP configuration support by fixing AccessFactory
...
It must not reuse the same OCA\User_LDAP\User\Manager instance for
several Access instances.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-04-24 16:03:40 +02:00
Marc Hefter
621c6c3c56
code styling
...
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: Marc Hefter <marchefter@march42.net>
2023-04-24 10:21:45 +02:00
Marc Hefter
aa210365ec
Update apps/user_ldap/lib/User/User.php
...
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: Marc Hefter <marchefter@march42.net>
2023-04-24 10:14:17 +02:00
Marc Hefter
e83520617d
removed profile data from LDAP will get removed
...
If attribute mapping is configured and no value present in LDAP, the
according profile field is emptied. Removing an attribute e.g. phone
from LDAP will cause the phone number being removed from profile.
Signed-off-by: Marc Hefter <marchefter@gmail.com>
2023-04-21 10:35:44 +02:00
Simon L
93966e99c1
Merge pull request #36565 from march42/feature/ldap_update_profile
...
[user_ldap] Update profile from LDAP fields
2023-04-20 11:23:24 +02:00
Marc Hefter
64914593a0
optimized handling of user profile data change
...
Check profile data checksum before updating user profile, to ensure
data has changed. Write checksum to user settings and cache.
Signed-off-by: Marc Hefter <marchefter@gmail.com>
2023-04-14 11:08:46 +02:00