luz paz
9d26671f05
Fix typos in apps/ subdirectory
...
Found via `codespell -q 3 -S l10n,./apps/files_external/3rdparty -L adn,ba,boxs,keypair,jus,optionel,ressource,tabel ./apps/`
Signed-off-by: luz paz <luzpaz@github.com>
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
2022-09-05 12:59:54 +07:00
Carl Schwan
d5c23dbb9f
Move CappedMemoryCache to OCP
...
This is an helpful helper that should be used in more place than just
server and this is already the case with groupfodlers, deck, user_oidc
and more using it, so let's make it public
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-07-14 15:54:31 +07:00
Carl Schwan
ec6b83cc18
Add stricter psalm type for CappedMemoryCache
...
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-05-12 15:06:18 +07:00
Côme Chilliet
dab5ea958a
Fix unit tests
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-03-03 16:35:06 +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
Côme Chilliet
7ac895e766
Move back logger to protected in OCA\User_LDAP\User\User
...
It was changed to private because of a bad copy/paste.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2021-11-23 11:06:14 +07:00
Côme Chilliet
6b960de47c
Get rid of LogWrapper calling deprecated logger and use LoggerInterface from PSR instead
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2021-11-09 15:11:15 +07:00
Arthur Schiwon
27865d03c0
use specific email getter where necessary
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-09-09 19:23:05 +07:00
Arthur Schiwon
bbcd8c9a68
LDAP: determine shares of offline users only when needed
...
- determine shares may via Sharing code result in user exists checks
- this may result in an infinite loop when user exists was called before
- the info is really only required at one occ command
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-06-28 12:56:37 +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
Roeland Jago Douma
3f4ece256e
Some psalm OfflineUser fixes
...
For #25641
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-02-15 13:36:02 +07:00
Christoph Wurst
d89a75be0b
Update all license headers for Nextcloud 21
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-16 18:48:22 +07:00
Arthur Schiwon
fd1fd5afa4
user share manager to determine share ownership
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-10-26 16:05:28 +07:00
Arthur Schiwon
951887e922
fixes determining whether former user is a share owner
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-10-26 16:05:28 +07:00
Arthur Schiwon
2e455f632a
split instantiation from business logic in OfflineUser
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-10-26 16:05:28 +07:00
Christoph Wurst
d9015a8c94
Format code to a single space around binary operators
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-10-05 20:25:24 +07:00
Arthur Schiwon
699871dcb0
these code bits were part of old logic that was already refactored out
...
- only references were in unit tests
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-09-04 12:56:43 +07:00
Christoph Wurst
cb057829f7
Update license headers for 19
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-29 11:57:22 +07:00
Arthur Schiwon
84619a5b9c
use serverControls directly with LDAP calls, fixes 19127
...
- 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>
2020-04-14 12:58:28 +07:00
Christoph Wurst
28f8eb5dba
Add visibility to all constants
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-10 16:54:27 +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
14c996d982
Use elseif instead of else if
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-10 10:35:09 +07:00
Christoph Wurst
44577e4345
Remove trailing and in between spaces
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 16:07:47 +07:00
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 13:54:22 +07:00
Christoph Wurst
2fbad1ed72
Fix (array) indent style to always use one tab
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 10:16:08 +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
Philipp Staiger
8769d97f62
single squashed commit for bug fix
...
Signed-off-by: Philipp Staiger <philipp@staiger.it>
2020-03-26 09:01:35 +07:00
Arthur Schiwon
5cae135b94
decouple userExists from userExistsOnLDAP check
...
allows to mark users as offline right away, avoids a gap of being not a
user and causing weird side effects
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-01-08 09:21:22 +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
Roeland Jago Douma
68748d4f85
Some php-cs fixes
...
* Order the imports
* No leading slash on imports
* Empty line before namespace
* One line per import
* Empty after imports
* Emmpty line at bottom of file
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2019-11-22 20:52:10 +07:00
Arthur Schiwon
8d2f712420
Don't process known avatars from LDAP
...
* avoids useless FS operation
* avoids useless DB writes
* avoids useless addressbook updates
* addendum to #17001
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-04 14:44:48 +07:00
Morris Jobke
36618b111f
Pass old value to user triggerChange hook
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2019-04-11 10:03:38 +07:00
Arthur Schiwon
792bcb82ae
add LDAP ConfigHandler for external storages and "$home" var
...
* handler registered upon OCA\\Files_External::loadAdditionalBackends
event as user_ldap is loaded before files_external
* new configuration field "ldapExtStorageHomeAttribute" (not in GUI yet)
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-02-14 15:22:22 +07:00
Arthur Schiwon
5c10a46445
ensure attribute names are lower cased
...
otherwise they will be skipped when the results is being formatted and the
lower-cased result keys do not match.
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-02-14 14:13:32 +07:00
Arthur Schiwon
85f14bc591
LDAP: extend remnants output with "detected on" field
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-12-21 17:24:28 +07:00
Arthur Schiwon
fbd4e9e651
add tests for the DUI
...
as they are interact with the DB they are more integraiton than unit tests
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-12-21 17:24:23 +07:00
Arthur Schiwon
8bacbffe28
do not forgot to store the second displayname portion
...
otherwise it causes a chain reaction of system addressbook updates
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-12-20 23:11:00 +07:00
Arthur Schiwon
0c5d9127e8
remove app specific IUserTools and consolidate test
...
Just some house keeping. IUserTools with used in even older days for
easier creation of Access instances…
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-10-30 22:44:50 +07:00
Roeland Jago Douma
8b2b238d86
Merge pull request #12054 from nextcloud/fix/5212/interact-with-userobject
...
LDAP: announce display name changes so that addressbook picks it up
2018-10-30 13:38:16 +07:00
Arthur Schiwon
49456e42f9
do not run into UniqueConstraintViolationException
...
… when an unmapped user logs in for the first time when background job
mode is ajax and no memcache was configured.
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-10-30 12:12:03 +07:00
Arthur Schiwon
d47e1513bc
remove unneeded empty search attribute values, fixes #12086
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-10-29 13:21:02 +07:00
Arthur Schiwon
bbe44108b5
only write when the displayname differs, but then announce it
...
refs #5212 and fixes #9112
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-10-25 23:41:12 +07:00
Arthur Schiwon
343036e55c
allow admin to disable fetching of avatars as well as a specific attribute
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-07-05 11:12:51 +07:00
Arthur Schiwon
a4dda465c2
let user set avatar in nextcloud von LDAP provides invalid image data
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-07-03 01:45:07 +07:00
Arthur Schiwon
cc51a00c93
lower log level for quota manipulation cases
...
and simplify the forest of ifs a little bit
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-06-28 21:10:07 +07:00
Roger Szabo
856164e578
Fix "Invalid argument supplied for foreach()"
...
Signed-off-by: Roger Szabo <roger.szabo@web.de>
2018-05-02 18:17:21 +07:00
Arthur Schiwon
38a90130ce
move log constants to ILogger
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-04-26 10:45:52 +07:00
Morris Jobke
2ad2eb38e8
Use type casting instead of *val() method
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2018-01-26 15:01:27 +07:00
Morris Jobke
c1e4f9f305
Use type casting instead of *val() method
...
It should be up to 6x faster
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2018-01-26 11:35:42 +07:00