Skip to content
Business logic Disclosed report Beginner

GitLab's Service Desk allows spoofing issue creator via reply-to email header

GitLab's Service Desk feature trusts the Reply-To header over the From header when creating issues from emails, allowing an attacker to spoof the issue creator as any email address, including maintainers. This could let an attacker create tickets that appear to come from trusted users.

GitLab

Originally disclosed on GitLab

  • Fixed in 3 months
  • Disclosed after 3 months

HackerOne report #1433607 by rijalrojan on 2021-12-22:

Report | Attachments | How To Reproduce

Report

Summary

Service Desk is a feature that is enabled by default in Gitlab cloud and is optional in on-premise instances. When enabled, this allows users to report issues to maintainers by sending an email. The receiver email format is as follows: contact-project+USERNAME-PROJECTNAME-PROJECTID-issue-[@]incoming.gitlab.com. This takes in the email and creates a ticket on it's behalf. Created tickets are accessible by maintainers only.

Screen_Shot_2021-12-21_at_7.12.53_PM.png
Screen_Shot_2021-12-21_at_7.12.53_PM.png From the original on GitLab

The system that ingests the email and creates a ticket, respects Reply-To header more than the actual From header when it receives the email. For example, in Gmail/Gsuite you can setup your own reply-to

Screen_Shot_2021-12-21_at_7.14.34_PM.png
Screen_Shot_2021-12-21_at_7.14.34_PM.png From the original on GitLab

Now when I send email to my test instance, this is what it looks like:

Screen_Shot_2021-12-21_at_7.15.44_PM.png
Screen_Shot_2021-12-21_at_7.15.44_PM.png From the original on GitLab

You can use this to create tickets in behalf of maintainers and others. Service desk by default allows creating ticket for private repository as well so this is not defaulted to only public repos

Steps to reproduce
  1. Change your Reply-To in Gmail/GSuite to reflect your victim's email.
  2. Send an email to a service desk email and notice your Reply-To is used as the sender.
Impact

The easiest and direct impact to this is being able to spoof and create tickets as maintainers.

Impact

The easiest and direct impact to this is being able to spoof and create tickets as maintainers. I am investigating further in my own instance but it will take time to setup.

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 email ingestion system uses the Reply-To header to determine the issue creator instead of the From header.

Impact

An attacker could spoof and create tickets as maintainers, potentially misleading maintainers or impersonating trusted users.

What the attacker needed

Service Desk enabled; Ability to send email to service desk address; Control over Reply-To header

How it was found

  1. Change your Reply-To in Gmail/GSuite to reflect your victim's email.
  2. Send an email to a service desk email and notice your Reply-To is used as the sender.

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 send an email, it has a 'From' address (who it's from) and a 'Reply-To' address (where replies should go). GitLab's Service Desk feature reads the 'Reply-To' address to decide who created the issue, so an attacker can set that to someone else's email and make the issue look like it was created by that person.

What is Business logic?

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.

More from GitLab

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.