summaryrefslogtreecommitdiffstats
path: root/lib/private
Commit message (Collapse)AuthorAgeFilesLines
* Fix updating with appsJoas Schilling2021-11-112-2/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #29383 from nextcloud/backport/29304/stable22John Molakvoæ2021-11-041-1/+1
|\
| * Patch for master-branchJanBartels2021-10-221-1/+1
| |
* | Merge pull request #29506 from nextcloud/backport/29281/stable22John Molakvoæ2021-11-042-6/+14
|\ \
| * | Move query outside the loop and reduce chunk size to 1000Sijmen Schoon2021-11-012-12/+14
| | | | | | | | | | | | | | | | | | | | | This involved changing CacheQueryBuilder\whereParentIn to take a parameter name, renaming the function accordingly. Signed-off-by: Sijmen Schoon <me@sijmenschoon.nl>
| * | Limit parameter count per query in Cache.removeChildrenSijmen Schoon2021-11-011-8/+14
| | | | | | | | | | | | Signed-off-by: Sijmen Schoon <me@sijmenschoon.nl>
* | | Fix resource usages in OC_ImageCôme Chilliet2021-11-025-22/+25
|/ / | | | | | | | | | | This makes sure using resource or GdImage (PHP>=8) behaves the same. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* | Merge pull request #29475 from nextcloud/backport/29115/stable22Carl Schwan2021-10-302-1/+9
|\ \ | | | | | | [stable22] Fix permissions when copying from ObjectStorage
| * | Fix permissions when copying from ObjectStorageCarl Schwan2021-10-302-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure that when a user copy a file from a directory they don't have all permissions to a directory where they have more permissions, the permissions are correctly set to the one from the parent taget folder. This was caused by the ObjectStoreStorage::copyFromStorage using the jailed storage and cache entry instead of the unjailed one like other storages (the local one). Steps to reproduce + Use object storage + Create a groupfolder with one group having full permission and another one who can just read files. + With an user who is in the second group, copy a file from the groupfolder to the home folder of this user. + The file in the home folder of the user will be read only and can't be deleted even though it is in their home folder and they are the owner. In oc_filecache, the permissions stored for this file are 1 (READ) Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* | | Merge pull request #29415 from nextcloud/backport/27440/stable22MichaIng2021-10-301-4/+4
|\ \ \ | |/ / |/| | [stable22] Handle files with `is_file` instead of `file_exists`
| * | Handle files with is_file instead of file_existsacsfer2021-10-231-4/+4
| | | | | | | | | Should fix things like `fread(): read of 8192 bytes failed with errno=21 Is a directory`
* | | Merge pull request #29391 from nextcloud/backport/29220/stable22MichaIng2021-10-232-2/+9
|\ \ \ | | | | | | | | [stable22] s3 external storage fixes
| * | | more reliable return value for Watcher::checkUpdateRobin Appelman2021-10-221-1/+8
| | | | | | | | | | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
| * | | s3 external storage listing reworkRobin Appelman2021-10-221-1/+1
| | |/ | |/| | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | | Make the route name error more helpfulChristoph Wurst2021-10-222-2/+2
| |/ |/| | | | | | | | | | | | | As a developer I have no clue what "Invalid route name" means. If the exception gives me a hint I might find it easier to figure out why my route triggers this error. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Prevent duplicate auth token activity updatesChristoph Wurst2021-10-222-2/+40
|/ | | | | | | | | | | | | | | | | | | | | | | | | | The auth token activity logic works as follows * Read auth token * Compare last activity time stamp to current time * Update auth token activity if it's older than x seconds This works fine in isolation but with concurrency that means that occasionally the same token is read simultaneously by two processes and both of these processes will trigger an update of the same row. Affectively the second update doesn't add much value. It might set the time stamp to the exact same time stamp or one a few seconds later. But the last activity is no precise science, we don't need this accuracy. This patch changes the UPDATE query to include the expected value in a comparison with the current data. This results in an affected row when the data in the DB still has an old time stamp, but won't affect a row if the time stamp is (nearly) up to date. This is a micro optimization and will possibly not show any significant performance improvement. Yet in setups with a DB cluster it means that the write node has to send fewer changes to the read nodes due to the lower number of actual changes. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix security issues when copying groupfolder with advanced ACLCarl Schwan2021-10-211-1/+4
| | | | | | | | | | Using advanced ACL, it is possible that an user has access to a directory but not to a subdirectory, so the copying use Common::copyFromStorage instead of Local::copyFromStorage. Fix https://github.com/nextcloud/groupfolders/issues/1692 Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* Merge pull request #29288 from nextcloud/backport/28768/stable22John Molakvoæ2021-10-211-1/+1
|\
| * Simplify :)acsfer2021-10-181-1/+1
| |
| * Replace `file_exists()` method by `is_file()`acsfer2021-10-181-1/+1
| |
| * Get `filesize()` if `file_exists()`acsfer2021-10-181-1/+1
| | | | | | Should make sense.
* | Merge pull request #29301 from nextcloud/backport/29259/stable22Joas Schilling2021-10-191-8/+10
|\ \ | | | | | | [stable22] Fix app upgrade
| * | Fix app upgradeJoas Schilling2021-10-181-8/+10
| |/ | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #29183 from nextcloud/backport/29028/stable22John Molakvoæ2021-10-191-3/+13
|\ \ | |/ |/|
| * add 'supported'-label to all supported apps, also if they are not downloaded yetBjoern Schiessle2021-10-121-3/+13
| | | | | | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* | Add proper message to created share not foundJohn Molakvoæ (skjnldsv)2021-10-131-1/+1
| | | | | | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* | Merge pull request #29196 from nextcloud/backport/29020/stable22blizzz2021-10-132-5/+18
|\ \ | | | | | | [stable22] Keep group restrictions when reenabling apps after an update
| * | Keep group restrictions when reenabling apps after an updateJoas Schilling2021-10-132-5/+18
| |/ | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* / Fix translated app detailsJoas Schilling2021-10-132-6/+5
|/ | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #29160 from nextcloud/backport/24185/stable22Julius Härtl2021-10-121-0/+1
|\
| * Make sure that a empty directory can still be deleted when copied from ↵Julius Härtl2021-10-111-0/+1
| | | | | | | | | | | | another storage Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Merge pull request #29129 from nextcloud/backport/27886/stable22MichaIng2021-10-122-0/+10
|\ \ | | | | | | [stable22] Keep pw based auth tokens valid when pw-less login happens
| * | add spaces around operatorsTobias Assmann2021-10-082-2/+2
| | | | | | | | | | | | Signed-off-by: Tobias Assmann <tobias.assmann@ecsec.de>
| * | draft to prevent the invalidation of pw based authn tokens on a pw less loginTobias Assmann2021-10-082-0/+10
| | | | | | | | | | | | Signed-off-by: Tobias Assmann <tobias.assmann@ecsec.de>
* | | Merge pull request #29133 from nextcloud/backport/28907/stable22Julius Härtl2021-10-112-3/+7
|\ \ \
| * | | explicitly close source stream on encryption storageDaniel Kesselberg2021-10-081-2/+3
| | | | | | | | | | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
| * | | explicitly close source stream on local storageDaniel Kesselberg2021-10-081-1/+4
| |/ / | | | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | / Tokens without password should not trigger changed password invalidationJulius Härtl2021-10-111-1/+1
| |/ |/| | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Merge pull request #29124 from nextcloud/backport/29123/stable22John Molakvoæ2021-10-081-1/+1
|\ \
| * | Set associative = true for cleanup jobDaniel Kesselberg2021-10-071-1/+1
| |/ | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* / generate a better optimized query for path prefix search filtersRobin Appelman2021-10-077-9/+175
|/ | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Merge pull request #29086 from nextcloud/backport/29082/stable22MichaIng2021-10-061-0/+21
|\ | | | | [stable22] Add a few sensitive config keys
| * consider some config keys under 'objectstore_multibucket' as sensitiveJulien Veyssier2021-10-061-0/+21
| | | | | | | | Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
* | Merge pull request #29062 from nextcloud/backport/28939/stable22Julius Härtl2021-10-061-0/+6
|\ \ | |/ |/|
| * Don't further setup disabled users when logging in with apacheJoas Schilling2021-10-041-0/+6
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Avoid usage of Nextcloud API, use PHP functionacsfer2021-10-041-1/+1
| |
* | Fix path of `file_get_contents`acsfer2021-10-041-1/+1
|/ | | | | Try to fix #28370 and #27441 Avoid pre-pends the `$path` to the user's own storage.
* Fix Lots of Error: file_exists(): open_basedir restriction in effect. in LogKarel Hink2021-10-014-5/+9
| | | | Signed-off-by: Karel Hink <info@karelhink.cz>
* Prevent empty base URL during installationLouis Chemineau2021-09-291-1/+2
| | | | Signed-off-by: Louis Chemineau <louis@chmn.me>
* Merge pull request #28954 from nextcloud/backport/28933/stable22Vincent Petry2021-09-271-6/+6
|\ | | | | [stable22] Fix check for redis minimal version