ESCALATED: Destroying designs in public issues without any permission
Any user, even without project membership, could comment on a design in a public issue using a GraphQL mutation with invalid position data, causing the design to become inaccessible. This allowed an attacker to effectively remove any design from any public issue, leading to a denial of service.
GitLab
Originally disclosed on GitLab
- Fixed in 4 months
- Disclosed after 4 months
HackerOne report #735282 by rpadovani on 2019-11-11, assigned to @cmaxim:
Developer note from @.luke: No data is destroyed and the user is permitted to perform this action. See https://gitlab.com/gitlab-org/gitlab/issues/36493#note_246244742.
Summary
Any user can remove any design from any public issue
Steps to reproduce
Alice attaches a design to a public issue over a public project
Bob doesn't have any membership to the project or to the parent's group.
Still, Bob can comment over the design.
Using GraphQL, Bob can comment with a syntactically valid comment, but with a broken content. The broken content will make the design completely inaccessible.
Given any public ID of a design attachment, attacker can submit this GraphQL query:
mutation {
createImageDiffNote(input:{
noteableId: "gid://gitlab/DesignManagement::Design/2329"
position: {
headSha: "0",
startSha: "0",
paths: {
oldPath: "x",
newPath: "x"
}
x: 0,
y: 0,
width: 0,
height: 0
},
body:"test"
}) {
errors
note {
id
}
}
}
The mutation will be successful, and the resource will disappear
Impact
DoS over design feature
Output of checks
This bug happens on GitLab.com
Impact
Destroying resources over which attacker hasn't any permission
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 GraphQL mutation for creating image diff notes did not properly validate the position data, allowing malformed input to corrupt the design's state.
Impact
An attacker could cause a denial of service on the design feature by making designs inaccessible, though no data is actually destroyed and the action is permitted according to a developer note.
What the attacker needed
Public project; public issue with a design; no project membership needed
How it was found
- Alice attaches a design to a public issue in a public project.
- Bob, who has no membership in the project or group, can still comment on the design.
- Bob sends a GraphQL mutation to create an image diff note with invalid position values (e.g., zero dimensions).
- The mutation succeeds, and the design becomes inaccessible.
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 design is an image attached to an issue in GitLab. The report shows that anyone, even without permission, could send a special request that made the design disappear for everyone. This is like being able to delete someone else's picture just by commenting on it in a broken way.
What is DoS?
A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.