Skip to content
IDOR Advisory Beginner CVE-2026-26004

GHSL-2025-130: Unauthorized access to event data across organizational boundaries in Sentry - CVE-2026-26004

An authenticated user with event:read permission in their own organization could access event data from any other organization by manipulating the group_id parameter while keeping their own organization slug in the URL. This allowed unauthorized access to potentially sensitive event data across organizational boundaries.

p Follow

Originally disclosed on GitHub Security Lab

A cross-organization Insecure Direct Object Reference (IDOR) vulnerability has been identified in Sentry’s GroupEventJsonView endpoint.

p-, on GitHub Security Lab

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 6 min read.

Context

Sentry is an error and performance monitoring platform. Applications send it events, and those events are grouped into issues (internally, groups). Each event carries a payload that can include stack traces, request data, user context and other details that are often sensitive.

The affected feature is the frontend view that returns a single event as JSON: GroupEventJsonView. It is an OrganizationView, meaning it is reached through an organisation-scoped URL and requires the event:read scope. Its job is to take a group_id and an event_id_or_latest from the URL, resolve the group, and return the corresponding event as JSON to a user who is allowed to read events in the organisation named in the path.

The issue was reported by the GitHub Security Lab as GHSL-2025-130 and later assigned CVE-2026-26004. It is classified as CWE-639, Authorization Bypass Through User-Controlled Key.

Setup

The vulnerability was tested against Sentry v25.12.0.

The proof of concept needs two ordinary, non-admin users in two separate organisations:

  1. A victim user in an organisation with the URL slug victimorg.
  2. An attacker user in an organisation with the URL slug attackerorg.

The attacker only needs the event:read permission inside their own organisation. No membership of, or relationship with, the victim organisation is required.

The victim organisation needs at least one issue with at least one event. The report suggests creating one with sentry-cli. The attacker needs to know or guess the victim's group ID; the report notes that group IDs are consecutive numbers and therefore guessable with relative ease.

Finding it

The researcher looked at how GroupEventJsonView resolves the object it returns. Its get method receives the active organization from the view machinery, but when it looks up the group it calls get_group_with_redirect(group_id) without passing that organisation:

Python
class GroupEventJsonView(OrganizationView):
    required_scope = "event:read"

    def get(self, request: HttpRequest, organization, group_id, event_id_or_latest) -> HttpResponse:
        try:
            # TODO(tkaemming): This should *actually* redirect, see similar
            # comment in ``GroupEndpoint.convert_args``.
            group, _ = get_group_with_redirect(group_id) # <--- no organization provided

The lookup is therefore driven purely by the user-controlled group_id, with no constraint tying it to the organisation in the URL.

The second half of the problem is the authorisation model. The researcher describes it as binding only to the active organisation context, not to the resource:

  • get_access uses the active organisation.
  • has_permission checks required_scope on request.access.
  • convert_args injects the active organisation only.

The consequence is that nothing enforces that the group_id in the URL belongs to the injected organisation. A user who passes the scope check in their own organisation passes it for any group ID they supply.

Exploitation

Step 1: Prepare two organisations and users

Create the non-admin users victim and attacker in two distinct organisations with the URL slugs victimorg and attackerorg.

Step 2: Create victim data

In victimorg, create an issue with at least one event, for example using sentry-cli.

Step 3: Note the group ID

Record the issue/group ID, for example 12. Because group IDs are consecutive numbers, they are guessable with relative ease.

Step 4: Log in as the attacker

Authenticate as the attacker user, who has event:read only in attackerorg.

Step 5: Request the victim's event through the attacker's organisation

Visit the following URL, keeping the attacker's own organisation slug in the path and substituting the victim's group ID:

Text
<sentry-host>/organizations/attackerorg/issues/{victim_group_id}/events/latest/json/

The same request as a curl command:

Bash
curl -X GET \
  '<sentry-host>/organizations/{attacker_org}/issues/{victim_group_id}/events/latest/json/' \
  -H 'Cookie: sentrysid=<attacker_session_token>' \
  -H 'Accept: application/json'

The path segment {attacker_org} is the attacker's own organisation, which is what satisfies the organisation-scoped view and the event:read scope check. The {victim_group_id} segment is the user-controlled key that selects the object. The sentrysid cookie carries the attacker's session, and Accept: application/json asks for the JSON representation.

The result, as the report states, is that the attacker receives complete event data from the victim organisation.

Root cause

The view resolves the group by ID alone. get_group_with_redirect(group_id) is called without the organisation that the view already has in hand, so the object lookup is not scoped to the organisation in the URL.

