Skip to content
Access control Disclosed report Beginner

ESCALATED: Projects are allowed to add members with different domain email address despite restricting in group settings

A group setting that restricts membership to email addresses from particular domains was enforced at the group level but not on projects underneath it. A maintainer could therefore add a member with an email from a disallowed domain directly at the project level.

GitLab

Originally disclosed on GitLab

  • Fixed in 23 months
  • Disclosed after 23 months

HackerOne report #679567 by ashish_r_padelkar on 2019-08-22, assigned to gitlab_cmaxim:

Summary

Hello,

In new feature https://gitlab.com/help/user/group/index#allowed-domain-restriction-premium-only , it is mentioned that You can restrict access to groups and their underlying projects by allowing only users with email addresses in particular domains to be added to the group

However, this restriction only works at group level and not projects underneath it.

Steps to reproduce

  1. Go to group settings at /-/edit#js-permissions-settings and put gitlab.com under Restrict membership by email.

  2. Now try to add members at group membership with different email and it wont allow you to do.

  3. Now as a maintainer ,go to projects underneath it and add the email with different domain and it will successfully adds the member.

What is the current bug behavior?

Allows adding email of different domains at project level despite setting it to group level

What is the expected correct behavior?

The settings should be applied at all levels as per documentation.

Output of checks

This bug happens on GitLab.com and probably on omnibus installations too

Regards,
Ashish

Impact

Allows adding members with different domain email addresses at project level despite group level settings.

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 project-level membership code did not consult the parent group's allowed-domain restriction, so the check only ran at group level.

Impact

A maintainer could add users with disallowed email domains to projects, bypassing the group's membership restriction.

What the attacker needed

A group with domain restriction set; maintainer role on a project in that group

How it was found

  1. Set the group's membership restriction to a specific email domain in the group settings.
  2. Try to add a member with a different domain at group level and observe it is refused.
  3. As a maintainer, add a member with a different domain at the project level and observe it succeeds.

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 group can be configured so only people with email addresses from certain domains may join. The report shows that this rule was checked when adding someone to the group itself, but not when adding someone to a project inside that group, so the restriction could be sidestepped.

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.