Git'Fellow
003bb0aca4
fix(storage): Try to delete existing target
...
Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
2024-11-21 07:44:43 +07:00
Josh Richards
1fc1543a8b
fix: Clean-up some remaining readdir calls with undesirable false evaluation potential
...
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
2024-11-13 09:11:17 +07:00
Victor Dubiniuk
e1df152eb9
Fix Undefined variable: response notice in case of non-404 error
...
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
2024-11-08 16:14:47 +07:00
Daniel Calviño Sánchez
1a98cd52b5
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 15:02:49 +07:00
Julius Knorr
643e9ffb06
fix: Allow overriding shouldApplyQuota check from child classes
...
Signed-off-by: Julius Knorr <jus@bitgrid.net>
2024-10-28 09:46:45 +07:00
John Molakvoæ
2308294a68
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 17:08:10 +07:00
Louis Chemineau
7c99850958
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 17:08:10 +07:00
provokateurin
eb3c1a2bee
fix(Storage\Local): Do not call getSourcePath() on SplFileInfo
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2024-09-15 14:53:34 +07:00
Ferdinand Thiessen
bcd26323c1
fix: Also validate parent path in `verifyPath`
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2024-08-28 20:24:03 +07:00
Robin Appelman
fff198657f
fix: use mountpoint from storage to find the encryption keys
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-08-20 14:24:43 +07:00
Côme Chilliet
277c2cf5d1
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-05 17:34:25 +07:00
withbest
dd08f93202
chore: fix some comments
...
Signed-off-by: withbest <seekseat@outlook.com>
2024-07-29 14:43:27 +07:00
Dennis Verspuij
181aecad4c
fix: Release directory iterator and thereby its potential directory lock prior to deleting a directory, to avoid e.g. "Text file busy" error with VirtualBox shared folder storage
...
Signed-off-by: Dennis Verspuij <6680484+dennisverspuij@users.noreply.github.com>
2024-07-27 16:37:16 +07:00
Ferdinand Thiessen
69341e4306
refactor: Migrate filename validation logic from `Storage` to `FilenameValidator`
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2024-07-16 12:49:09 +07:00
John Molakvoæ
91227c908b
Merge branch 'master' into refactor/OC-Server-getHTTPClientService
...
Signed-off-by: John Molakvoæ <skjnldsv@users.noreply.github.com>
2024-05-30 14:21:45 +07:00
Andy Scherzinger
dae7c159f7
chore: Add SPDX header
...
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
2024-05-24 13:11:22 +07:00
Côme Chilliet
672923f0a6
fix: Fix newly spotted psalm issues, add exhaustive typed magic properties for LDAP classes
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-04-30 09:23:58 +07:00
Joas Schilling
7cfe36e49b
fix(storage): Fix DAV storage as false is never returned
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-04-22 21:06:00 +07:00
Joas Schilling
64d32abb48
fix(CI): Suppress psalm UndefinedClass
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-04-18 09:24:11 +07:00
Joas Schilling
050408c9de
fix(files): Also skip cross storage move with access control
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-04-17 16:29:07 +07:00
Julius Härtl
e0fcf6b700
Merge pull request #44294 from nextcloud/fix/storage-mount-owner
...
fix: Pass the mountpoint target user to storages without owner
2024-04-09 13:18:13 +07:00
Julius Härtl
4910e7e231
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-04-09 09:04:24 +07:00
Robin Appelman
d31ed8dbca
fix: use proper jailed patch in watcher
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-04-08 18:37:05 +07:00
Côme Chilliet
ec5133b739
fix: Apply new coding standard to all files
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-04-02 14:16:21 +07: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 +07: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 +07:00
Robin Appelman
ea8a774a0a
fix: add some recrusive detection/prevention
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-03-08 14:20:14 +07: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 +07: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 +07:00
Robin Appelman
e9d97a568f
use OCP\Server
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-02-12 16:39:00 +07:00
Robin Appelman
7a91abb439
improve di performance for cache
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-02-09 13:28:30 +07: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 +07: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 +07: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 +07: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 +07:00
Robin Appelman
460344336e
optimize cache jail creation
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-10-19 19:27:00 +07: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 +07:00
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 +07: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 +07: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 +07: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 +07: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 +07:00
Simon L
489a57e9a3
Merge pull request #39707 from nextcloud/bugfix/39706/local-ext-storage-unavailable-mode
2023-09-04 12:05:36 +07: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 +07:00
Andrew Summers
4536029589
Refactor `OC\Server::getHTTPClientService`
...
Signed-off-by: Andrew Summers <18727110+summersab@users.noreply.github.com>
2023-08-29 21:30:01 +07: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 +07: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 +07: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 +07: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 +07: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 +07:00