Skip to content
Access control Write-up Beginner

Admin Emails Passwords Exposed Via Http Method Change

An API endpoint used for replying to emails returned a full dump of user data, including email addresses and password hashes, when the HTTP method was changed from POST to GET. An attacker could read sensitive credentials for all registered users, including administrators, without authentication.

Mahmoud El Manzalawy Follow

Published on infosecwriteups.com

Hello folks, I’m Mahmoud El manzalawy, a bug bounty hunter who enjoys finding vulnerabilities in his free time.

Mahmoud El Manzalawy, on infosecwriteups.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 backend mapped the same endpoint to both a create action and a read action without any authorisation check on the read path.

Impact

An unauthenticated attacker could obtain email addresses and password hashes for all registered users, including administrators, enabling account takeover through cracking or reuse.

What the attacker needed

No authentication needed

The fix

The endpoint should enforce authorisation and separate read and write actions so that a GET request cannot return user records.

How it was found

  1. Open the email section and use the reply feature.
  2. Notice a suspicious request containing an API path.
  3. Send the request to Repeater and replay it, getting a 201 Created response.
  4. Change the HTTP method from POST to GET and send it again.
  5. Observe the response containing a full dump of user data.

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.

Web servers use different HTTP methods to say what you want to do: POST usually creates something and GET usually reads something. Here the same address behaved differently depending on the method, and asking to read it handed back the whole user list with passwords. That means the server never checked who was asking before giving out private data.

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 Mahmoud El Manzalawy

View all

1 more disclosed report, 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.