aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib
Commit message (Collapse)AuthorAgeFilesLines
* Callable parameter injectionChristoph Wurst2020-07-032-3/+90
| | | | | | | | | | | | | | This is like what we have to DI and classes, but for callables. The motivating factor is to get rid of *service locators* in the `boot` method of apps as a new pattern is about to emerge where we have lots of `query` calls on the app or server container in order to fetch some services. With this little helper it's possible to call another (public) method and magically have everything injected. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #21360 from nextcloud/root-storage-prevent-scanningRoeland Jago Douma2020-07-021-0/+59
|\ | | | | prevent the root storage from accidentally scanning user folders
| * prevent the root storage from accidentally scanning user foldersRobin Appelman2020-06-111-0/+59
| | | | | | | | | | | | | | while this scan *should* never be triggered, it's good to have some failsafe to ensure that the users home contents don't end up getting scanned in the root storage Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Merge pull request #21599 from nextcloud/debt/noid/type-to-typesRoeland Jago Douma2020-07-021-3/+3
|\ \ | | | | | | Replace TYPE with TYPES
| * | Replace TYPE with TYPESDaniel Kesselberg2020-06-301-3/+3
| | | | | | | | | | | | | | | | | | As TYPE::* is deprecated. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | | Merge pull request #21653 from ↵Roeland Jago Douma2020-07-021-0/+28
|\ \ \ | | | | | | | | | | | | | | | | nextcloud/bugfix/noid/fix-ipv6-remote-addresses-from-x-forwarded-for-header Fix IPv6 remote addresses from X_FORWARDED_FOR headers before validating
| * | | Fix IPv6 remote addresses from X_FORWARDED_FOR headers before validatingJoas Schilling2020-07-021-0/+28
| |/ / | | | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* / / Fix unit testsJoas Schilling2020-06-262-9/+9
|/ / | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Fix robots "noindex, nofollow" signalsJoas Schilling2020-06-253-3/+6
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Fix testsJoas Schilling2020-06-241-1/+0
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Update share type constant usageJoas Schilling2020-06-2415-393/+395
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Add unified search APIChristoph Wurst2020-06-241-0/+6
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Fix language in share notes email for usersJoas Schilling2020-06-231-12/+29
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #21452 from ↵Joas Schilling2020-06-231-37/+47
|\ \ | | | | | | | | | | | | nextcloud/bugfix/21451/allow-autocomplete-by-displayname-again Fix autocomplete for LDAP with `shareapi_only_share_with_group_members` on
| * | Fix unit testsJoas Schilling2020-06-181-37/+47
| | | | | | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | | Merge pull request #21479 from nextcloud/fix/21474/allow_specifying_cookie_typeblizzz2020-06-221-6/+13
|\ \ \ | | | | | | | | Allow to specify the cookie type for appframework responses
| * | | Allow to specify the cookie type for appframework responsesRoeland Jago Douma2020-06-221-6/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In general it is good to set them to Lax. But also to give devs more control over them is not a bad thing. Helps with #21474 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | | | Fix unit test of the ResponseTestRoeland Jago Douma2020-06-211-3/+3
|/ / / | | | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* / / Allow crash reporters registration during app bootstrapChristoph Wurst2020-06-192-5/+49
|/ / | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Add dedicated API for apps' bootstrapping processChristoph Wurst2020-06-173-0/+345
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Merge pull request #21416 from nextcloud/fix/user-deleted-token-cleanupChristoph Wurst2020-06-161-0/+117
|\ \ | | | | | | Clean up auth tokens when user is deleted
| * | Clean up auth tokens when user is deletedChristoph Wurst2020-06-151-0/+117
| | | | | | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | | Avoid duplicate matches in wide and exact resultsJulius Härtl2020-06-151-10/+31
|/ / | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* / Increase timeout of the appstore requestsJoas Schilling2020-06-121-3/+3
|/ | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Remove dropped " ON " when join has no conditionJoas Schilling2020-06-081-6/+6
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Prevent harder to share your rootJoas Schilling2020-06-031-2/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Fix disabling send password by Talk without new password in mail sharesDaniel Calviño Sánchez2020-05-291-5/+79
| | | | | | | | | | | | | | | | | | When "send password by Talk" was disabled in a mail share it was possible to keep the same password as before, as it does not pose any security issue (unlike keeping it when "send password by Talk" is enabled, as in that case the password was already disclosed by mail). However, if a mail share is updated but the password is not set again only the hashed password will be available. In that case it would not make sense to send the password by mail, so now the password must be changed when disabling "send password by Talk". Note that, even if explicitly setting the same password again along with the "send password by Talk" property would work, this was also prevented for simplicity. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Fix enabling send password by Talk with same password in mail sharesDaniel Calviño Sánchez2020-05-281-4/+96
| | | | | | | | | | | | | When "send password by Talk" is enabled in a mail share a new password must be also set. However, when the passwords of the original and the new share were compared it was not taken into account that the original password is now hashed, while the new one is not (unless no new password was sent, in which case the password of the original share was set in the new share by the controller, but that was already prevented due to both passwords being literally the same), so it was possible to set the same password again. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Fix enabling send password by Talk with empty password in link sharesDaniel Calviño Sánchez2020-05-281-0/+69
| | | | | | | When "send password by Talk" is enabled in a link share now a non empty password is enforced. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Add lazy events for the Node APIRoeland Jago Douma2020-05-281-38/+97
| | | | | | | | | | | Right now if you want to get events via the Node API you have to have a real instance of the Root. Which in turns sets up the whole FS. We should make sure this is done lazy. Else enabling the preview generator for example makes you setup the whole FS on each and every authenticated call. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Do not read certificate bundle from data dir by defaultMorris Jobke2020-05-251-3/+2
| | | | | | | | | | | Before the resources/config/ca-bundle.crt was only used when the list of custom certificates was empty and the instance was not installed. But it should also be used when the list is empty and the instance is installed. This is inverting the logic to stop if the instance is not installed to use the default bundle. And it also does this when the list is empty. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Merge pull request #20814 from nextcloud/group-id-onlyRoeland Jago Douma2020-05-211-11/+9
|\ | | | | dont get the group details if we only ask for the id
| * dont get the group details if we only ask for the idRobin Appelman2020-05-071-11/+9
| | | | | | | | | | | | | | currenty when getting the groups for a user, the full group object is always created (and cached) even if only the groupid is required Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Revert "Compress the appstore requests by default"Morris Jobke2020-05-201-42/+5
| | | | | | | | | | | | This reverts commit 6ffde128ad17a1ebe38f8d18b21a37d01b47c46b. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Allow gzip encoded requests by defaultMorris Jobke2020-05-201-3/+7
| | | | | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Compress the appstore requests by defaultMorris Jobke2020-05-201-5/+42
| | | | | | | | | | | | In test it reduced the transfered data from 5 MB to 2 MB. This should reduce the load on the appstore significantly. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Cache appstore requests for 60 instead of 5 minutesMorris Jobke2020-05-201-7/+7
| | | | | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | l10n: Add "The" before "Following"Valdnet2020-05-151-4/+4
| |
* | Merge pull request #20939 from nextcloud/enh/middleware/not_modifiedRoeland Jago Douma2020-05-133-41/+107
|\ \ | | | | | | Move not modified check to the middleware
| * | Move the notmodified check to middleware where it belongsRoeland Jago Douma2020-05-133-41/+107
| | | | | | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | | Merge pull request #20897 from nextcloud/bugfix/httpcacheRoeland Jago Douma2020-05-131-1/+1
|\ \ \ | |/ / |/| | Proxy server could cache http response when it is not private
| * | Fix http cache testClement Wong2020-05-121-1/+1
| | | | | | | | | | | | Signed-off-by: Clement Wong <git@clement.hk>
* | | Merge pull request #20270 from nextcloud/enh/appframework/gzipRoeland Jago Douma2020-05-121-0/+163
|\ \ \ | | | | | | | | Add AppFramework compression middleware to gzip responses
| * | | Add AppFramework GZip middleware to gzip responsesRoeland Jago Douma2020-05-121-0/+163
| | | | | | | | | | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | | | Use random_bytesRoeland Jago Douma2020-05-111-4/+11
|/ / / | | | | | | | | | | | | | | | | | | Since we don't care if it is human readbale. The code is backwards compatible with the old format. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | / Adjust tests to only return group IDsMorris Jobke2020-05-081-32/+15
| |/ |/| | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Update education bundleRoeland Jago Douma2020-05-011-2/+0
| | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Fix getDirectoryContent implementation for Jail wrapperRobin Appelman2020-04-301-0/+15
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Fix Argon2 options checksMichaIng2020-04-301-0/+5
| | | | | | | | | | | | | | | | | | | | | | The minimum for memory cost is 8 KiB per thread. Threads must be checked and set first to allow checking against the correct memory cost mimimum. Options are now applied the following way: - If config.php contains the setting with an integer higher or equal to the minimum, it is applied. - If config.php contains the setting with an integer lower than the minimum, the minimum is applied. - If config.php does not contain the setting or with no integer value, the PHP default is applied. Signed-off-by: MichaIng <micha@dietpi.com> Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Merge pull request #19793 from nextcloud/bugfix/noid/link-to-federated-reshareMorris Jobke2020-04-271-18/+0
|\ \ | | | | | | Fix resharing of federated shares that were created out of links