Skip to content
Info disclosure Disclosed report Beginner

Email address leaked in `getPipelineHeaderData` graphql

The GraphQL query getPipelineHeaderData returned the email address of the user who triggered a pipeline, even when that user had set their email to private. An attacker could view the email addresses of all users who triggered pipelines in public projects.

GitLab

Originally disclosed on GitLab

  • Fixed in 23 hours
  • Disclosed after 23 hours

HackerOne report #1021174 by ashish_r_padelkar on 2020-10-28, assigned to @rchan-gitlab:

Report | Attachments | How To Reproduce

Report

Summary

Hello,

Email address of users are leaked even if they have set below settings in their profiles at https://gitlab.com/-/profile if they triggered the pipelines in public projects.

Screenshot_2020-10-29_at_01.13.07.png
Screenshot_2020-10-29_at_01.13.07.png From the original on GitLab

This happens in graphql request for getPipelineHeaderData when trying to see pipeline details and the email of user who triggered the pipeline is visible in response.

As pipelines are publicly visible to all in public projects, emails of all the users who triggered the pipelines in such projects are visible publicly.

Steps to reproduce
  1. Go to any public project and go to any pipeline details page.
  2. Following request is sent in background.
POST /api/graphql HTTP/1.1  
Host: gitlab.com  
Connection: close  
Content-Length: 748  
accept: */*  
X-CSRF-Token: 1  
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.111 Safari/537.36  
content-type: application/json  
Origin: https://gitlab.com  
Sec-Fetch-Site: same-origin  
Sec-Fetch-Mode: cors  
Sec-Fetch-Dest: empty  
Referer: https://gitlab.com/groupnew321/project2/-/pipelines/206490527  
Accept-Encoding: gzip, deflate  
Accept-Language: en-GB,en;q=0.9  
Cookie: 1

[{"operationName":"getPipelineHeaderData","variables":{"fullPath":"groupnew321/project2","iid":"17"},"query":"query getPipelineHeaderData($fullPath: ID!, $iid: ID!) {\n  project(fullPath: $fullPath) {\n    pipeline(iid: $iid) {\n      id\n      status\n      retryable\n      cancelable\n      userPermissions {\n        destroyPipeline\n        __typename\n      }\n      detailedStatus {\n        detailsPath\n        icon\n        group\n        text\n        __typename\n      }\n      createdAt\n      user {\n        name\n        webPath\n        email\n        avatarUrl\n        status {\n          message\n          emoji\n          __typename\n        }\n        __typename\n      }\n      __typename\n    }\n    __typename\n  }\n}\n"}]  
  1. The response contains user object which discloses the email address of the user even when public viewing is not allowed!
What is the current bug behavior?

Emails are visible of all users in public projects whoever triggered the pipeline .

What is the expected correct behavior?

Email address shouldnt be visible publicly when users are not allowing it.

Output of checks

This bug happens on GitLab.com

Regards,
Ashish

Impact

Emails of users are visible publicly in pipeline detail graphql endpoint whoever triggered the pipelines.

Attachments

Warning: Attachments received through HackerOne, please exercise caution!

How To Reproduce

Please add reproducibility information to this section:

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

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 GraphQL resolver for the pipeline's user field did not check the user's email privacy setting before returning the email.

Impact

Email addresses of users who triggered pipelines in public projects are publicly visible, even if those users set their email to private.

What the attacker needed

Public project with pipelines; no authentication needed

How it was found

  1. Go to any public project and open a pipeline details page.
  2. Observe the background GraphQL request to /api/graphql with operation getPipelineHeaderData.
  3. The response includes the user object with the email field.

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.

When you look at a pipeline (an automated build process) in a public project, the system shows who started it. Normally, if you've set your email to private, it shouldn't be shown. But here, the system included the email in the data it sent back, so anyone could see it.

What is Info disclosure?

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

More from GitLab

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.