Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

S3 Control operation (createMultiRegionAccessPoint) fails with missing x-amz-content-sha256 header #1187

Closed
0marperez opened this issue Jan 22, 2024 · 1 comment · Fixed by #1188
Labels
bug This issue is a bug. needs-triage This issue or PR still needs to be triaged.

Comments

@0marperez
Copy link
Contributor

Describe the bug

When trying to create a multi-region-access-point using s3 control the operation fails with an exception.

Expected behavior

The operation should succeed without any exceptions

Current behavior

The operation fails with the exception:

Exception in thread "main" aws.sdk.kotlin.services.s3control.model.S3ControlException: Missing required header for this request: x-amz-content-sha256

Steps to Reproduce

Try to create a multi-region-access-point using s3 control with the AWS SDK for Kotlin.
The code snippet used:

fun main(): Unit = runBlocking {
    val s3Control = S3ControlClient {
        region = "us-west-2"
        logMode = LogMode.LogRequestWithBody + LogMode.LogResponse
    }

    s3Control.createMultiRegionAccessPoint(
        CreateMultiRegionAccessPointRequest{
            accountId = "..."
            details {
                name = "mrap-test"
                regions = listOf(
                    Region {
                        bucket = "..."
                        bucketAccountId = "..."
                    },
                    Region {
                        bucket = "..."
                        bucketAccountId = "..."
                    }
                )
            }
        }
    )
}

Possible Solution

Add the missing header

Context

No response

AWS Kotlin SDK version used

1.0.37

Platform (JVM/JS/Native)

JVM

Operating System and version

Mac OS Ventura 13.6.3

@0marperez 0marperez added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Jan 22, 2024
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. needs-triage This issue or PR still needs to be triaged.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant