Skip to content
Access control Write-up Intermediate

How I dumped PII information of customers in an ecommerce site?

An endpoint that generated signed URLs for images accepted arbitrary image IDs, allowing access to any image in the bucket. By guessing a folder name, the attacker obtained signed URLs for a folder containing ID card images with sensitive personal information.

Rikesh Baniya Follow

Published on rikeshbaniyaaa.medium.com

Like every website, the most interesting endpoint is always the image upload section. So I fired my burp and was checking how the images are getting stored.

Rikesh Baniya, on rikeshbaniyaaa.medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

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

How it worked

Root cause

Likely the signature-generating endpoint did not verify that the requested image ID belonged to the requesting user, allowing access to any object in the bucket.

What the attacker needed

Access to the signature-generating endpoint; knowledge of or ability to guess image IDs or folder names

How it was found

  1. Observe that images are stored in an S3 bucket and accessed via signed URLs.
  2. Find an endpoint that generates signed URLs based on a user-supplied image ID.
  3. Supply a simple value like '1' and receive a signed URL for that object.
  4. Try a null value to access the bucket root, which returns an error.
  5. Bruteforce folder names and find 'consumers'.
  6. Visit the signed URL for the 'consumers' folder to access ID card images.

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 write-up has not been written yet. The Original tab links to the source.

Websites often store uploaded images in cloud storage and give users temporary links to view them. The site had a feature that created these links for any image ID you provided, without checking if you were allowed to see that image. The attacker guessed a folder name and got links to private ID card photos.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More by Rikesh Baniya

View all

4 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.