Skip to content
Access control Disclosed report Beginner

comment from one issue can be included in a different issue

A comment from one issue could be displayed in a different issue by manipulating the URL fragment. An attacker could mislead a user into approving content they did not intend to approve.

GitLab

Originally disclosed on GitLab

  • Fixed in 5 months
  • Disclosed after 5 months

⚠️ 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 #3110165 by maselage on 2025-04-24, assigned to @katwu:

Report | Attachments | How To Reproduce

Report

NOTE! Thanks for submitting a report! Please note that initial triage is handled by HackerOne staff. They are identified with a HackerOne triage badge and will escalate to the GitLab team any. Please replace all the (parenthesized) sections below with the pertinent details. Remember, the more detail you provide, the easier it is for us to triage and respond quickly, so be sure to take your time filling out the report!

Summary

It is possible to display a comment from one issue in a completely different issue. Thus it is possible to ask for approval on one issue while in reality a completely different issue will be approved.

Steps to reproduce

(Step-by-step guide to reproduce the issue, including:)

  1. Start a fresh GitLab (I usedDocker) in Version 17.11.0 or 17.11.1. (I was not able to reproduce it in Version 17.10.4). I first noticed this behaviour in a productive system, but no special GitLab configuration is needed, simply "docker run" GitLab on localhost will do it.
  2. create a group/project, path will be http://loclahost/group/project
  3. create Issue 1, path will be http://loclahost/group/project/-/issues/1
  4. create Issue 2, path will be http://loclahost/group/project/-/issues/2
  5. comment on Issue 2, path will be http://loclahost/group/project/-/issues/2#note1
  6. now manipulate the URL to http://loclahost/group/project/-/issues/1#note1
  7. if you give this URL to a unknowing user, he will see the Text of Issue 1 with the comment from Issue 2. The unknowing user might act on this false information and leave a comment.
  8. when you check http://loclahost/group/project/-/issues/1 afterward you won't see any comment.
  9. when you check http://loclahost/group/project/-/issues/2 afterward you will see the original comment and the new comment from the unknowing user.
Impact

The unknowing user might act, e.g. approve something written in Issue 2 while actually replying to Issue 1. So in fact unknowing user will approve Issue 1 without knowing it.

Examples

(If the bug is project related, please create an example project and export it using the project export feature)

(If you are using an older version of GitLab, this will also help determine whether the bug has been fixed in a more recent version)

(If the bug can be reproduced on GitLab.com without violating the Rules of Engagement as outlined in the program policy, please provide the full path to the project.)

What is the current bug behavior?

A comment from one issue might be displayed in another issue.

What is the expected correct behavior?

Never show a comment from one issue inside another issue.

Relevant logs and/or screenshots

Screenshots with different pathes and two users (AUser and BadUser) demonstrating how to exploit bug (ignore the administrator, trying to spoil the fun. The unknowing CEO should have approved at that place).

The original good Issue:
[REDACTED]

The bad Issue (trying to lure the CEO to approve):
[REDACTED]

The good Issue with the fake comment (this is what the ceo would see/approve):
[REDACTED]

Output of checks

(If you are reporting a bug on GitLab.com, write: This bug happens on GitLab.com)

Results of GitLab environment info

root@localhost:/# gitlab-rake gitlab:env:info

System information
System:
Current User: git
Using RVM: no
Ruby Version: 3.2.5
Gem Version: 3.6.6
Bundler Version:2.6.5
Rake Version: 13.0.6
Redis Version: 7.2.7
Sidekiq Version:7.3.9
Go Version: unknown

GitLab information
Version: 17.11.1
Revision: 78fb986046b
Directory: /opt/gitlab/embedded/service/gitlab-rails
DB Adapter: PostgreSQL
DB Version: 16.8
URL: http://localhost
HTTP Clone URL: http://localhost/some-group/some-project.git
SSH Clone URL: git@localhost:some-group/some-project.git
Using LDAP: no
Using Omniauth: yes
Omniauth Providers:

GitLab Shell
Version: 14.41.0
Repository storages:

  • default: unix:/var/opt/gitlab/gitaly/gitaly.socket

GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell

Gitaly

  • default Address: unix:/var/opt/gitlab/gitaly/gitaly.socket
  • default Version: 17.11.1
  • default Git Version: 2.49.0.gl1

Impact

With a manipulated link you could mislead an unsuspecting user into approving something he has not even read.

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 application uses the URL fragment to load a comment without verifying it belongs to the current issue.

Impact

An attacker could mislead a user into approving an issue they did not intend to approve.

What the attacker needed

GitLab version 17.11.0 or 17.11.1; attacker can create issues and comments; victim clicks a crafted link

How it was found

  1. Start a fresh GitLab instance (version 17.11.0 or 17.11.1).
  2. Create a group and project.
  3. Create two issues, Issue 1 and Issue 2.
  4. Add a comment to Issue 2.
  5. Change the URL to point to Issue 1 but keep the comment fragment.
  6. Share the manipulated URL with a user; they see Issue 1 with the comment from Issue 2.

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 comment on one issue could appear on another issue's page if the link is changed. This could trick someone into approving something they did not mean to approve.

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.