From 55585ef24cfaad5a3d256f1ff6dbdf4a8bb30c6b Mon Sep 17 00:00:00 2001 From: Liam Beckman Date: Mon, 8 Jun 2026 18:47:50 -0700 Subject: [PATCH 1/2] fix: Remove context passed to MinIO's `NewSSEKMS` Signed-off-by: Liam Beckman --- storage/generic_s3.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/storage/generic_s3.go b/storage/generic_s3.go index 3875d3e68..b27082a83 100644 --- a/storage/generic_s3.go +++ b/storage/generic_s3.go @@ -198,7 +198,7 @@ func download(ctx context.Context, client *minio.Client, bucket, objectPath, fil opts := minio.GetObjectOptions{} if kmskeyId != "" { logger.Debug("genericS3: using KMS encryption", "kmsKeyId", kmskeyId) - SSEKMS, err := encrypt.NewSSEKMS(kmskeyId, ctx) + SSEKMS, err := encrypt.NewSSEKMS(kmskeyId, nil) if err != nil { return fmt.Errorf("genericS3: download(): creating SSEKMS: %v", err) } @@ -264,7 +264,7 @@ func (s3 *GenericS3) Put(ctx context.Context, url, path string) (*Object, error) opts := minio.PutObjectOptions{} if s3.kmskeyId != "" { logger.Debug("genericS3: using KMS encryption for upload", "kmsKeyId", s3.kmskeyId) - SSEKMS, err := encrypt.NewSSEKMS(s3.kmskeyId, ctx) + SSEKMS, err := encrypt.NewSSEKMS(s3.kmskeyId, nil) if err != nil { return nil, fmt.Errorf("genericS3: Put(): creating SSEKMS: %v", err) } From e9b28ebda1d9c545396304172badc9927c86f7dc Mon Sep 17 00:00:00 2001 From: Liam Beckman Date: Wed, 10 Jun 2026 12:59:23 -0700 Subject: [PATCH 2/2] Update generic_s3.go --- storage/generic_s3.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/storage/generic_s3.go b/storage/generic_s3.go index b27082a83..79397227e 100644 --- a/storage/generic_s3.go +++ b/storage/generic_s3.go @@ -198,6 +198,8 @@ func download(ctx context.Context, client *minio.Client, bucket, objectPath, fil opts := minio.GetObjectOptions{} if kmskeyId != "" { logger.Debug("genericS3: using KMS encryption", "kmsKeyId", kmskeyId) + // Updated to avoid passing in erroneous context + // https://github.com/minio/minio-go/issues/2235 SSEKMS, err := encrypt.NewSSEKMS(kmskeyId, nil) if err != nil { return fmt.Errorf("genericS3: download(): creating SSEKMS: %v", err)