Guest Users can create issues for Sentry errors and track their status
A Guest user in a private project could create an issue linked to a Sentry error and track its status, despite documentation stating only Reporter or higher roles should access Error Tracking. This allowed Guests to create references and observe when the error was resolved.
- Triaged in 32 days
- Fixed in 5 months
- Paid in 2 months
- Disclosed after 7 months
Summary
According to the permission docs and Error Tracking Docs , only User with role Reporter or more can see or modify the Error Tracking details. However, the "Create Issue" allows a particular Guest user to create a reference issue for the error and track its status whenever some other user resolves it.
Steps to reproduce
(Step-by-step guide to reproduce the issue, including:)
-
Consider a private project with
Guestrole user. -
Connect
Sentryto this project from theMaintaineraccount. -
And create new issues in Sentry. This automatically populates these errors in https://gitlab.com/project_name/-/error_tracking/.
-
Now, consider the request for creating an issue.
POST Data format for this is as follows:
issue[title]=Title issue[description]= Description issue[sentry_issue_attributes][sentry_issue_identifier]=Error_Id authenticity_token= your_auth_token -
Change
Error_Idparameter to some Error's reference id value (this is basically Sentry's Error id). -
Now, execute the request from
Guest's session. This creates an issue for that particular error. -
Now, go to the
Maintainer's login and resolve the error. This will close the issue that created by theGuest Userwith the message@Maintainer resolved the corresponding error and closed the issue.
Impact
Using this vulnerability, Guest Users can create issues for Sentry errors and track their Status.
Context
GitLab's Error Tracking feature lets a project connect to an external error monitoring service, in this case Sentry, and surface the errors it collects inside the project. Once Sentry is connected, the errors appear in the project's error tracking list at a path of the form https://gitlab.com/project_name/-/error_tracking/. From there a user can create a GitLab issue that references a particular error and follow that issue as the error's status changes.
The report is about who is allowed to do that. GitLab's permission documentation and the Error Tracking documentation both state that only a user with the Reporter role or above can see or modify Error Tracking details. The researcher found that the "Create Issue" action did not enforce that boundary: a Guest user could create a reference issue for an error and then track its status whenever another user resolved the error.
Setup
The preconditions are simple and all of them are described in the report:
- A private project with a user holding the
Guestrole. - Sentry connected to that project from a
Maintaineraccount. - New issues created in Sentry, which automatically populate the errors in the project's error tracking page.
No special tooling is mentioned. The work is done with a captured HTTP request replayed from the Guest session.
Finding it
The researcher compared the documented permission model with the behaviour of the Create Issue action. The documentation says Error Tracking details are for Reporter and above, yet the request that creates an issue from an error was accepted from a Guest session. That mismatch is the whole finding: the action is reachable by a role that the documentation says should not have access to the feature at all.
Exploitation
Step 1: Prepare the project and the error data
Take a private project that has a Guest user, connect Sentry to it from the Maintainer account, and create new issues in Sentry. Those errors are then populated automatically in the project's error tracking page at https://gitlab.com/project_name/-/error_tracking/.
Step 2: Capture the Create Issue request
The request that creates an issue from an error carries the following POST data:
issue[title]=Title
issue[description]= Description
issue[sentry_issue_attributes][sentry_issue_identifier]=Error_Id
authenticity_token= your_auth_token
The important field is issue[sentry_issue_attributes][sentry_issue_identifier], which carries the identifier of the Sentry error the new issue should reference. The authenticity_token is the usual CSRF token for the session.
Step 3: Point the request at a chosen error
Change the Error_Id value to the reference id of some error, which is Sentry's error id. This selects which error the issue will be linked to.
Step 4: Send it from the Guest session
Execute the request using the Guest user's session. Executing the request from the Guest session creates an issue for that particular error, even though the Guest role is not supposed to have access to Error Tracking details.
Step 5: Observe the status tracking
Log in as the Maintainer and resolve the error. Resolving the error closes the issue that the Guest user created, and the issue receives the message:
@Maintainer resolved the corresponding error and closed the issue
The issue receives that message when the Maintainer resolves the error.
Root cause
The Create Issue action for error tracking did not apply the same role check that governs viewing and modifying Error Tracking details. The documented rule is Reporter or above; the endpoint accepted a Guest. The report does not describe the server-side code, so the precise location of the missing check is not stated. What can be said is that the authorisation decision for this action was weaker than the one protecting the rest of the feature, which is why a role that cannot see the error tracking list could still act on an error through this request.
Impact
A Guest user on a private project can create issues for Sentry errors and track their status. Resolving the error closes the linked issue and posts the resolution message, so the issue's status follows the error. The report frames the impact exactly this way: creating issues for Sentry errors and tracking their status. It does not claim access to the error contents, the ability to modify errors, or any effect beyond issue creation and status tracking.
Fix
The report does not describe the fix that was applied.
Variants to test
- Replay other error tracking actions (for example any action that reads or changes an error's state) from a
Guestsession and see whether they are rejected. A positive result is any action that succeeds where the documentation requiresReporter. - Try the same Create Issue request from a user with no membership in the project at all. A positive result is an issue being created for an error in a private project.
- On other GitLab features that link an internal object to an external service, check whether the linking action enforces the same role as the feature's list and detail views. A positive result is a lower-privileged role performing the link.
- After a successful link, resolve the external object from a higher-privileged account and watch the linked internal object. A positive result is a status change and a system message appearing in the lower-privileged user's view.
Hunting notes
This kind of bug hides where a feature has a documented role requirement but several separate actions behind it, each with its own authorisation check. During recon, read the permission documentation for the product and compare it with what each request in the feature actually accepts, replaying captured requests from the lowest role available.
The signal here was a documented rule (Reporter or above for Error Tracking) that did not match observed behaviour. The researcher showed impact by following the object through its full lifecycle: the Guest created the issue, the Maintainer resolved the error, and the issue closed with the resolution message.
What happened, in plain words
GitLab is a website where teams keep their code and track work. One of its features, called Error Tracking, can be connected to an outside service called Sentry. Sentry watches a running program and records every time the program crashes or misbehaves; each of those recorded problems is called an error. When Sentry is connected to a GitLab project, those errors show up inside GitLab on a page whose address looks like https://gitlab.com/project_name/-/error_tracking/. From that page a team member can open a GitLab issue (a task or ticket) that points at one particular error, and then follow that issue as the error gets fixed.
GitLab gives each person in a project a role, which is simply a level of permission. A Guest is a low role, a Reporter is higher, and a Maintainer is higher still. GitLab's own documentation says that only a Reporter or someone above that level may see or change Error Tracking details. The researcher found that this rule was not applied everywhere: the button or request that creates an issue from an error also worked for a Guest. So a low-privileged user could create a linked issue for an error and then watch that issue to learn when the error was resolved.
This kind of mistake is called a broken access control problem: the product has a rule about who may do something, but one of the actions behind the feature does not check the rule. The behaviour is clearly not what the documentation promises.
Context
Error Tracking is the GitLab feature at the centre of this report. It connects a project to an external error monitoring service, here Sentry, and brings the errors that service collects into the project. Once the connection exists, the errors appear in the project's error tracking list at a path of the form https://gitlab.com/project_name/-/error_tracking/. From that list a user can create a GitLab issue that references a particular error, and then follow that issue as the error's status changes.
The question the report asks is who is allowed to do that. GitLab's permission documentation and its Error Tracking documentation both say that only a user with the Reporter role or above can see or modify Error Tracking details. The researcher found that the Create Issue action did not enforce that boundary: a Guest user could create a reference issue for an error and then track its status whenever another user resolved the error.
A quick note on the words used from here on. A role is a named permission level attached to a user in a project. A session is the state of being logged in: your browser holds a small piece of data, often called a cookie, that the server uses to recognise you on each request. A request is the message your browser sends to the server when you click something or submit a form, and a POST request is the kind used to send data that changes something on the server, such as creating a new issue.
Setup
The preconditions are simple and all of them are described in the report:
- A private project with a user holding the
Guestrole. - Sentry connected to that project from a
Maintaineraccount. - New issues created in Sentry, which automatically populate the errors in the project's error tracking page.
No special tooling is mentioned. The work is done with a captured HTTP request replayed from the Guest session. Capturing a request means recording exactly what the browser sent to the server, so it can be sent again later, possibly with small changes. Replaying it means sending that recorded request again, in this case while logged in as the Guest user.
Finding it
The researcher compared the documented permission model with the behaviour of the Create Issue action. The documentation says Error Tracking details are for Reporter and above, yet the request that creates an issue from an error was accepted from a Guest session. That mismatch is the whole finding: the action is reachable by a role that the documentation says should not have access to the feature at all.
Exploitation
Step 1: Prepare the project and the error data
Take a private project that has a Guest user, connect Sentry to it from the Maintainer account, and create new issues in Sentry. Those errors are then populated automatically in the project's error tracking page at https://gitlab.com/project_name/-/error_tracking/.
Why this step: you need a real error to point at, and you need two accounts at different permission levels so you can show that the low one can do something the high one is supposed to control. The Maintainer sets up the connection because that is the role that is allowed to manage the feature.
Step 2: Capture the Create Issue request
The request that creates an issue from an error carries the following POST data:
issue[title]=Title
issue[description]= Description
issue[sentry_issue_attributes][sentry_issue_identifier]=Error_Id
authenticity_token= your_auth_token
Line by line, in plain words:
issue[title]=Titlesets the title of the new GitLab issue. The square brackets are a common way of sending structured data in a form:issue[title]means "thetitlefield of theissueobject".issue[description]= Descriptionsets the body text of the issue.issue[sentry_issue_attributes][sentry_issue_identifier]=Error_Idis the important field. It carries the identifier of the Sentry error that the new issue should reference. In other words, it tells GitLab which error this issue belongs to.authenticity_token= your_auth_tokenis the usual CSRF token for the session. A CSRF token is a random value that the server puts into forms so it can tell that a request really came from the site's own pages and not from some other website trying to make your browser act on your behalf. It is tied to your logged-in session, so it is a secret and is replaced with[redacted]here.
Why this step: to change one value and resend the request, you first need to see the request in its normal form. Capturing it gives you a template that the server already accepts.
Step 3: Point the request at a chosen error
Change the Error_Id value to the reference id of some error, which is Sentry's error id. This selects which error the issue will be linked to.
Why this step: the identifier is what ties the new issue to a specific error. By choosing the value yourself, you decide which error the issue refers to, rather than letting the page fill it in for you.
Step 4: Send it from the Guest session
Execute the request using the Guest user's session. Executing the request from the Guest session creates an issue for that particular error, even though the Guest role is not supposed to have access to Error Tracking details.
Why this step: this is the actual test. If the permission rule were enforced, the server would refuse the request because the session belongs to a Guest. The fact that it succeeds is the vulnerability.
Step 5: Observe the status tracking
Log in as the Maintainer and resolve the error. Resolving the error closes the issue that the Guest user created, and the issue receives the message:
@Maintainer resolved the corresponding error and closed the issue
Why this step: resolving the error from the higher-privileged account closes the issue the Guest created and posts the resolution message, showing the issue's status follows the error.
Root cause
The Create Issue action for error tracking did not apply the same role check that governs viewing and modifying Error Tracking details. The documented rule is Reporter or above; the endpoint accepted a Guest. An endpoint is simply a specific address on the server that accepts a particular kind of request. The report does not describe the server-side code, so the precise location of the missing check is not stated. What can be said is that the authorisation decision for this action was weaker than the one protecting the rest of the feature, which is why a role that cannot see the error tracking list could still act on an error through this request.
Impact
A Guest user on a private project can create issues for Sentry errors and track their status. Resolving the error closes the linked issue and posts the resolution message, so the issue's status follows the error. The report frames the impact exactly this way: creating issues for Sentry errors and tracking their status. It does not claim access to the error contents, the ability to modify errors, or any effect beyond issue creation and status tracking.
Fix
The report does not describe the fix that was applied.
Variants to test
- Replay other error tracking actions (for example any action that reads or changes an error's state) from a
Guestsession and see whether they are rejected. A positive result is any action that succeeds where the documentation requiresReporter. - Try the same Create Issue request from a user with no membership in the project at all. A positive result is an issue being created for an error in a private project.
- On other GitLab features that link an internal object to an external service, check whether the linking action enforces the same role as the feature's list and detail views. A positive result is a lower-privileged role performing the link.
- After a successful link, resolve the external object from a higher-privileged account and watch the linked internal object. A positive result is a status change and a system message appearing in the lower-privileged user's view.
Hunting notes
This kind of bug hides where a feature has a documented role requirement but several separate actions behind it, each with its own authorisation check. During recon, read the permission documentation for the product and compare it with what each request in the feature actually accepts, replaying captured requests from the lowest role available. Recon here means the early exploration phase, where you learn how a product is built and what it promises before you start testing it.
The signal here was a documented rule (Reporter or above for Error Tracking) that did not match observed behaviour. The researcher showed impact by following the object through its full lifecycle: the Guest created the issue, the Maintainer resolved the error, and the issue closed with the resolution message.
Glossary
- Access control: the rules that decide which user is allowed to do which action.
- Broken access control: a situation where those rules exist on paper but one action does not enforce them.
- Cookie: a small piece of data stored by your browser that lets a website recognise your logged-in session.
- CSRF token: a random value placed in forms so the server can tell a request came from its own pages and not from another site; also called an authenticity token.
- Endpoint: a specific address on a server that accepts a particular kind of request.
- Error: in this context, a recorded crash or malfunction collected by an error monitoring service.
- Error Tracking: the GitLab feature that displays errors from an external service inside a project.
- Guest: the lowest GitLab project role mentioned in the report.
- HTTP request: the message a browser sends to a server to ask for a page or to submit data.
- Issue: a GitLab ticket or task used to track work.
- Maintainer: a high GitLab project role, able to manage the project and its integrations.
- POST request: a request that sends data to the server in order to change something, such as creating an issue.
- Private project: a project whose contents are visible only to its members.
- Recon: the exploration phase of testing, where you learn how a product works and what it promises.
- Reporter: a GitLab project role above
Guest, which the documentation requires for Error Tracking details. - Replay: sending a previously captured request again, possibly with small changes.
- Role: a named permission level attached to a user in a project.
- Sentry: an external service that monitors a running program and records its errors.
- Session: the state of being logged in, maintained across requests by the server using a cookie.
- Vulnerability: a weakness in a product that lets someone do something the product's rules do not allow.