S3 bucket mapping fails when Object Lock requires checksum headers (PutObject returns 400) #319

Closed
opened 2026-04-05 16:16:11 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @smyoss on 12/29/2025

Description

Mapping a new S3 bucket fails during the direct test/mapping flow because the PutObject request is rejected by S3 when Object Lock parameters are involved. The API returns an HTTP 400 and the server logs indicate that S3 requires either a Content-MD5 header or an x-amz-checksum-* header for these requests. As a result, users are unable to validate or map a new bucket via S3 regardless of configuration attempts. This blocks onboarding/connecting new buckets where Object Lock is enabled or required.

Technical Details

  • Error message:
    • failed to upload test file to S3: Content-MD5 OR x-amz-checksum- HTTP header is required for Put Object requests with Object Lock parameters
  • API endpoint observed:
    • POST /api/v1/storages/direct-test
  • Server log:
    • [GIN] 2025/12/29 - 05:28:05 | 400 | 26.509089ms | 47.150.97.18 | POST "/api/v1/storages/direct-test"
  • Symptom:
    • “No matter what I try, I can't connect over S3 to map in a new bucket.”
  • Notes / suspected cause:
    • Our S3 client PutObject call likely sets Object Lock headers/parameters but does not include Content-MD5 or x-amz-checksum-*, which some S3 providers (and AWS S3 with Object Lock) require.

Version

v2.18.1

Image
*Originally created by @smyoss on 12/29/2025* ## Description Mapping a new S3 bucket fails during the direct test/mapping flow because the PutObject request is rejected by S3 when Object Lock parameters are involved. The API returns an HTTP 400 and the server logs indicate that S3 requires either a `Content-MD5` header or an `x-amz-checksum-*` header for these requests. As a result, users are unable to validate or map a new bucket via S3 regardless of configuration attempts. This blocks onboarding/connecting new buckets where Object Lock is enabled or required. ## Technical Details - Error message: - `failed to upload test file to S3: Content-MD5 OR x-amz-checksum- HTTP header is required for Put Object requests with Object Lock parameters` - API endpoint observed: - `POST /api/v1/storages/direct-test` - Server log: - `[GIN] 2025/12/29 - 05:28:05 | 400 | 26.509089ms | 47.150.97.18 | POST "/api/v1/storages/direct-test"` - Symptom: - “No matter what I try, I can't connect over S3 to map in a new bucket.” - Notes / suspected cause: - Our S3 client PutObject call likely sets Object Lock headers/parameters but does not include `Content-MD5` or `x-amz-checksum-*`, which some S3 providers (and AWS S3 with Object Lock) require. ## Version v2.18.1 <img width="717" height="308" alt="Image" src="https://github.com/user-attachments/assets/e8924045-ce4b-4da9-a160-df644350c041" />
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/databasus#319