Côme Chilliet
f3dcbfe146
Fix PHP 8.1 support for user_ldap application
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2 lat temu
Côme Chilliet
480056de88
Fix sanitizing regex and add a test case for uppercase in username
I did not find any test data that would fail with the previous regex,
but still added data with uppercase to at least test that.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2 lat temu
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>
2 lat temu
Côme Chilliet
158e73242e
Avoid use of iconv to get rid of unicode
Using iconv for translit depends upon server configuration, locale, and
PHP version. Using htmlentities instead to have a consistent behavior
independent of configuration.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2 lat temu
Côme Chilliet
51398d706a
Use Psr\Log\LoggerInterface in OCA\User_LDAP\Access
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2 lat temu
Arthur Schiwon
6ab30a669b
ensure that user and group IDs in LDAP's tables are also max 64chars
- limitation by core tables (e.g. sharing), IDs are always 64chars
- when longer group IDs were requested they are hashed (does not affect
displaynames)
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2 lat temu
Gary Kim
b78f3a57d1
Migrate HintException to OCP
Signed-off-by: Gary Kim <gary@garykim.dev>
3 lat temu
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
3 lat temu
dependabot-preview[bot]
eb502c02ff
Bump nextcloud/coding-standard from 0.3.0 to 0.5.0
Bumps [nextcloud/coding-standard](https://github.com/nextcloud/coding-standard ) from 0.3.0 to 0.5.0.
- [Release notes](https://github.com/nextcloud/coding-standard/releases )
- [Changelog](https://github.com/nextcloud/coding-standard/blob/master/CHANGELOG.md )
- [Commits](https://github.com/nextcloud/coding-standard/compare/v0.3.0...v0.5.0 )
Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 lat temu
Arthur Schiwon
02b703193a
really use known groups
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
3 lat temu
Roeland Jago Douma
54ef1a73af
Cancel 1 LDAP test for php8
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
3 lat temu
Joas Schilling
5fba0e562f
Use query builder instead of OC_DB in user_ldap
Signed-off-by: Joas Schilling <coding@schilljs.com>
3 lat temu
Arthur Schiwon
fd1fd5afa4
user share manager to determine share ownership
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
3 lat temu
Christoph Wurst
d9015a8c94
Format code to a single space around binary operators
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 lat temu
Morris Jobke
234b510652
Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to \PHPUnit\Framework\MockObject\MockObject
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
3 lat temu
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>
4 lat temu
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>
4 lat temu
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 lat temu
Christoph Wurst
1a9330cd69
Update the license headers for Nextcloud 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 lat temu
Christoph Wurst
b80ebc9674
Use the short array syntax, everywhere
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 lat temu
Christoph Wurst
2ee65f177e
Use the shorter phpunit syntax for mocked return values
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 lat temu
Christoph Wurst
5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 lat temu
Roeland Jago Douma
3a7cf40aaa
Mode to modern phpunit
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4 lat temu
Roeland Jago Douma
c007ca624f
Make phpunit8 compatible
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4 lat temu
Arthur Schiwon
73cacb8896
check user state when fetching to avoid dealing with offline objects
fixes #9502
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
f1565336bd
DI for NC's user manager
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
47a10bd25a
treat iconv issues
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
8607992e85
do not create empty userid when attribute does not have allowed chars
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
27f14eee26
don't cache user, if no internal user id was retrieved/assigned
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
991190b994
ensure that users are cached when they are retrieved
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
419759e68b
resolve DI
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
fc6b3902af
adjust tests
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
ef3cd32916
don't skip updating when ajax is set as background job mode
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Arthur Schiwon
c6f1af9896
move ldap user sync to background (WIP)
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
6 lat temu
Morris Jobke
0eebff152a
Update license headers
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
6 lat temu
Roger Szabo
5e7723f15c
restore ldap_password_renew_pr
Signed-off-by: Roger Szabo <roger.szabo@web.de>
7 lat temu
Lukas Reschke
4c5e7d270a
Add tests
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
7 lat temu
Arthur Schiwon
a49d571799
fix and tidy up tests after merge conflicts
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
7 lat temu
Victor Dubiniuk
c4fcd1f282
Update tests for phunit 5.5
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
7 lat temu
Roeland Jago Douma
bdf4bf4669
DI IConfig into ldap helper
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
7 lat temu
Joas Schilling
01cf85e4e5
Fix the User_LDAP app
7 lat temu
Roeland Jago Douma
5fb2eee5df
Fix getMock user_ldap
7 lat temu
Jörn Friedrich Dreyer
4d31caa6f8
fix a few minor code smells
7 lat temu
root
02ec8b1726
New LDAPProvider for user_ldap
8 lat temu
Joas Schilling
813f0a0f40
Fix apps/
8 lat temu
Lukas Reschke
aba539703c
Update license headers
8 lat temu
Joas Schilling
3ef8c95b37
Move tests/ to PSR-4
8 lat temu
Joas Schilling
c807a26bd8
Move Access to PSR-4
8 lat temu
Joas Schilling
af0a6961b1
Move Connection to PSR-4
8 lat temu
Joas Schilling
387019a212
Move FilesystemHelper to PSR-4
8 lat temu