Authorisation does not compensate for this. The frontend authorisation model checks the active organisation context and the required_scope on request.access, and convert_args injects only the active organisation. All of these checks are satisfied by the attacker's own organisation, so they never compare the requested group_id against the organisation that was authorised. There is no enforcement that the group_id in the URL belongs to the injected organisation.

The report classifies the weakness as CWE-639, Authorization Bypass Through User-Controlled Key.

Impact

The vulnerability allows any authenticated user with event:read permission in their own organisation to access sensitive event data from any other organisation, by manipulating at least the group_id parameter while keeping their own organisation slug in the URL path. The report describes the impact as unauthorised access to potentially sensitive event data across organisational boundaries.

The practical precondition is knowledge of the target group ID. The report notes that group IDs are consecutive numbers and therefore guessable with relative ease, which lowers that barrier.

Fix

Sentry fixed the vulnerability in pull request 105601 on 2026-01-02. The report does not describe the contents of the fix. At the time of the fix, Sentry decided not to issue a CVE; CVE-2026-26004 was assigned by GitHub on 2026-02-10.

Variants to test

  • Other organisation-scoped views that take an object ID and resolve it without passing the active organisation. A positive result is a response containing another organisation's object while the URL path names your own organisation.
  • Endpoints where the scope check is performed against the active organisation but the object lookup is keyed only by a numeric or otherwise guessable identifier. A positive result is a successful response for an ID that does not belong to your organisation.
  • Sequential identifier spaces. A positive result is that IDs you do not own resolve to data you should not see, confirming the keys are both guessable and unscoped.

Hunting notes

This bug hides in the gap between two mechanisms that each look correct on their own: an organisation-scoped view that enforces a scope on the active organisation, and an object lookup that takes only an ID. The signal during review is a view that receives organization but calls a lookup helper without it, exactly as in the snippet above. The code carries a TODO comment next to the lookup call.

During recon, look for organisation slugs in URL paths combined with numeric object IDs, and for endpoints that return JSON representations of objects. Consecutive numeric IDs make impact easy to demonstrate: create data in one organisation, then request it from a second account in a different organisation using the first organisation's ID.

The researcher showed impact by setting up two non-admin users in two organisations, creating a real event in the victim organisation, and retrieving its full event data as the attacker through the attacker's own organisation slug. The researcher showed impact by setting up two non-admin users in two organisations, creating a real event in the victim organisation, and retrieving its event data as the attacker through the attacker's own organisation slug.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 15 min read.

What happened, in plain words

Sentry is a service that helps software teams keep track of errors. When an application crashes or misbehaves, it sends a message to Sentry describing what went wrong. Sentry stores these messages as events, and groups similar events together into issues (internally called groups). An event can contain a lot of detail: the code that failed, information about the request that triggered it, details about the user who was affected, and more. That is exactly the kind of information you would not want a stranger to read.

Sentry is multi-tenant: many different companies (called organisations) use the same Sentry installation, and each organisation should only ever see its own data. The bug described here broke that separation. Any logged-in user who was allowed to read events in their own organisation could read event data belonging to a completely different organisation, simply by changing a number in a web address.

This kind of mistake has a name: an Insecure Direct Object Reference, or IDOR. The idea is simple. Imagine a hotel where every room key is just a number written on a card, and the front desk never checks whether the room belongs to you. If you are a paying guest, you can open your own door, but nothing stops you from writing a different room number on your card and opening someone else's door. The system trusts the number you supply instead of checking that the number is yours. That is what happened here: the web address contained an issue number, and Sentry looked up that issue without checking that it belonged to the organisation named in the same address.

The issue was found by the GitHub Security Lab and tracked as GHSL-2025-130. It was later given the official vulnerability identifier CVE-2026-26004. It is classified as CWE-639, which is the formal name for this family of bugs: Authorization Bypass Through User-Controlled Key. In plain terms: the part of the request the user controls (the number) was used to decide which data to return, without an authorisation check tying that data to the user.

Context

Sentry is an error and performance monitoring platform. Applications send it events, and those events are grouped into issues (internally, groups). Each event carries a payload that can include stack traces, request data, user context and other details that are often sensitive.

A few of those words deserve a slower explanation for anyone new to this.

  • An event is a single report sent by an application to Sentry, for example "at 14:03 this web page crashed with this error".
  • A payload is the body of that report, the actual contents. In Sentry's case it can include a stack trace (the list of function calls that led to the crash, like a breadcrumb trail showing where the program was), request data (what the user's browser asked for), and user context (who was using the application at the time).
  • An issue (or group) is Sentry's way of bundling many similar events together so a team sees one problem instead of thousands of copies. Each issue has a numeric identifier, the group ID.

