79088057

Date: 2024-10-15 00:34:30
Score: 0.5
Natty:
Report link

Nobody included the required token for the curl command to actually work. I dug it up in the docs: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instancedata-data-retrieval.html

What you actually need to run is the following:

TOKEN="$(curl -X PUT "http://169.254.169.254/latest/api/token" -H "X-aws-ec2-metadata-token-ttl-seconds: 21600")"

Then:

curl -H "X-aws-ec2-metadata-token: $TOKEN" http://169.254.169.254/latest/dynamic/instance-identity/document

Reasons:
  • Probably link only (1):
  • Has code block (-0.5):
Posted by: Wildcard