Skip to content
Access control Disclosed report Beginner

Improve UI and documentation around public builds on private projects

A guest user on a private project could still view CI/CD pipelines and jobs through a direct pipelines URL even though the interface hid the CI/CD menu. The reporter argued this contradicted the permissions documentation, which said guests should not see pipelines.

GitLab

Originally disclosed on GitLab

  • Fixed in 23 months
  • Disclosed after 23 months

Problem

It was reported as a vulnerability that guests can see CI/CD jobs for private projects. https://docs.gitlab.com/ee/ci/pipelines/settings.html#change-which-users-can-view-your-pipelines

<p> <details> <summary>Original Issue description</summary>

⚠️ Please read the process on how to fix security issues before starting to work on the issue. Vulnerabilities must be fixed in a security mirror.

HackerOne report #1894723 by randrly on 2023-03-07, assigned to @ottilia_westerlund:

Report | Attachments | How To Reproduce

Report

Hi There

Summary

In permissions documentation https://docs.gitlab.com/ee/user/permissions.html, guest user should can't see the pipeline and jobs

2023-03-07_13-47.png
2023-03-07_13-47.png From the original on GitLab
2023-03-07_13-46.png
2023-03-07_13-46.png

But when i try to use guest account the CI/CD menu stil there and the pipeline jobs still can be seen via

Steps to reproduce

1 . Login to gitlab.com as owners
2 . Create a project
3 . Setup CI/CD

2023-03-07_14-02.png
2023-03-07_14-02.png From the original on GitLab
2023-03-07_14-02_1.png
2023-03-07_14-02_1.png
2023-03-07_14-02_3.png
2023-03-07_14-02_3.png
2023-03-07_14-02_2.png
2023-03-07_14-02_2.png
  1. Setup Public Pipelines to disabled in Project Setting -> Save

4 . Invite a guest user
5 . Login as guest and you still can't see the CI/CD in the menu
6 . Craft URL like this https://gitlab.com/randrialdyt1/testproject/-/pipelines.json?scope=all&page=1

2023-03-07_14-12.png
2023-03-07_14-12.png From the original on GitLab
2023-03-07_14-12_1.png
2023-03-07_14-12_1.png
Impact

Guest User Still Can See CI/CD Jobs

PoC Video
simplescreenrecorder-2023-03-07_14.08.32.mp4 From the original on GitLab

Impact

Guest User Still Can See CI/CD Jobs

Attachments

Warning: Attachments received through HackerOne, please exercise caution!

How To Reproduce

Please add reproducibility information to this section:

</details> </p>

In reality there is a feature called public builds which is on by default and allows guest users to view builds. When this setting is off then guest users can no longer see the builds.

There are a few issues with UX/UI and documentation here:

  1. It doesn't agree well with the permissions documents which state guest user access is allowed 'If the project is public and Public pipelines is enabled in Project Settings > CI/CD.' Perhaps we should link to the CI documentation here for a single source of truth.
  2. We don't document what the defaults are in the ci documentation
  3. The default seems counter intuitive - Do users expect guests to be able to see there builds on private projects?
  4. The UI disagrees that this information should be visible and doesn't have a link to the pipeline page

Proposal

My recommendation would be:

  1. Fix the UI to show the pipeline tab if public builds is enabled for guest users on a private project
  2. Document the defaults for public builds on project creation
  3. Link to the CI documentation as a single source of truth for the public builds feature instead of re-explaining it on the permissions page.

Also consider:

  1. Keep the public builds off by default if the project is private and document that? It seems like something users would want to explicitly allow because of the principle of least privilege. Perhaps we can open a follow-up after discussing further.

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 'public builds' setting was enabled by default and the pipelines endpoint did not check it for guest users, while the interface hid the menu entry regardless.

What the attacker needed

A private project with CI/CD configured; a guest account on that project

The fix

The maintainers proposed showing the pipeline tab when public builds is enabled, documenting the defaults, and linking to the CI documentation as the single source of truth.

How it was found

  1. Log in as the project owner and create a project.
  2. Set up CI/CD for the project.
  3. Disable public pipelines in the project settings and save.
  4. Invite a guest user to the project.
  5. Log in as the guest and request the project's pipelines JSON endpoint directly.

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 guest is a low-privilege project member. The project had public builds enabled by default, so guests could reach pipelines by typing the address directly, even though the menu hid CI/CD.

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 from GitLab

View all

The newest disclosed reports for this program.

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.