John Molakvoæ (skjnldsv)
c26b1e4b07
fix(s3): add Content-MD5 header for DeleteObjects to fix AWS SDK v3.339.0+ compatibility
...
AWS SDK PHP v3.339.0+ introduced a breaking change requiring the Content-MD5
header for DeleteObjects operations. This causes 'MissingContentMD5' errors when
using S3-compatible services like MinIO.
Add middleware to automatically calculate and inject the Content-MD5 header on
all DeleteObjects requests. This is applied universally at the S3ConnectionTrait
level, fixing both external storage (AmazonS3) and core ObjectStore (S3) classes.
Fixes: https://github.com/aws/aws-sdk-php/issues/3068
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2026-05-12 09:07:20 +02:00
Robin Appelman
9f5535d01b
fix: apply quota with writeStream
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-05-02 14:04:09 +02:00
Robin Appelman
f3a5bc8c17
fix: block writing empty files with 0 quota
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-05-02 14:04:09 +02:00
Ferdinand Thiessen
be2ac0bd86
Merge pull request #59932 from nextcloud/carl/copySkeleton
...
refactor: Move copy skeleton step to a file listener
2026-04-29 23:15:38 +02:00
Ferdinand Thiessen
e5b1799079
chore: add missing Override attribute to test files
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2026-04-28 21:29:28 +02:00
Carl Schwan
bb4c55c125
refactor: Move copy skeleton step to a file listener
...
Instead of having all user providers call OC_Util::copySkeleton
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-04-27 15:37:02 +02:00
Joas Schilling
aa904b255f
Merge pull request #59378 from nextcloud/carl/non-internal-api
...
chore: Replace MoveableMount usage with IMovableMount
2026-04-27 12:37:56 +02:00
Robin Appelman
cf06ebf999
test: more tests for UserMountCache
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-04-24 18:17:43 +02:00
Carl Schwan
fbf84e6473
chore: Replace MoveableMount usage with IMovableMount
...
The former is private API while the IMovableMount is public.
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-04-24 10:14:37 +02:00
Kostiantyn Miakshyn
fcb10219d1
fix: Allow num_buckets to be equal as min_bucket
...
Signed-off-by: Kostiantyn Miakshyn <molodchick@gmail.com>
2026-04-19 18:28:12 +02:00
Stephen Cuppett
cdaeed02b6
feat(objectstore): Add AWS SSE-KMS encryption support for S3 storage
...
Add support for Server-Side Encryption with AWS Key Management Service
(SSE-KMS) for S3 object storage. This allows Nextcloud to encrypt data
at rest in S3 using AWS-managed keys.
Key features:
- New config options: sse_kms_enabled and sse_kms_key_id
- Backward compatible with existing SSE-C (customer-provided keys)
- SSE-C takes precedence when both SSE-C and SSE-KMS are configured
Implementation details:
- Added getServerSideEncryptionParameters() method to centralize
encryption parameter logic for both SSE-C and SSE-KMS
- Updated multipart uploads to use unified encryption parameters
- Added comprehensive PHPUnit tests for SSE-KMS scenarios
- Tested with AWS bucket and KMS keys in us-east-1 region
Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
Signed-off-by: Stephen Cuppett <steve@cuppett.com>
2026-04-16 13:21:53 -04:00
Louis Chmn
72812b2b07
chore(Scanner): Use modern syntax and APIs
...
Signed-off-by: Louis Chmn <louis@chmn.me>
2026-04-08 12:26:55 +02:00
Josh
8895970019
test(ViewTest): disable Nextcloud not PHP - drop testTouchFloat()
...
Our interface contract (and implementations) in IStorage are:
`public function touch(string $path, ?int $mtime = null): bool {`
This wasn't always the case but it is today, so testTouchFloat() no longer makes sense; it's not testing our code, just PHP.
Signed-off-by: Josh <josh.t.richards@gmail.com>
2026-03-10 22:12:42 -04:00
Robin Appelman
cf124e7c75
fix: make objectstore copy consistent with changed local storage behavior
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-03-10 16:07:38 +01:00
Kate
810caa3e4a
Merge pull request #58593 from nextcloud/carl/share-spring-cleaning
2026-03-10 15:01:50 +01:00
Côme Chilliet
397454ff4a
fix: Adapt ViewTest to ['path'] being absolute
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2026-03-10 12:34:50 +01:00
Carl Schwan
7fa44717e0
refactor(share): Remove some deprecated method usages
...
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-03-10 11:39:57 +01:00
Carl Schwan
af94028bdb
refactor: Remove old Share backend
...
This has been implicitely deprecated for a while with Share20 containing
the new implementation.
The only use was to determine whether remote sharing was enabled or not,
which we can do much more easily.
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-03-10 10:09:40 +01:00
Côme Chilliet
8aedcb4a82
Merge pull request #58652 from nextcloud/automated/noid/rector-changes
...
Apply rector changes
2026-03-05 16:03:50 +01:00
Robin Appelman
d14c4082e1
test: add test for updating cached mounts with multiple entries for root id
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-03-04 18:43:35 +01:00
Josh
2d39c5a179
test(Storage): avoid falsy directory/filename checks (for now)
...
Signed-off-by: Josh <josh.t.richards@gmail.com>
2026-03-02 13:44:20 +01:00
Josh
ace9eb21e6
test(Storage): expand file / directory name tests
...
Signed-off-by: Josh <josh.t.richards@gmail.com>
2026-03-02 13:44:20 +01:00
nextcloud-command
663018455e
refactor: Apply rector changes
...
Signed-off-by: GitHub <noreply@github.com>
2026-03-01 14:43:11 +00:00
Robin Appelman
bd8f251ad8
test: add test for calling filesize on non-existing files
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-02-24 15:32:06 +01:00
provokateurin
4eada2d804
refactor(Files): Modernize Wrapper
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2026-02-17 06:43:16 +01:00
provokateurin
5f4a5d8c67
refactor(Files): Remove deprecated streamCopy method
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2026-02-17 06:43:16 +01:00
Andy Scherzinger
39ff32a33b
Merge pull request #58134 from nextcloud/carl/lock-propagator-order
...
fix(propagator): Improve lock behavior of propagator
2026-02-09 16:04:38 +01:00
Carl Schwan
f3778bc9c7
fix(propagator): Improve lock behavior of propagator
...
Fix possible dead locks when running the propagator caused by two
requests updating the same amount rows in transactions.
- Lock rows always in the same deterministic order by sorting the
path_hash first
- On all database outside of sqlite, also do first a SELECT FOR UPDATE
to lock all the rows used in batch UPDATE calls, afterward to decrease
the risk of two requests trying to lock the same rows
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-02-09 12:10:56 +01:00
provokateurin
f12cecb684
feat(rector): Enable SafeDeclareStrictTypesRector
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2026-02-09 10:59:31 +01:00
Ferdinand Thiessen
762ae4520a
fix(InMemoryFile): allow to stream read the contents
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2026-02-06 17:29:26 +01:00
Carl Schwan
9a26169323
fix(WatcherTest): Properly mock getCache and getScanner in IStorage
...
Otherwise we end up with trying to assign null to a property which has
strict types.
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-02-06 14:21:41 +01:00
Carl Schwan
c96ece0bcb
refactor: Add more typing
...
- repairs job
- database
- redis
And remove Helpertest which was unused outside of some tests.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2026-02-06 13:55:39 +01:00
Carl Schwan
5d0d0c17e5
chore(rector): Run rector on apps, core and tests directory
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2026-02-06 13:23:23 +01:00
Robin Appelman
bea82ac656
test: adjust tests to updated getById
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-02-04 18:23:35 +01:00
Robin Appelman
be2c26a75b
test: adjust tests to new getById
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-02-04 18:23:33 +01:00
Carl Schwan
04ddeeec4a
perf(MountManager): use binary search to find mount in path
...
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-01-29 11:41:58 +01:00
Robin Appelman
94f33463ff
test: adjust tests
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-01-21 16:35:55 +01:00
Carl Schwan
7b05c8f797
refactor(files): Rename IMountProviderArgs
...
It's not an interface so the I-prefix is inadequate.
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-01-12 17:33:52 +01:00
Benjamin Gaussorgues
fe34ea5ec7
Merge pull request #57407 from nextcloud/carl/fix-php-85-deprecation-image
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Integration sqlite / changes (push) Waiting to run
Integration sqlite / integration-sqlite (master, 8.4, main, --tags ~@large files_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, capabilities_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, collaboration_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, comments_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, dav_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, federation_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, file_conversions) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, files_reminders) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, filesdrop_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, ldap_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, openldap_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, openldap_numerical_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, remoteapi_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, routing_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, setup_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, sharees_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, sharing_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, theming_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (master, 8.4, main, videoverification_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite-summary (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis (push) Waiting to run
Psalm static code analysis / static-code-analysis-security (push) Waiting to run
Psalm static code analysis / static-code-analysis-ocp (push) Waiting to run
Psalm static code analysis / static-code-analysis-ncu (push) Waiting to run
2026-01-08 13:57:11 +01:00
Salvatore Martire
07eef5eaf4
fix: drop set up partial mounts on setupForUser
...
Signed-off-by: Salvatore Martire <4652631+salmart-dev@users.noreply.github.com>
2026-01-07 17:00:09 +01:00
Carl Schwan
bd815595d4
fix: Remove NOP ReflectionProperty::setAccessible calls
...
Doesn't do anything since PHP 8.1 and is deprecated since PHP 8.5
2026-01-07 15:23:20 +01:00
Robin Appelman
047ff27e46
test: add tests for watcher check filter
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2025-12-31 12:23:04 +01:00
Salvatore Martire
6e9ba894a2
fix: add $forChildren parameter to IPartialMountProvider
...
Signed-off-by: Salvatore Martire <4652631+salmart-dev@users.noreply.github.com>
2025-12-29 18:06:12 +01:00
Ferdinand Thiessen
be8b2bfa8b
Merge pull request #57228 from nextcloud/fix/setup-for-path-caching
...
fix: adjust authoritative setup path caching logic
2025-12-23 16:49:05 +01:00
Ferdinand Thiessen
8c90d4f822
Merge pull request #56919 from nextcloud/jtr/fix-mime-detection-tests
...
fix(files/type): preserve numeric keys (follow-up)
2025-12-23 16:01:01 +01:00
Salvatore Martire
6c19fbcf4d
fix: adjust authoritative setup path caching logic
...
Signed-off-by: Salvatore Martire <4652631+salmart-dev@users.noreply.github.com>
2025-12-22 15:52:52 +01:00
Joas Schilling
226b7df65e
fix(Hooks): Don't use offset null as it's deprecated (and not actually used)
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-12-19 15:58:05 +01:00
Benjamin Gaussorgues
89fcefbfa0
Merge pull request #55369 from nextcloud/carl/cleanup-external-manager
2025-12-17 14:14:48 +01:00
Carl Schwan
6945a030f5
refactor(OC_Helper): remove buildNotExistingFileNameForView
...
Move the functionality in the last place it is used OC\Files\Node\Folder
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-12-16 10:38:29 +01:00
provokateurin
341fd348e6
fix(UserMountCache): Add back unique index for oc_mounts and use normal insert
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2025-12-15 12:26:23 +01:00