Issue-Close Spoofing Persists via Activity-Feed Flooding after Patch
The patch for ProcessCommitWorker still records the commit author as the issue closer, even though it checks the pusher's permission. An attacker can forge commits with the victim's name and email to close issues in a project where the victim has close rights, making it appear the victim closed them and flooding their activity feed.
GitLab
Originally disclosed on GitLab
- Fixed in 3 months
- Disclosed after 3 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 #3140313 by pwnie on 2025-05-12, assigned to @greg:
Report | How To Reproduce
Report
Summary
The recent patch to ProcessCommitWorker verifies that the current user (the authenticated pusher) is allowed to close an issue. However, it still writes the commit author into issue.closed_by. Because Git author data can be forged, an attacker can:
- Grant the victim the necessary permission by adding them to the attacker-controlled project (e.g., Developer role).
- Forge commits that reference “Close # x” while spoofing the victim’s name + email in the author field.
The permission check passes—because the victim does have close rights in that project—so the issue really closes, but the event is logged as if the victim performed the action. The attacker can repeat this indefinitely, creating hundreds or thousands of “Closed issue” entries under the victim’s public profile and contribution graph.
Steps to Reproduce
-
Set-up
Attacker creates a public project A.
Attacker invites Victim as Developer (or higher), conferring issue-close rights. -
Seed Issues
Attacker opens many trivial issues in project A (#1 … #N). -
Forge & Push Commits
Bash git clone ATTACKER_REPO_URL cd ATTACKER_REPO for i in $(seq 1 N); do echo $i > junk$i git add junk$i GIT_AUTHOR_NAME="Victim" \ GIT_AUTHOR_EMAIL="[email protected]" \ git commit -m "Close #$i" done git push origin main -
Observe
- All issues
#1 … #Nclose successfully. - Victim’s profile activity feed shows N “closed issue” events, attributed to Victim, even though Victim never interacted.
- All issues
Impact
| Aspect | Result |
|---|---|
| Integrity | Falsifies historical record of who performed project actions. |
| Reputation | Makes Victim appear responsible for mass-closing spammy issues, damaging trust. |
| Denial of Visibility | Floods Victim’s activity graph, burying genuine contributions. |
| Scalability | Limited only by attacker’s willingness to create issues; cost is negligible. |
Because the closure is legitimate from GitLab’s perspective, victims cannot delete these entries without removing themselves from the project—something they may overlook, and which attackers can re-initiate at any time.
Root Cause
ProcessCommitWorker:
- Confirms current_user (the pusher) has
can?(:update_issue, issue). - Executes
issue.closeand setsclosed_by = commit.author.
Provided the targeted victim has project membership with the requisite permission, step 1 passes. Step 2 then records the spoofed author.
Suggested Remediation
- Attribute to the pusher, not the commit author, when auto-closing.
- If author and pusher differ, mark the event system-generated (“Closed by commit pushed by current_user”).
- Optionally, notify the impersonated user on first occurrence so they can leave the project or report abuse.
- Rate-limit auto-close events per user per project to curb flooding.
Severity
High (Integrity + Reputation Abuse)
The vulnerability enables large-scale, permanent manipulation of public user-history without any compromise of their credentials.
Impact
Because the closure is legitimate from GitLab’s perspective, victims cannot delete these entries without removing themselves from the project—something they may overlook, and which attackers can re-initiate at any time.
How To Reproduce
Please add reproducibility information to this section:
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 code checks the pusher's permission but then sets the issue's closed_by field to the commit author, which can be forged.
Impact
The attacker can falsify the historical record of who closed issues, damage the victim's reputation, and flood their activity graph, with the scale limited only by the attacker's willingness to create issues.
What the attacker needed
Attacker can create a project; victim must be a member with close rights; attacker can push commits
The fix
The auto-close should attribute the action to the pusher, not the commit author, and optionally mark it as system-generated and rate-limit such events.
How it was found
- Attacker creates a public project and invites the victim as Developer.
- Attacker opens many trivial issues in the project.
- Attacker forges commits with the victim's name and email, each with a message like 'Close #i', and pushes them.
- All issues close and the victim's activity feed shows many 'closed issue' events attributed to the victim.
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 push code to GitLab, you can write any name and email as the commit author. GitLab checks if the pusher has permission, but then records the commit author as the one who closed the issue. So an attacker can make it look like someone else closed lots of issues.
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.