Côme Chilliet
e094602311
fix(user_ldap): Remove redundant if check
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-01-30 13:47:09 +07:00
Côme Chilliet
e55806b546
feat(user_ldap): upstream common code into Proxy class and add public getters for backends
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-01-30 11:49:58 +07:00
provokateurin
77114fb327
fix(OpenAPI): Adjust array syntax to avoid ambiguities
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2024-11-05 09:58:11 +07:00
provokateurin
381077028a
refactor(apps): Use constructor property promotion when possible
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2024-10-21 12:37:59 +07:00
Côme Chilliet
1580c8612b
chore(apps): Apply new rector configuration to autouse classes
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-10-15 10:40:25 +07:00
Daniel Kesselberg
af6de04e9e
style: update codestyle for coding-standard 1.2.3
...
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2024-08-25 19:34:58 +07:00
Andy Scherzinger
8d8891c5bc
chore: Add SPDX header
...
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
2024-05-30 15:49:33 +07:00
Côme Chilliet
85cea1960b
fix: Avoid useless reference usage in user_ldap
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-04-30 09:24:01 +07:00
Côme Chilliet
0f348516d2
fix: Remove obsolete resource typing
...
In PHP>=8.1, LDAP and FTP resources are always typed objects
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-04-09 10:01:47 +07:00
Côme Chilliet
658b20aef5
Fix crash of login in case of duplicated group membership
...
If several LDAP configurations return the same group id for a user it
should still only appear once in the return of getUserGroups
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-01-15 09:39:59 +07:00
Arthur Schiwon
d6b356c63b
enh(LDAP): implement IIsAdmin interface
...
- add configuration to specify one LDAP group acting as admin group (CLI)
- implement `isAdmin()` method, basically relying on inGroup against the
configured group
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2023-12-01 12:48:24 +07:00
Côme Chilliet
8212feefb9
Merge pull request #40367 from nextcloud/fix/user_ldap-update-groups-on-login
...
Fire group membership events from LDAP at login
2023-10-16 10:01:55 +07:00
Côme Chilliet
05efbf11d9
Fix LDAP LoginListener by adding new group relationships to caches before firing the event
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-10-12 10:13:43 +07:00
Arthur Schiwon
cce8d0a7a5
fix(LDAP): solve race condition reading groups of disappeared LDAP user
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2023-10-11 15:35:10 +07:00
Arthur Schiwon
c1480aade4
refactor(LDAP): pass IConfig via constructor to Group_LDAP
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2023-10-10 11:18:57 +07: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 +07: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 +07: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 +07: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 +07: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 +07: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 +07:00
Côme Chilliet
4130a4cbd8
Make sure to use AccessFactory to create Access instances and use DI
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-10-25 09:52:35 +07:00
Arthur Schiwon
8e8acf2d90
LDAP to no register new users when outside of fair use or over limits
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2022-10-18 12:57:43 +07:00
Côme Chilliet
77bdad84c2
Add ldap:reset-group command to unmap groups from LDAP
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-04-01 12:18:02 +07:00
Côme Chilliet
f3dcbfe146
Fix PHP 8.1 support for user_ldap application
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2021-12-16 09:43:30 +07:00
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-06-04 22:02:41 +07:00
Johannes Leuker
2796ef80ff
Show group backends in occ group:list --info and group:info
...
Signed-off-by: Johannes Leuker <j.leuker@hosting.de>
2021-03-01 16:02:08 +07:00
Arthur Schiwon
86e5e7d927
LDAP simplify User_Proxy and Group_Proxy signatures
...
- make User_Proxy and Group_Proxy easy to instantiate
- simplify dependent code
- move commands to info.xml
- make UpdateGroups job class non-static
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-10-23 12:25:31 +07:00
Morris Jobke
fedf9c69d9
Use matching parameter names form interfaces and implementations
...
Found by Psalm 3.14.1
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-08-19 18:16:35 +07:00
Arthur Schiwon
4babdc082b
formatting
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-04-23 21:34:05 +07:00
Arthur Schiwon
cc31c38277
don't circulate with only one backend
...
- saves some overhead costs
- in some occasions saves LDAP requests
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-04-17 12:38:52 +07:00
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
...
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.
This also removes and empty lines from method/function bodies at the
beginning and end.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-10 14:19:56 +07:00
Christoph Wurst
1a9330cd69
Update the license headers for Nextcloud 19
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-03-31 14:52:54 +07:00
Christoph Wurst
b80ebc9674
Use the short array syntax, everywhere
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-03-26 16:34:56 +07:00
Christoph Wurst
5bf3d1bb38
Update license headers
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2019-12-05 15:38:45 +07:00
Arthur Schiwon
c6c8a41d2f
group display name support (service level + ldap)
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-05-27 12:03:05 +07:00
Morris Jobke
a661f043e1
Remove unneeded semicolon and parentheses
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2018-01-26 23:46:40 +07:00
Morris Jobke
0eebff152a
Update license headers
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-11-06 16:56:19 +07:00
Vinicius Cubas Brand
fa565750d1
User_LDAP plugins: smaller fixes
...
Signed-off-by: Vinicius Cubas Brand <viniciuscb@gmail.com>
2017-11-03 11:42:59 +07:00
Vinicius Cubas Brand
10ca793452
Plugins infrastructure in User_LDAP
...
Signed-off-by: Vinicius Cubas Brand <viniciuscb@gmail.com>
2017-11-03 11:41:40 +07:00
Morris Jobke
89a7b007f2
Fix comments
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-07-25 08:57:58 +07:00
Arthur Schiwon
497ee3e3e6
Add repair steps
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2017-02-17 18:45:33 +07:00
Joas Schilling
813f0a0f40
Fix apps/
2016-07-21 18:13:57 +07:00
Lukas Reschke
aba539703c
Update license headers
2016-05-26 19:57:24 +07:00
Joas Schilling
391531851c
Move interface to PSR-4
2016-05-25 16:04:58 +07:00
Joas Schilling
e73d811425
Move Proxy to PSR-4
2016-05-25 16:04:57 +07:00
Joas Schilling
cbba55a26c
Move Group_LDAP and Group_Proxy to PSR-4
2016-05-25 16:04:56 +07:00