A quick word on JSON, because it appears throughout. JSON is a plain-text format for structured data, a way of writing information as labelled fields so a program can read it easily. When this report says an endpoint returns an event "as JSON", it means the server sends the event's details back as structured text rather than as a web page.

The affected feature is the frontend view that returns a single event as JSON: GroupEventJsonView. A view here is simply a piece of server code that handles one particular kind of web request and produces a response. It is an OrganizationView, meaning it is reached through an organisation-scoped URL and requires the event:read scope.

Two more terms unpacked:

  • An organisation-scoped URL is a web address that includes the organisation's short name (its slug) in the path, so the server knows which organisation's area of the site you are asking about. Think of it as a folder name in a filing cabinet: /organizations/yourcompany/....
  • A scope is a permission label. event:read means "may read events". Sentry checks that the logged-in user holds this permission before answering.

Its job is to take a group_id and an event_id_or_latest from the URL, resolve the group, and return the corresponding event as JSON to a user who is allowed to read events in the organisation named in the path. In other words: the address says which organisation you are in, which issue you want, and which event of that issue (or simply the latest one), and the server hands back the event's details.

The issue was reported by the GitHub Security Lab as GHSL-2025-130 and later assigned CVE-2026-26004. It is classified as CWE-639, Authorization Bypass Through User-Controlled Key.

Setup

The vulnerability was tested against Sentry v25.12.0.

The proof of concept needs two ordinary, non-admin users in two separate organisations:

  1. A victim user in an organisation with the URL slug victimorg.
  2. An attacker user in an organisation with the URL slug attackerorg.

Why two ordinary users and not administrators? Because the point of the bug is that no special power is needed. The attacker only needs the event:read permission inside their own organisation. No membership of, or relationship with, the victim organisation is required. That is what makes it serious: the lowest level of legitimate access is enough to reach someone else's data.

The victim organisation needs at least one issue with at least one event. The report suggests creating one with sentry-cli. sentry-cli is Sentry's command-line tool, a program you run in a terminal to send test data to Sentry; the report uses it simply as a convenient way to produce a realistic issue with a real event inside it.

The attacker needs to know or guess the victim's group ID; the report notes that group IDs are consecutive numbers and therefore guessable with relative ease. Consecutive means 1, 2, 3, 4 and so on, with no gaps. If you can see that your own issues are numbered 40 and 41, it is a fair bet that other organisations' issues are numbered nearby. This is like house numbers on a street: knowing one number tells you roughly where the others are.

Finding it

The researcher looked at how GroupEventJsonView resolves the object it returns. Its get method receives the active organization from the view machinery, but when it looks up the group it calls get_group_with_redirect(group_id) without passing that organisation:

Python
class GroupEventJsonView(OrganizationView):
    required_scope = "event:read"

    def get(self, request: HttpRequest, organization, group_id, event_id_or_latest) -> HttpResponse:
        try:
            # TODO(tkaemming): This should *actually* redirect, see similar
            # comment in ``GroupEndpoint.convert_args``.
            group, _ = get_group_with_redirect(group_id) # <--- no organization provided

Line by line, in plain words:

  • class GroupEventJsonView(OrganizationView): declares the view and says it is a kind of organisation-scoped view, so it inherits the standard organisation checks.
  • required_scope = "event:read" states the permission needed to use it: the ability to read events.
  • def get(self, request: HttpRequest, organization, group_id, event_id_or_latest) -> HttpResponse: is the function that handles a request. It receives four things: the request itself, the organisation worked out from the URL, the group ID from the URL, and either a specific event ID or the word "latest". Notice that the organisation is handed to this function.
  • The two comment lines are notes left by Sentry's own developers, including a TODO, a marker programmers use for "this part still needs work".
  • group, _ = get_group_with_redirect(group_id) is the crucial line. It looks up the group using only the number. The organisation that the function already has in its hands is not passed along. The researcher's inline comment, <--- no organization provided, points straight at the gap.

The lookup is therefore driven purely by the user-controlled group_id, with no constraint tying it to the organisation in the URL. "User-controlled" means the value comes from the person making the request, so they can put whatever they like there.

The second half of the problem is the authorisation model. The researcher describes it as binding only to the active organisation context, not to the resource:

  • get_access uses the active organisation.
  • has_permission checks required_scope on request.access.
  • convert_args injects the active organisation only.

These three names are internal pieces of Sentry's permission machinery. Taken one at a time:

  • get_access works out what the current user is allowed to do, based on the organisation that is currently active (the one in the URL).
  • has_permission then checks whether that access includes the required scope, here event:read.
  • convert_args prepares the arguments for the view and fills in the active organisation.

