From c0ed55cd3da8cb7dc4131a359ef5904d3e923ef7 Mon Sep 17 00:00:00 2001 From: Ben McClelland Date: Wed, 2 Sep 2026 14:08:20 -0700 Subject: [PATCH] fix: use dir permissions option for temporary directories The multipart upload temp directory was created with a hard-coded 0755 mode instead of the configured --dir-perms value, unlike every other directory creation path in this backend. This caused inconsistent permissions below bucket directories. Fixes #2266 --- backend/posix/posix.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/posix/posix.go b/backend/posix/posix.go index 834b4561..78abc847 100644 --- a/backend/posix/posix.go +++ b/backend/posix/posix.go @@ -1744,7 +1744,7 @@ func (p *Posix) CreateMultipartUpload(ctx context.Context, mpu s3response.Create tmppath := filepath.Join(bucket, objdir) // the unique upload id is a directory for all of the parts // associated with this specific multipart upload - err = os.MkdirAll(filepath.Join(tmppath, uploadID), 0755) + err = os.MkdirAll(filepath.Join(tmppath, uploadID), p.newDirPerm) if err != nil { return s3response.InitiateMultipartUploadResult{}, fmt.Errorf("create upload temp dir: %w", err) }