summaryrefslogtreecommitdiffstats
path: root/lib/private/Files
diff options
context:
space:
mode:
authorArthur Schiwon <blizzz@arthur-schiwon.de>2023-08-02 20:55:24 +0200
committerGitHub <noreply@github.com>2023-08-02 20:55:24 +0200
commit0d96313256ac0fb5dfdba4156337023f5300e29c (patch)
tree1dd4d5a1dc9c810a98cb4b6ea2ee3768396692d5 /lib/private/Files
parent83d114b091b54ad6cf9df0274caa65a675670f15 (diff)
parente25db0e2947adf242cacda23d9b4b6813814023d (diff)
downloadnextcloud-server-0d96313256ac0fb5dfdba4156337023f5300e29c.tar.gz
nextcloud-server-0d96313256ac0fb5dfdba4156337023f5300e29c.zip
Merge pull request #39499 from nextcloud/backport/38934/stable27
[stable27] fix(s3): Pass SSE-C parameters for multipart upload
Diffstat (limited to 'lib/private/Files')
-rw-r--r--lib/private/Files/ObjectStore/S3.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/private/Files/ObjectStore/S3.php b/lib/private/Files/ObjectStore/S3.php
index 76eee2bc962..2d9119b5fc6 100644
--- a/lib/private/Files/ObjectStore/S3.php
+++ b/lib/private/Files/ObjectStore/S3.php
@@ -49,7 +49,7 @@ class S3 implements IObjectStore, IObjectStoreMultiPartUpload {
$upload = $this->getConnection()->createMultipartUpload([
'Bucket' => $this->bucket,
'Key' => $urn,
- ]);
+ ] + $this->getSSECParameters());
$uploadId = $upload->get('UploadId');
if ($uploadId === null) {
throw new Exception('No upload id returned');
@@ -65,7 +65,7 @@ class S3 implements IObjectStore, IObjectStoreMultiPartUpload {
'ContentLength' => $size,
'PartNumber' => $partId,
'UploadId' => $uploadId,
- ]);
+ ] + $this->getSSECParameters());
}
public function getMultipartUploads(string $urn, string $uploadId): array {
@@ -80,12 +80,12 @@ class S3 implements IObjectStore, IObjectStoreMultiPartUpload {
'UploadId' => $uploadId,
'MaxParts' => 1000,
'PartNumberMarker' => $partNumberMarker
- ]);
+ ] + $this->getSSECParameters());
$parts = array_merge($parts, $result->get('Parts') ?? []);
$isTruncated = $result->get('IsTruncated');
$partNumberMarker = $result->get('NextPartNumberMarker');
}
-
+
return $parts;
}
@@ -95,7 +95,7 @@ class S3 implements IObjectStore, IObjectStoreMultiPartUpload {
'Key' => $urn,
'UploadId' => $uploadId,
'MultipartUpload' => ['Parts' => $result],
- ]);
+ ] + $this->getSSECParameters());
$stat = $this->getConnection()->headObject([
'Bucket' => $this->bucket,
'Key' => $urn,