Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Use IMDSv2 to get instance metadata#102

Open
rajeshfintech wants to merge 1 commit into
aws-samples:master from
rajeshfintech:patch-1
Open

Use IMDSv2 to get instance metadata #102
rajeshfintech wants to merge 1 commit into
aws-samples:master from
rajeshfintech:patch-1

Conversation

@rajeshfintech

@rajeshfintech rajeshfintech commented Sep 17, 2022
edited
Loading

Copy link
Copy Markdown

Issue #95
Current version of script breaks when IMDSv2 is enforced on EC2 instances(
"InstanceMetadataOptions": {
"HttpTokens": "required",
} )

Description of changes:
To improve security, AWS recommend to use IMDSv2, the session-oriented communication to get instance metadata.https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/configuring-instance-metadata-service.html. This change is backward compatible with IMDSv1.
Also updated the request to get the region using placement/region this feature was released by AWS on 2020年08月24日 - https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instancedata-data-categories.html

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

To improve security, AWS recommend to use IMDSv2, the session-oriented communication to get instance metadata.https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/configuring-instance-metadata-service.html. 
This change is backward compatible with IMDSv1.
Also updated the request to get the region using `placement/region` this feature was released by AWS on 2020年08月24日 - https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instancedata-data-categories.html 
rajeshfintech added a commit to rajeshfintech/aws-codedeploy-samples that referenced this pull request Sep 17, 2022
Issue #, if available:
This is similar to other PR on elbv2 aws-samples#102 
Current version of script breaks when IMDSv2 is enforced on EC2 instances(
"InstanceMetadataOptions": {
"HttpTokens": "required",
} )
Description of changes:
To improve security, AWS recommend to use IMDSv2, the session-oriented communication to get instance metadata.https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/configuring-instance-metadata-service.html. This change is backward compatible with IMDSv1.
Also updated the request to get the region using placement/region this feature was released by AWS on 2020年08月24日 - https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instancedata-data-categories.html 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /