aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files_external/lib
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #23021 from nextcloud/notify-saved-login-authblizzz2020-10-131-14/+56
|\ | | | | allow using saved login credentials for notify
| * also give storage backend it's change to manipulate the configRobin Appelman2020-10-071-0/+9
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
| * allow using saved login credentials for notifyRobin Appelman2020-09-231-14/+47
| | | | | | | | | | | | when only the user is provided, we use to provided user to try and get saved login credentials Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Merge pull request #23020 from nextcloud/disable-notify-self-checkRobin Appelman2020-10-081-1/+10
|\ \ | | | | | | add option to disable notify self check
| * | add option to disable notify self checkRobin Appelman2020-09-231-1/+10
| |/ | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* / Format code to a single space around binary operatorsChristoph Wurst2020-10-055-31/+31
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* improve handling of out of space errors for smbRobin Appelman2020-09-171-0/+6
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Remove @suppress SqlInjectionCheckerMorris Jobke2020-09-161-4/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Set delimiter so that the CommonPrefixes response can properly be determinedJulius Härtl2020-09-101-1/+2
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* fix s3 doesDirectoryExist check for empty directoriesRobin Appelman2020-09-101-1/+1
| | | | | | | | | | if a directory is empty, only the 'marker' object `/` exists. since not all s3 implementations return just the prefix when listing objects by prefix, when listing objects by the folder prefix, nothing will be returned if the directory is empty. by not including the trailing slash in the prefix, the folder marked will always be returned if it exists Signed-off-by: Robin Appelman <robin@icewind.nl>
* Fix reading empty files from objectstorageRoeland Jago Douma2020-09-091-2/+8
| | | | | | | | Since we try to do range requests this will fail hard. However since empty files are not that interesting to read anyways we just read from an emptry memory stream. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Update the license headers for Nextcloud 20Christoph Wurst2020-08-2421-5/+23
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #21734 from nextcloud/external-s3-no-touchMorris Jobke2020-08-201-17/+1
|\ | | | | disable touch to update mtime for external s3 storage
| * disable touch to update mtime for external s3 storageRobin Appelman2020-07-071-17/+1
| | | | | | | | | | | | since updating the mtime requires doing a copy this can have a significant overhead and it messes with versioning Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Use matching parameter names form interfaces and implementationsMorris Jobke2020-08-193-4/+4
| | | | | | | | | | | | Found by Psalm 3.14.1 Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Fix "misplaced variables" warning of Psalm in PHPDoc statementsMorris Jobke2020-08-171-1/+1
| | | | | | | | | | | | Ref #21787 Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Fix some MissingDocblockType or InvalidDocblock warnings.Daniel Kesselberg2020-08-142-5/+3
| | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | Remove setCustomJs of the files_external FrontendDefinitionTraitMorris Jobke2020-08-131-10/+0
| | | | | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Remove unused method uploadFileDaniel Kesselberg2020-08-131-9/+0
| | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | Move event listener to dedicated classMorris Jobke2020-07-302-22/+67
| | | | | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | update saved credentials on password changeRobin Appelman2020-07-301-1/+27
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | remove saved credentails if the user no longer has any storage configured ↵Robin Appelman2020-07-302-4/+78
| | | | | | | | | | | | using them Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Only save login credentials in database once there is an external storage ↵Robin Appelman2020-07-301-23/+29
| | | | | | | | | | | | that needs it Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Merge pull request #21728 from nextcloud/bugfix/noid/s3-external-mtime-cacheMorris Jobke2020-07-151-0/+6
|\ \ | | | | | | Reuse cache for directory mtime/size if filesystem changes can be ignored
| * | Reuse cache for directory mtime/size if filesystem changes can be ignoredJulius Härtl2020-07-071-0/+6
| |/ | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Merge pull request #21785 from ↵Morris Jobke2020-07-1312-24/+26
|\ \ | | | | | | | | | | | | nextcloud/techdebt/noid/remove-classmap-in-files_external Move OC_Mount_Config to proper classname and remove OC::$CLASSPATH us…
| * | Move OC_Mount_Config to proper classname and remove OC::$CLASSPATH usage in ↵Morris Jobke2020-07-1012-24/+26
| |/ | | | | | | | | | | files_external Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* / filter files containing a hash in the path for ftp storagesRobin Appelman2020-07-101-0/+17
|/ | | | | | | | the php ftp streamwrapper doesn't handle hashes correctly and will break when it tries to enter a path containing a hash. By filtering out paths containing a hash we can at least stop the external storage from breaking completely Signed-off-by: Robin Appelman <robin@icewind.nl>
* Move files_external to migrationsJoas Schilling2020-07-061-0/+150
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Also always return in app commandsJoas Schilling2020-06-2610-11/+19
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Remove rescanDelay from directory mtimeJulius Härtl2020-06-221-6/+1
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* normalize sftp path in read and write streamRobin Appelman2020-05-252-0/+6
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Update license headers for 19Christoph Wurst2020-04-2934-1/+34
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* add tooltip to optionRobin Appelman2020-04-221-1/+2
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Add option to check share ACL's when listing directoriesRobin Appelman2020-04-212-0/+37
| | | | | | | | | | | | | | If a file or folder in a directory doesn't have read permissions they will not be shown Note that enabling this option incurs a performance penalty additional requests need to be made to get all the acl. Additionally the acl resolving logic is fairly primitive at the moment and might not work correctly in all setups (it should error to showing the entry) Signed-off-by: Robin Appelman <robin@icewind.nl>
* Add method to storage backends to get directory content with metadataRobin Appelman2020-04-201-8/+57
| | | | | | | | | | | | | | | | | Currently you need to use `opendir` and then call `getMetadata` for every file, which adds overhead because most storage backends already get the metadata when doing the `opendir`. While storagebackends can (and do) use caching to relief this problem, this adds cache invalidation dificulties and only a limited number of items are generally cached (to prevent memory usage exploding when scanning large storages) With this new methods storage backends can use the child metadata they got from listing the folder to return metadata without having to keep seperate caches. Signed-off-by: Robin Appelman <robin@icewind.nl>
* Fix issues with Keystone auth v3 in files_external appJulien Lutran2020-04-152-2/+2
| | | | Signed-off-by: Julien Lutran <julien.lutran@corp.ovh.com>
* Add visibility to all constantsChristoph Wurst2020-04-1013-39/+39
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add visibility to all methods and position of static keywordChristoph Wurst2020-04-1012-12/+12
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-1065-128/+36
| | | | | | | | | | | | | | | 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-1010-19/+19
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #20391 from nextcloud/refactor/spaces-cleanupChristoph Wurst2020-04-093-3/+2
|\ | | | | Remove all extra whitespace PSR2 does not like
| * Make sure every file ends with an empty newlineChristoph Wurst2020-04-091-1/+0
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
| * Remove trailing and in between spacesChristoph Wurst2020-04-092-2/+2
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Merge pull request #20384 from nextcloud/techdebt/lowercase-keywordsChristoph Wurst2020-04-091-2/+2
|\ \ | |/ |/| Use php keywords in lowercase
| * Use php keywords in lowercaseChristoph Wurst2020-04-091-2/+2
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Unify function spacing to PSR2 recommendationChristoph Wurst2020-04-097-10/+10
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use exactly one empty line after the namespace declarationChristoph Wurst2020-04-099-7/+2
| | | | | | For PSR2 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix (array) indent style to always use one tabChristoph Wurst2020-04-092-7/+7
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix multiline commentsChristoph Wurst2020-04-082-6/+6
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>