summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/lib
Commit message (Collapse)AuthorAgeFilesLines
* fix potentially passing null to events where IUser is expectedArthur Schiwon2020-11-041-2/+7
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* fixes determining whether former user is a share ownerArthur Schiwon2020-10-271-11/+4
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* split instantiation from business logic in OfflineUserArthur Schiwon2020-10-271-1/+24
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* tame psalm. why does it ignore '@property'?Arthur Schiwon2020-10-211-5/+1
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* when nesting is not enabled, the group filter can be applied right awayArthur Schiwon2020-10-211-1/+7
| | | | | | | | - helps performance, but skipping unnecessary entries - reduces reoccuring info-level log output against groups that do not qualify ("no or empty name") Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* makes LDAP's group updater dispatch type eventsArthur Schiwon2020-09-101-2/+14
| | | | | | * fixes group share updates on added users Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* add repair step to clean up DB off lastFeatureRefresh entries in user prefsArthur Schiwon2020-09-071-0/+65
| | | | | | - also removes related app setting "updateAttributesInterval" Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* these code bits were part of old logic that was already refactored outArthur Schiwon2020-09-061-53/+0
| | | | | | - only references were in unit tests Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Merge pull request #22203 from nextcloud/backport/21559/stable19blizzz2020-08-123-0/+46
|\ | | | | [stable19] shortcut in reading nested group members when IN_CHAIN is available
| * do not flip available state to unavailable, allow empty resultsArthur Schiwon2020-08-122-11/+21
| | | | | | | | | | | | | | | | | | - the detection relies that the first, requested result is not empty - it might be empty though – groups without members - protect switching from available to unavailable - switching the other way around was also not envisaged either Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
| * LDAP: shortcut in reading nested group members when IN_CHAIN is availableArthur Schiwon2020-08-112-0/+36
| | | | | | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* | remove logging message carrying no valuable informationArthur Schiwon2020-08-121-8/+5
|/ | | | | | | | the exception caught is not an error, but due to valid configuration and code flow is expecting this. For an admin it is confusing, and it carries no information worth for debugging. Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Remove unexpected argumentDaniel Kesselberg2020-08-112-2/+2
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* reset the cookie internally in new API when abandoning paged results opArthur Schiwon2020-07-311-1/+11
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* fix strings being passed where arrays where expectedArthur Schiwon2020-06-252-25/+7
| | | | | | also brought type hints up to internal API level Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* comment was wrong, block is needed neverthelessArthur Schiwon2020-06-241-2/+1
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* be more clear about the conditionblizzz2020-06-191-1/+1
| | | Co-authored-by: Christoph Wurst <ChristophWurst@users.noreply.github.com>
* getXbyY can still return false, e.g. when using ldap write supportArthur Schiwon2020-06-191-2/+1
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* clear LDAP cache after user deletionArthur Schiwon2020-06-091-0/+1
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* simplify getGroups, fixing wrong chunking logicArthur Schiwon2020-05-271-50/+7
| | | | | | pagination is taken care of properly in the search logic in Access class Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* fixes infinitely repeating LDPA search results with PHP <= 7.2Arthur Schiwon2020-05-261-0/+6
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Update license headers for 19Christoph Wurst2020-04-2933-11/+38
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Don't remove last user in ldap group when limit is -1Clement Wong2020-04-271-3/+3
| | | | Signed-off-by: Clement Wong <git@clement.hk>
* Merge pull request #19919 from nextcloud/enh/noid/ldpa_group_perfblizzz2020-04-249-167/+365
|\ | | | | LDAP Group Backend optimizations
| * formattingArthur Schiwon2020-04-237-126/+236
| | | | | | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
| * do not rerun expensive sanitizer against already processed DNsArthur Schiwon2020-04-171-4/+18
| | | | | | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
| * read records from DB for lists at once, not one by one.Arthur Schiwon2020-04-174-12/+80
| | | | | | | | | | | | Keep a runtime cache of dn-id-mapping Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
| * don't circulate with only one backendArthur Schiwon2020-04-173-4/+29
| | | | | | | | | | | | | | - saves some overhead costs - in some occasions saves LDAP requests Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
| * consolidate groupsMatchFilter in groupsExistArthur Schiwon2020-04-172-44/+25
| | | | | | | | | | | | | | - less duplication - profiting of the same cache entry Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* | do not run paged results against ldap_read ops on PHP7.3+Arthur Schiwon2020-04-211-1/+0
|/ | | | | | | | | - previously it was needed as the PHP LDAP handling of paged results was strange - but now the read operation would fail, e.g. with extra home dir attribute set ("Home dir attribute can't be read from LDAP for uid: foobar" Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* PHP-CS-Fixer greenRoeland Jago Douma2020-04-166-29/+31
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* use serverControls directly with LDAP calls, fixes 19127Arthur Schiwon2020-04-149-203/+651
| | | | | | | | - adapters for PHP API version to Support PHP < 7.3 - switch to pass only one base per search - cookie logic is moved from Access to API adapters Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Format code according to PSR2Christoph Wurst2020-04-101-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add visibility to all constantsChristoph Wurst2020-04-105-17/+17
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add visibility to all methods and position of static keywordChristoph Wurst2020-04-102-8/+8
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add visibility to all properties and move static keywordChristoph Wurst2020-04-103-4/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-1047-773/+741
| | | | | | | | | | | | | | | 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>
* Use elseif instead of else ifChristoph Wurst2020-04-1011-31/+31
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #20391 from nextcloud/refactor/spaces-cleanupChristoph Wurst2020-04-099-17/+17
|\ | | | | Remove all extra whitespace PSR2 does not like
| * Remove trailing whitespaces from commentsChristoph Wurst2020-04-092-4/+4
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
| * Remove trailing and in between spacesChristoph Wurst2020-04-098-13/+13
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Merge pull request #20384 from nextcloud/techdebt/lowercase-keywordsChristoph Wurst2020-04-091-1/+1
|\ \ | |/ |/| Use php keywords in lowercase
| * Use php keywords in lowercaseChristoph Wurst2020-04-091-1/+1
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Unify function spacing to PSR2 recommendationChristoph Wurst2020-04-099-16/+16
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use exactly one empty line after the namespace declarationChristoph Wurst2020-04-099-9/+0
| | | | | | For PSR2 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix (array) indent style to always use one tabChristoph Wurst2020-04-0911-75/+75
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix multiline commentsChristoph Wurst2020-04-086-38/+38
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update the license headers for Nextcloud 19Christoph Wurst2020-03-3121-1/+22
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use the short array syntax, everywhereChristoph Wurst2020-03-2621-232/+232
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* single squashed commit for bug fixPhilipp Staiger2020-03-261-28/+26
| | | | Signed-off-by: Philipp Staiger <philipp@staiger.it>