Commit graph

11064 commits

Author SHA1 Message Date
Julius Härtl
420d395947
Merge pull request #27415 from nextcloud/backport/26494/stable21 2021-06-14 09:48:41 +02:00
Julius Härtl
6e190b1a55
Merge pull request #27303 from nextcloud/backport/27062/stable21
[stable21] properly use limit and offset for search in Jail wrapper
2021-06-09 08:07:49 +02:00
Richard de Boer
9f3824b884 Check whether output buffering is active before turning it off
Before we just turned it off and @suppressed the error if ob was not active.
In PHP 8 this error is no longer suppressed, so try to not cause it at all.

Signed-off-by: Richard de Boer <git@tubul.net>
2021-06-07 21:33:53 +00:00
Richard de Boer
7e9d459fea Fix functions taking optional parameters before required ones
PHP 8 shows deprecation warnings about this, see #25806
Removes the "default" values, as they actually are required parameters anyway.

Signed-off-by: Richard de Boer <git@tubul.net>
2021-06-07 21:33:52 +00:00
Morris Jobke
4136993f44
Merge pull request #27336 from nextcloud/backport/27329/stable21
[stable21] Propagate throttling on OCS response
2021-06-07 10:39:52 +02:00
John Molakvoæ
390bd12c8a
Merge pull request #27333 from nextcloud/backport/27328/stable21
[stable21] emit UserLoggedInEvent on apache auth
2021-06-06 11:00:24 +02:00
Robin Appelman
287edf0e61
Set umask before operations that create local files
this solves issues where "other php stuff" is messing with the umask

Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-06-04 15:43:16 +02:00
Joas Schilling
c89fbcde11
Merge pull request #27347 from nextcloud/backport/27053/stable21
[stable21] Don't throw when comments is disabled
2021-06-04 11:01:31 +02:00
Joas Schilling
5593ec985e Don't throw when comments is disabled
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-06-02 13:42:49 +00:00
Lukas Reschke
6a6bcdc558 Propagate throttling on OCS response
The BaseResponse converter did not take over any throttling state from the DataResponse.

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-06-01 19:42:31 +00:00
Richard Steinmetz
5c868c735d Don't allow executing cli if cache backend is unavailable
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
2021-06-01 16:07:07 +00:00
Arthur Schiwon
2e57360a0d emit UserLoggedInEvent on apache auth
- post_login OC_Hook is barely used or listened to

Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-06-01 15:41:04 +00:00
Robin Appelman
a21eb8d6d2 properly use limit and offset for search in Jail wrapper
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-05-31 12:28:12 +00:00
Morris Jobke
a1877062ac Use noreply@ as email address for share emails
Fixes #26683

Before it used the instance name, which a) doesn't make sense to randomly guess email addresses and b) could contain characters that are not allowed in email addresses like spaces.

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2021-05-28 11:42:16 +00:00
Robin Appelman
5bb0370994 improve type handling of Avatar::generateAvatarFromSv
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-05-26 17:11:42 +00:00
Florent
ede67149ea Avoid reading ~/.aws/config when using S3 provider
When using S3 storage, we sometimes have open_basedir errors due to aws-sdk-php trying to read ~/.aws/config which is out of open_basedir restrictions.
Christoph Wurst already added csm=false config in #21406 but it wasn't enough, we also need to set use_arn_region=false, added in this commit.