The consequence is that nothing enforces that the group_id in the URL belongs to the injected organisation. A user who passes the scope check in their own organisation passes it for any group ID they supply. The permission check answers the question "may this person read events in the organisation named in the address?" but never asks the follow-up question "does the issue number they typed actually belong to that organisation?".

Exploitation

Step 1: Prepare two organisations and users

Create the non-admin users victim and attacker in two distinct organisations with the URL slugs victimorg and attackerorg.

This step exists to recreate the real-world situation: two separate customers sharing one Sentry installation. Without two organisations there is nothing to cross between.

Step 2: Create victim data

In victimorg, create an issue with at least one event, for example using sentry-cli.

This gives the victim something worth stealing. A real event, with its stack trace and request details, is what makes the demonstration convincing rather than theoretical.

Step 3: Note the group ID

Record the issue/group ID, for example 12. Because group IDs are consecutive numbers, they are guessable with relative ease.

This is the "key" in the hotel analogy. The report notes that group IDs are consecutive numbers and therefore guessable with relative ease.

Step 4: Log in as the attacker

Authenticate as the attacker user, who has event:read only in attackerorg.

Logging in matters because the bug is not open to anonymous visitors. It requires a legitimate account, which is precisely why it is easy to overlook: the attacker looks like a normal, well-behaved customer.

Step 5: Request the victim's event through the attacker's organisation

Visit the following URL, keeping the attacker's own organisation slug in the path and substituting the victim's group ID:

Text
<sentry-host>/organizations/attackerorg/issues/{victim_group_id}/events/latest/json/

Reading the address from left to right: <sentry-host> is the Sentry server's address; /organizations/attackerorg/ says "I am acting inside my own organisation", which is true and passes every check; /issues/{victim_group_id}/ names the issue, and this is the part the attacker fills in with someone else's number; /events/latest/json/ asks for the most recent event of that issue, in JSON form.

The same request as a curl command:

Bash
curl -X GET \
  '<sentry-host>/organizations/{attacker_org}/issues/{victim_group_id}/events/latest/json/' \
  -H 'Cookie: sentrysid=<attacker_session_token>' \
  -H 'Accept: application/json'

curl is a command-line tool for making web requests, useful for showing exactly what is sent. Line by line:

  • curl -X GET sends a GET request, the ordinary kind a browser makes when you open a page.
  • The long line in single quotes is the URL, with placeholders for the server, the attacker's organisation and the victim's group ID.
  • -H 'Cookie: sentrysid=<attacker_session_token>' attaches a cookie. A cookie is a small piece of text your browser stores and sends back with each request so the server can recognise you. Here sentrysid is the cookie that carries the attacker's logged-in session, and the session token is the secret value proving who they are. Without it the server would treat the request as anonymous.
  • -H 'Accept: application/json' tells the server the client would like the answer in JSON, the structured text format described earlier.

The path segment {attacker_org} is the attacker's own organisation, which is what satisfies the organisation-scoped view and the event:read scope check. The {victim_group_id} segment is the user-controlled key that selects the object. The sentrysid cookie carries the attacker's session, and Accept: application/json asks for the JSON representation.

The result, as the report states, is that the attacker receives complete event data from the victim organisation. The server checked the attacker's permission in their own organisation, found it valid, then fetched the issue by number alone, and the number pointed at the victim's data.

Root cause

The view resolves the group by ID alone. get_group_with_redirect(group_id) is called without the organisation that the view already has in hand, so the object lookup is not scoped to the organisation in the URL.

Authorisation does not compensate for this. The frontend authorisation model checks the active organisation context and the required_scope on request.access, and convert_args injects only the active organisation. All of these checks are satisfied by the attacker's own organisation, so they never compare the requested group_id against the organisation that was authorised. There is no enforcement that the group_id in the URL belongs to the injected organisation.

A useful way to picture it: two guards each do their job correctly. One checks that you are allowed into the building. The other fetches whatever file you name. Neither of them checks that the file belongs to your department. The bug lives in the gap between the two.

The report classifies the weakness as CWE-639, Authorization Bypass Through User-Controlled Key.

Impact

The vulnerability allows any authenticated user with event:read permission in their own organisation to access sensitive event data from any other organisation, by manipulating at least the group_id parameter while keeping their own organisation slug in the URL path. The report describes the impact as unauthorised access to potentially sensitive event data across organisational boundaries.

"At least the group_id" is worth noticing: the report says this parameter is enough, and does not claim it is the only one.

