Skip to content

Commit

Permalink
Update PutBucketLifecycleConfiguration test
Browse files Browse the repository at this point in the history
It now checks the Crc32 checksum header instead of Md5

Update test for Authorization header
  • Loading branch information
landonxjames committed Sep 25, 2024
1 parent 6182401 commit bf37449
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions aws/sdk/aws-models-extra/s3-tests.smithy
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,7 @@ apply PutBucketLifecycleConfiguration @httpRequestTests([
protocol: "aws.protocols#restXml",
uri: "/",
headers: {
// we can assert this, but when this test is promoted, it can't assert
// on the exact contents
"content-md5": "JP8DTuCSH6yDC8wNGg4+mA==",
"x-amz-checksum-crc32": "11+f3g==",
},
bodyMediaType: "application/xml",
body: """
Expand Down
2 changes: 1 addition & 1 deletion aws/sdk/integration-tests/s3/tests/endpoints.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ async fn multi_region_access_points() {
let auth_header = captured_request.headers().get("AUTHORIZATION").unwrap();
// Verifies that the sigv4a signing algorithm was used, that the signing scope doesn't include a region, and that the x-amz-region-set header was signed.
let expected_start =
"AWS4-ECDSA-P256-SHA256 Credential=ANOTREAL/20090213/s3/aws4_request, SignedHeaders=host;x-amz-content-sha256;x-amz-date;x-amz-region-set;x-amz-user-agent, Signature=";
"AWS4-ECDSA-P256-SHA256 Credential=ANOTREAL/20090213/s3/aws4_request, SignedHeaders=host;x-amz-checksum-mode;x-amz-content-sha256;x-amz-date;x-amz-region-set;x-amz-user-agent, Signature=";

assert!(
auth_header.starts_with(expected_start),
Expand Down

0 comments on commit bf37449

Please sign in to comment.