Louis Chemineau
ef4281ebe3
fix(files): Correctly copy the cache information on copy operations
...
Needed to copy the `encrypted` flag of encrypted files when those files are two level down in a moved folder.
Signed-off-by: Louis Chemineau <louis@chmn.me>
2025-02-13 23:37:04 +00:00
Ferdinand Thiessen
3f8244a841
fix(files): Do not array access null value
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-01-29 10:28:01 +00:00
Robin Appelman
bb3e6ea9d9
fix: don't do same-storage move optimization with encryption wrappers
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2025-01-09 09:32:16 +01:00
Git'Fellow
8ec775bc84
fix(storage): Try to delete existing target
...
Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
2024-11-21 07:41:54 +01:00
Josh Richards
ce3cec9681
fix: Clean-up some remaining readdir calls with undesirable false evaluation potential
...
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
[skip ci]
2024-11-13 08:34:23 +05:30
Victor Dubiniuk
e9699a5a55
Fix Undefined variable: response notice in case of non-404 error
...
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
2024-11-08 16:12:15 +00:00
Benjamin Gaussorgues
31aa1fe4f5
Merge pull request #48488 from nextcloud/backport/48235/stable29
2024-10-30 09:59:56 +01:00
Daniel Calviño Sánchez
6f962c75d4
fix: Fix copying or moving from shared groupfolders
...
When copying or moving between two local storages the source path (on
disk) to copy or move from is got from the unjailed path of the source
storage. However, if the source storage has more than one jail getting
the unjailed path resolves the most external jail, but the source path
needs to be got from the most internal jail instead (the one closer to
the local storage).
This can happen, for example, with a shared groupfolder: in that case
there is an external jail for the shared storage, and one internal jail
for the groupfolder storage wrapped by the shared storage.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2024-10-29 10:41:24 +00:00
Julius Knorr
433f939d43
fix: Allow overriding shouldApplyQuota check from child classes
...
Signed-off-by: Julius Knorr <jus@bitgrid.net>
2024-10-09 16:43:10 +00:00
Robin Appelman
dd663a91d2
fix: preserve fileid when moving from objectstore to non-objectstore
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-10-09 14:50:02 +02:00
John Molakvoæ
790ef0ea17
chore: improve hash_file php usage in Local Storage
...
Co-authored-by: Ferdinand Thiessen <opensource@fthiessen.de>
Signed-off-by: John Molakvoæ <skjnldsv@users.noreply.github.com>
2024-09-16 15:18:02 +00:00
Louis Chemineau
41111e5f0a
fix(files): Ensure that the hash method does not return null
...
To match beececf660/lib/private/Files/View.php (L1050)
- Fix https://github.com/nextcloud/server/issues/44110
Signed-off-by: Louis Chemineau <louis@chmn.me>
2024-09-16 15:18:02 +00:00
provokateurin
789be3c141
fix(Storage\Local): Do not call getSourcePath() on SplFileInfo
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2024-09-15 14:52:42 +00:00
Robin Appelman
cf2826d1f7
fix: use mountpoint from storage to find the encryption keys
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-08-20 14:22:44 +00:00
Côme Chilliet
c408c3868c
fix(encryption): Fix mountpoint check to accept if several are found
...
There is no strong requirement to have only one mount for a given
storage id. Also the error in this case would be misleading.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-08-07 19:01:35 +00:00
Julius Härtl
c60725c813
fix: Pass the mountpoint target user to storages without owner
...
Storages that do not have a dedicated owner (e.g. groupfolders, external
storages) currently always assume the current session user as the owner.
This leads to several issues when there is no user session but a node is
obtained through a user folder.
In order to have the correct user available we need to pass the user
that is used to setup a mountpoint along to the storage layer as we
generally assume that an owner is available for those.
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2024-07-22 12:51:50 +00:00
Joas Schilling
0a429e0f80
fix(CI): Suppress psalm UndefinedClass
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-04-18 09:25:17 +02:00
Joas Schilling
546b0471ed
fix(files): Also skip cross storage move with access control
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-04-17 14:31:50 +00:00
Robin Appelman
6c142a3cd5
fix: use proper jailed patch in watcher
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-04-09 10:41:50 +00:00
Côme Chilliet
0b332ceac2
fix: Apply new coding standard to all files
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-04-04 11:45:22 +02:00
Robin Appelman
d5fa2ec7c3
fix: log error when default getWrapperStorage would return null
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-03-20 14:26:01 +01:00
Benjamin Gaussorgues
5158bbf09b
fix: avoid scanning a non existing directory
...
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
2024-03-14 16:26:52 +01:00
Robin Appelman
ea8a774a0a
fix: add some recrusive detection/prevention
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-03-08 14:20:14 +01:00
Ferdinand Thiessen
27642d3e6d
fix: Enforce forbidden filename characters on backend
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2024-02-28 22:19:25 +01:00
Julius Härtl
22eab7ba36
fix: Throw instead of yielding nothing when listing local directories
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2024-02-23 16:08:09 +01:00
Robin Appelman
e9d97a568f
use OCP\Server
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-02-12 16:39:00 +01:00
Robin Appelman
7a91abb439
improve di performance for cache
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-02-09 13:28:30 +01:00
Lorenz Brun
a6f879e154
dav: fix wrong decoding of pluses in URLs
...
PHP's urldecode function does not decode URLs according to RFC 3986, but
according to the HTML 4.01 query parameter
encoding. This results in pluses being wrongly decoded to spaces even
though they should not be decoded at all.
Use rawurldecode instead, which follows RFC 3986 properly.
This fixes an issue where files on DAV shares containing pluses were
incorrectly decoded to spaces.
Fixes : #15849
Signed-off-by: Lorenz Brun <lorenz@brun.one>
2024-01-31 13:26:04 +01:00
Joas Schilling
aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
2023-11-23 10:36:13 +01:00
Benjamin Gaussorgues
cb4e367a22
Merge pull request #40935 from nextcloud/local-case-insensitive
...
add some support for rename on case insensitive local filesystems
2023-11-15 13:58:44 +01:00
Robin Appelman
8418fcfedf
add some support for rename on case insensitive local filesystems
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-10-20 15:03:11 +02:00
Robin Appelman
460344336e
optimize cache jail creation
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-10-19 19:27:00 +02:00
Hamid Dehnavi
ea06cf2f39
Convert isset ternary to null coalescing operator
...
Signed-off-by: Hamid Dehnavi <hamid.dev.pro@gmail.com>
2023-09-28 17:44:19 +03:30
Robin Appelman
b11ca34bbd
Merge pull request #40499 from nextcloud/known-mtime-wrapper
...
add wrapper for external storage to ensure we don't get an mtime that is lower than we know it is
2023-09-21 18:33:15 +02:00
Robin Appelman
ef87ff1848
Merge pull request #39216 from shdehnavi/replace_substr_calls_in_lib_private
...
Refactor "substr" calls in lib/private to improve code readability
2023-09-21 16:34:27 +02:00
Robin Appelman
5bf34979fe
add wrapper to ensure we don't get an mtime that is lower than we know it is
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-09-19 13:58:15 +02:00
Julius Härtl
88a96e4db7
fix: Only store unencrypted_size if path should be encrypted
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-09-06 07:25:28 +02:00
Robin Appelman
64f62f7cfd
Merge pull request #39863 from nextcloud/sharing-mask-wrapper
...
move share permission logic to storage wrapper
2023-09-04 14:05:14 +02:00
Simon L
489a57e9a3
Merge pull request #39707 from nextcloud/bugfix/39706/local-ext-storage-unavailable-mode
2023-09-04 12:05:36 +02:00
Robin Appelman
e4f85226c5
extend fix-key-location to handle cases from broken cross-storage moves
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-08-31 19:46:47 +02:00
Vincent Petry
8d1a3daa3f
Allow ext storage Local to go unavailable
...
Whenever an external storage of type Local points at a non-existing
directory, process this as a StorageNotAvailable instead of returning
404.
This makes desktop clients ignore the folder instead of deleting it when
it becomes unavailable.
The code change was limited to external storages to avoid issues during
setup and with the default home storage.
Signed-off-by: Vincent Petry <pvince81@yahoo.fr>
2023-08-29 11:04:31 +02:00
Robin Appelman
b6c3507aa0
only determine quota_include_external_storage once for quota wrapper
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-08-18 14:25:28 +02:00
Robin Appelman
a031bc4788
more share permission logic to storage wrapper
...
this way we only have to determine the share permissions once
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-08-14 18:17:27 +02:00
Daniel Kesselberg
f1d4f7c7e4
fix: copy-and-delete fallback should use unlink
...
because rmdir does not work for files.
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2023-07-31 21:41:25 +02:00
Daniel Kesselberg
b4ff557b8c
fix(storage): fallback to copy and unlink when rename fails
...
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2023-07-31 18:54:21 +02:00
Hamid Dehnavi
d0b20534b9
Refactor "substr" calls to improve code readability
...
Signed-off-by: Hamid Dehnavi <hamid.dev.pro@gmail.com>
2023-07-07 04:54:20 +03:30
Richard Steinmetz
c4eccbb304
fix(sse): don't update uncached files
...
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
2023-07-04 12:42:29 +02:00
Robin Appelman
493e151be0
dav: clean path before putting it in the statcache
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-06-23 14:39:17 +02:00
Robin Appelman
279822c217
implement optimized getDirectoryContent for DAV
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-06-22 16:34:32 +02:00
Dominik Fuchß
e3f6a13e14
Fix deprecated method call
...
Signed-off-by: Dominik Fuchß <develop@fuchss.org>
2023-06-13 10:31:33 +02:00