The practical precondition is knowledge of the target group ID. The report notes that group IDs are consecutive numbers and therefore guessable with relative ease, which lowers that barrier.

Fix

Sentry fixed the vulnerability in pull request 105601 on 2026-01-02. The report does not describe the contents of the fix. At the time of the fix, Sentry decided not to issue a CVE; CVE-2026-26004 was assigned by GitHub on 2026-02-10.

A pull request is a proposed change to a codebase, reviewed before it is merged. A CVE is a public catalogue number for a known vulnerability, so people can look it up and track it.

Variants to test

  • Other organisation-scoped views that take an object ID and resolve it without passing the active organisation. A positive result is a response containing another organisation's object while the URL path names your own organisation.
  • Endpoints where the scope check is performed against the active organisation but the object lookup is keyed only by a numeric or otherwise guessable identifier. A positive result is a successful response for an ID that does not belong to your organisation.
  • Sequential identifier spaces. A positive result is that IDs you do not own resolve to data you should not see, confirming the keys are both guessable and unscoped.

An endpoint is simply one address on a server that answers a particular kind of request. The three bullets are three ways to look for the same underlying mistake elsewhere: a permission check that looks at the wrong thing, a lookup that trusts a number, and numbering schemes that make guessing easy.

Hunting notes

This bug hides in the gap between two mechanisms that each look correct on their own: an organisation-scoped view that enforces a scope on the active organisation, and an object lookup that takes only an ID. The signal during review is a view that receives organization but calls a lookup helper without it, exactly as in the snippet above. The code carries a TODO comment next to the lookup call.

During recon, look for organisation slugs in URL paths combined with numeric object IDs, and for endpoints that return JSON representations of objects. Recon, short for reconnaissance, means the exploratory phase of looking around an application to see how it is built. Consecutive numeric IDs make impact easy to demonstrate: create data in one organisation, then request it from a second account in a different organisation using the first organisation's ID.

The researcher showed impact by setting up two non-admin users in two organisations, creating a real event in the victim organisation, and retrieving its full event data as the attacker through the attacker's own organisation slug. The researcher showed impact by setting up two non-admin users in two organisations, creating a real event in the victim organisation, and retrieving its event data as the attacker through the attacker's own organisation slug. Cross-tenant means one customer reaching another customer's data, and reproducible means anyone following the same steps gets the same result.

Glossary

  • API: a defined way for one program to ask another for data or actions, usually over the web.
  • Authorisation: deciding whether a user is allowed to do a particular thing, as opposed to authentication, which is deciding who they are.
  • Cookie: a small piece of text a browser stores and sends back with requests so a server can recognise the user.
  • Cross-tenant: reaching data that belongs to a different customer (tenant) of the same service.
  • curl: a command-line tool for sending web requests.
  • CVE: a public catalogue number assigned to a known vulnerability so it can be tracked.
  • CWE-639: the catalogue name for authorization bypass through a user-controlled key, the class this bug belongs to.
  • Endpoint: one address on a server that handles a particular kind of request.
  • Event: a single report an application sends to Sentry, for example about a crash.
  • Group / issue: Sentry's bundle of similar events, identified by a numeric group ID.
  • Group ID: the number identifying an issue; in this report these numbers are consecutive and therefore guessable.
  • IDOR (Insecure Direct Object Reference): a bug where a user-supplied identifier is used to fetch data without checking that the data belongs to that user.
  • JSON: a plain-text format for structured data made of labelled fields.
  • Organisation: one customer's separate area inside a shared Sentry installation.
  • Organisation-scoped URL: a web address containing the organisation's slug, telling the server which customer's area is being used.
  • Payload: the contents of a message, here the details carried inside an event.
  • Permission / scope: a label such as event:read saying what a user may do.
  • Pull request: a proposed code change, reviewed before being merged.
  • Recon: the exploratory phase of studying an application to understand how it works.
  • Reproducible: repeatable by anyone following the same steps, with the same result.
  • Scope: see permission; a named permission required by a view.
  • sentry-cli: Sentry's command-line tool, used here to create a realistic issue and event.
  • Session token: the secret value in a cookie that proves a user is logged in.
  • Slug: the short name of an organisation as it appears in a URL, such as attackerorg.
  • Stack trace: the list of function calls that led to an error, like a breadcrumb trail.
  • TODO: a note programmers leave in code marking work that still needs doing.
  • User-controlled: a value that comes from the person making the request and can therefore be set to anything.
  • View: a piece of server code that handles one kind of request and produces a response.

More by p

View all

49 more disclosed reports, best first.

More from GitHub Security Lab

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Insecure direct object reference (IDOR)

The lesson behind this report.

One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.