Skip to content
Info disclosure Disclosed report Intermediate

Private AWS AMIs are temporarily being exposed publicly

Private AWS AMIs intended for internal use were temporarily exposed in the public AMI community catalog, allowing anyone to launch an EC2 instance from them. An attacker could inspect internal binaries and references to internal AWS environments, though no credentials were found.

seth_art_dd Follow

Originally disclosed on HackerOne

Informational View original
  • Fixed in 27 days
  • Disclosed after 51 days

The AMI community catalog is where people can publish Amazon Machine Images (AMIs) publicly. AMIs are used to create EC2 instances. While working with the AMI community catalog, using the aws ec2 describe-images command, I found multiple images that all have the same prefix that keep getting published to this public community catalog, but then shortly after discovery, they get removed from the catalog.

The Description for all images is: █████

In summary, I was able to manually create an EC2 instance in my own account using one of these AMIs during the short window it was public, and I believe that this AMI is supposed to be for internal AWS use only, and is never supposed to be public. I found multiple binaries on this AMI (chronicled & chroniclectl) that are not mentioned anywhere else on the internet and pull imports from ████████ (an internal golang package repo), and they contain references to internal AWS environments, like gamma/beta/dev.

I did not find anything really critical here - no private internal AWS credentials or anything like that. Also noteworthy is that these AMIs are being made public by hundreds of unique AWS account IDs.

My assumption is that there is a bug in some internal processes that is accidentally making these AMIs public during some type of job execution, but there is also some type of clean-up action that either makes the AMI private when the job is finished, or maybe the AMI is simply just deleted.

Steps To Reproduce:

(Add details for how we can reproduce the issue)

  1. Search for the AMI either for one region like this: aws --profile ███ ec2 describe-images --filters "Name=name,Values=ib-lifecycle-basic-ami*" --region us-west-2, or in a loop like this: for region in aws ec2 describe-regions --query "Regions[].RegionName" --output text; do; echo "$region"; aws ec2 describe-images --filters "Name=name,Values=ib-lifecycle-basic-ami*" --region $region; done or in the console
  2. Create an EC2 with the AMI ID
  3. Connect to the EC2
  4. Find AWS private binaries ████████
  5. Find references to internal resources such as █████, public pgp key from the ███ <█████████> team, etc.

Impact

An attacker can access an AMI that is intended to be used internally at AWS. The attacker can learn about the existence of AWS systems, private AWS binaries and their endpoints. An attacker could attempt to reverse engineer the binaries to see if they expose any additional information or lead to other vulnerabilities in the endpoints the binaries interact with.

Additionally, an attacker can monitor these AMIs and create a list of unique AWS accounts that appear to be for internal AWS use (as opposed to customer accounts)

The original report as published on HackerOne, by seth_art_dd. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely a bug in an internal AWS process that accidentally publishes these AMIs publicly during a job, with a clean-up step that later makes them private or deletes them.

Impact

An attacker could access an internal AWS AMI, learn about internal systems and binaries, and potentially reverse engineer them, but no private credentials were found.

What the attacker needed

AWS account to launch EC2; AMI must be public during the window

How it was found

  1. Search for AMIs with a specific name prefix in one region or across all regions using the AWS CLI or console.
  2. Create an EC2 instance from one of the found AMI IDs.
  3. Connect to the EC2 instance.
  4. Locate private AWS binaries on the instance.
  5. Find references to internal resources such as internal environments and a public PGP key from an internal team.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

An Amazon Machine Image (AMI) is a template used to start a virtual server (EC2 instance) in AWS. Some AMIs meant only for AWS staff were briefly listed in the public catalog, so outsiders could start servers from them and look inside. The researcher found internal tools but no passwords or keys.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More from AWS VDP

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.