Signed-off-by: Florent <florent@coppint.com>
2021-05-25 08:59:03 +00:00
Julius Härtl
80cda3b174 Fix log error when creating files from an empty template
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-05-19 07:03:27 +00:00
Joas Schilling
3d9abee6f0
Don't break OCC if an app is breaking in it's Application class
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-05-06 14:46:11 +02:00
Roeland Jago Douma
f4135573d0 Do not try to contact lookup server if not needed
In some cases (for example you never send data to the lookup server)
there is no need for this job to even try.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-04-29 09:07:38 +02:00
Julius Härtl
e2fffcda44 Fail when creating new files with an empty path
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-04-28 10:06:03 +00:00
Joas Schilling
ab595274c0 Do not allow to overwrite some variables
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-27 13:40:14 +00:00
Joas Schilling
6a8d6beb57 Fix ratelimit template
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-27 13:40:12 +00:00
Roeland Jago Douma
4082318616
Merge pull request #26760 from nextcloud/backport/26259/stable21
[stable21] Validate the website field input to be a valid URL
2021-04-26 20:42:06 +02:00
Roeland Jago Douma
e075f80f41
Merge pull request #26759 from nextcloud/backport/26747/stable21
[stable21] Fix installer deprecation warnings for PHP 8
2021-04-26 20:41:49 +02:00
Joas Schilling
d1756dde20 Log deprecation only as debug
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-26 15:12:50 +00:00
Joas Schilling
6ed9bb36ac Respect the error level when logging
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-26 15:12:50 +00:00
Joas Schilling
2c1218826d Validate the website field input to be a valid URL
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-26 11:58:56 +00:00
acsfer
63fa7d9354 PHP 8+ deprecates openssl_free_key 2021-04-26 10:46:44 +00:00
acsfer
c12be83a0b Only use libxml_disable_entity_loader on PHP<8 2021-04-26 10:46:44 +00:00
Maxence Lange
35204381bb private cannot be final
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
2021-04-26 07:06:08 +00:00
Roeland Jago Douma
97e5fe43df Explicitly check hex2bin input
For #23197

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-04-22 11:31:39 +00:00
Roeland Jago Douma
f915efc859
Merge pull request #26639 from nextcloud/backport/26551/stable21
[stable21] ensure redis returns bool for hasKey
2021-04-20 10:33:18 +02:00
Arthur Schiwon
92e1606c18
ensure redis returns bool for hasKey
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-04-19 23:40:47 +02:00
Vincent Petry
fe0f1c792c
Fix empty password check for mail shares
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-04-19 15:44:26 +02:00
Lukas Reschke
ad91f39c46 Limit size of properties to 2048 characters
It is unreasonable to expect that one of these fields would be longer
than 2048 characters. Whilst some have definitely lower limits (such as
for phone numbers or domain names), a upper bound as sanity check makes
sense.

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-04-12 16:37:04 +00:00
Lukas Reschke
b5838c5248 Increase subnet matcher
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-04-12 10:36:25 +00:00
Lukas Reschke
d66e86c56c
Merge pull request #26400 from nextcloud/backport/26061/stable21
[stable21] Log and continue when failing to update encryption keys during for individual files
2021-04-06 13:43:34 +02:00
John Molakvoæ
b59cf16325
Merge pull request #26406 from nextcloud/backport/26396/stable21 2021-04-02 16:59:51 +02:00
Julius Härtl
dc8e819915 Properly handle creating the template directory in a subfolder (fixes #25787)
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-04-01 13:31:55 +00:00
Julius Härtl
89a19a338e Get the parent directory before creating a file from a template
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-04-01 13:31:55 +00:00
Robin Appelman
40507ca543
make ILDAPProviderFactory usable when there is no ldap setup
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-04-01 13:08:23 +02:00
Vincent Petry
6ac708c99a Fix phpcs issues in encryption update
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-04-01 07:56:41 +00:00
Julius Härtl
d6bad03a5c Log and continue when failing to update encryption keys during for individual files
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-04-01 07:56:41 +00:00
Joas Schilling
0c348863e7 Allow apps to write/update account data
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-01 06:07:47 +00:00
kesselb
618a48487f
Merge pull request #26377 from nextcloud/backport/25500/stable21
[stable21] fix(translation): replace static error message
2021-03-31 10:07:58 +02:00
Julius Härtl
00daf58da8
Merge pull request #26376 from nextcloud/backport/25804/stable21
[stable21] Do not attempt to read 0 bytes when manually iterating over a non-seekable file
2021-03-31 09:44:47 +02:00
Christoph Wurst
0432b32535
Merge pull request #26379 from nextcloud/backport/25924/stable21
[stable21] Only mark migrations as installed after execution
2021-03-31 07:43:32 +02:00
Arthur Schiwon
caec3a8cee gracefully handle deleteFromSelf when share is already gone
- handling race conditions

Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-03-30 20:26:29 +00:00
Joas Schilling
e3927afe19 Only mark migrations as installed after execution
The problem is that if a developer creates a structural error in their migration file,
they will already be marked as executed and an not be rerun.

Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-03-30 19:51:12 +00:00
Samuel
3073732002 revert(comment)
Signed-off-by: Samuel <faust64@gmail.com>
2021-03-30 19:26:04 +00:00