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

Support FIPS for S3 Accesspoint & Object Lambda #3964

Merged
merged 8 commits into from
Nov 17, 2021

Conversation

trivikr
Copy link
Member

@trivikr trivikr commented Nov 16, 2021

Fixes: #3959
Fixes: #3960

Testing

  • Unit testing.
  • Verified that hostname is generated for S3 Accesspoint.
Code
import AWS from "../aws-sdk-js/index.js";

// ARN for the accesspoint
const Bucket =
  "arn:aws:s3:us-west-2:123456789012:accesspoint/trivikr-accesspoint-testing";

const client = new AWS.S3({ region: "us-west-2", useFipsEndpoint: true });
const req = client.listObjects({ Bucket });
req.on('complete', function () {
  console.log({ hostname: req.httpRequest.endpoint.host });
});
req.send(function () {});
Output
{
  hostname: 'trivikr-accesspoint-testing-123456789012.s3-accesspoint-fips.us-west-2.amazonaws.com'
}
  • Verified that hostname is generated for S3 Object Lambda.
Code
import AWS from "../aws-sdk-js/index.js";

// ARN for the S3 Object Lambda
const Bucket =
  "arn:aws:s3-object-lambda:us-west-2:123456789012:accesspoint/trivikr-object-lambda-testing";

const client = new AWS.S3({ region: "us-west-2", useFipsEndpoint: true });
const req = client.listObjects({ Bucket });
req.on('complete', function () {
  console.log({ hostname: req.httpRequest.endpoint.host });
});
req.send(function () {});
Output
{
  hostname: 'trivikr-object-lambda-testing-123456789012.s3-object-lambda-fips.us-west-2.amazonaws.com'
}
Checklist
  • npm run test passes
  • changelog is added, npm run add-change

@trivikr trivikr requested a review from a team as a code owner November 16, 2021 20:26
@trivikr trivikr changed the title Support FIPS for S3 Accesspoint Support FIPS for S3 Accesspoint & Object Lambda Nov 16, 2021
Copy link
Contributor

@AllanZhengYP AllanZhengYP left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢 Thank you for putting up the fix!

@trivikr trivikr requested review from AllanZhengYP and a team November 17, 2021 17:23
@trivikr trivikr merged commit 1e6b66f into aws:master Nov 17, 2021
@trivikr trivikr deleted the fips-s3-accesspoint branch November 17, 2021 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

FIPS is not supported for S3 Object Lambda FIPS is not supported for S3 Accesspoint
2 participants