Skip to content
IDOR Write-up Intermediate

Add comment on a private Oculus Developer support

The Oculus Developer support GraphQL endpoint allowed adding comments to private bug reports by supplying a comment ID (external_post_id) from another user's private bug, without verifying that the comment belonged to the same bug. An attacker who knew or guessed a victim's comment ID could post comments on private bug reports.

Sarmad Hassan Follow

Published on blog.flawminers.com

Oculus Developer support is the dedicated hub for developers and creators seeking to explore the limitless possibilities of virtual reality (VR) on the Oculus platform for more details see https://developer.oculus.com/support/

Sarmad Hassan, on blog.flawminers.com

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. 5 min read.

Context

Oculus Developer support is the hub for developers and creators working with virtual reality on the Oculus platform. The researcher points to https://developer.oculus.com/support/ as the entry point for the feature set he examined.

Within that domain there is an option labelled 'Report a Bug', which lets users submit general bugs to the Oculus support team. Bug reports live under a URL of the form https://developer.oculus.com/bugs/bug/your-bug-ID/, and each report can carry comments, including replies to other comments. The finding concerns that commenting flow: a user who knows the comment ID belonging to someone else's private bug report could add a comment to that private report.

Setup

The researcher had tested Oculus a few months earlier without finding anything, and returned to the platform on 17 September for a fresh examination. The Plan B test used two separate accounts to confirm that one account could comment on a bug owned by the other. Requests were intercepted and modified with Burp Suite. No specific versions of anything are given.

The precondition for the attack is knowledge of a comment ID that belongs to a private bug report. The report treats this as the hard part and returns to it under Bug Limitation.

Finding it

While exploring the Oculus Developer domain the researcher came across the 'Report a Bug' option. The feature itself is ordinary: users submit bugs to the Oculus support team. What drew his attention was the commenting behaviour around bug reports, and specifically the identifiers carried in the request that posts a reply to a comment. If those identifiers were trusted without checking ownership, a user might be able to comment on a report that is not theirs.

Exploitation

Step 1: create a public bug, comment, and reply to your own comment

The researcher created a public bug and added a comment to it. He then replied to his own comment and intercepted the resulting request in Burp Suite to inspect the parameters. The request structure was as follows:

HTTP
POST /graphql?locale=user HTTP/1.1
Host: graph.oculus.com

access_token=My-Access-Token&variables={"input":{"client_mutation_id":"1","comment_parent_id":"556190998150906","external_post_id":"548709645565708","message":"whatever"}}&blablabla

Two parameters in the GraphQL variables stood out:

  1. comment_parent_id: the bug ID, which is visible in the URL of the report, https://developer.oculus.com/bugs/bug/your-bug-ID/.
  2. external_post_id: the ID of the comment being replied to, in this case the researcher's own comment.

Step 2, Plan A: swap the bug ID

The first idea was to add a comment to another user's private bug by replacing his own bug ID in comment_parent_id with the victim's bug ID. This approach did not work: the request did not yield the desired result.

Step 3, Plan B: swap the comment ID

The second idea kept the request aimed at the victim's private bug but changed external_post_id to the comment ID of a comment on that private bug. Tested with two separate accounts, this succeeded. The report says the security measures verified based on the bug ID and not the external_post_id (comment ID), and the reply was accepted. The researcher notes that he expected Plan B to work while he was still on Plan A, without being able to explain why.

From the original on blog.flawminers.com

Root cause

The authorisation decision on the reply mutation was tied to the bug identified by comment_parent_id and did not extend to the comment identified by external_post_id. The report says the checks were based on the bug ID and not the comment ID, so changing external_post_id to a comment on a private bug succeeded. In other words, the ownership check covered one of the two object references in the request and not the other, which is the classic shape of an IDOR in a nested-object mutation. The report describes the behaviour directly; the underlying code is not shown, so the exact check that was missing is inferred from the observed results.

Bug Limitation

The report is explicit that the bug had a single limitation: how does an attacker obtain other users' comment IDs from their private bugs? Private bugs are accessible only to the bug owner and the support team, so discovering such an identifier is inherently difficult, if not seemingly impossible.

The researcher does not claim a reliable way to obtain those IDs. He raises the possibility that an attacker who somehow uncovers other users' comment IDs, or who assembles a list of random comment IDs, could mount a methodical yet random attack. He frames this as a reminder that everything is within the realm of plausibility, not as a demonstrated technique. The practical consequence is that the vulnerability is real but its exploitation depends on a precondition the report does not solve.

Impact

An attacker who knows the comment ID of a comment on another user's private Oculus Developer bug report can add a comment to that private report. The attack requires the comment ID as a precondition, and the report does not describe any way of obtaining it at scale. No bounty amount, CVSS score or severity rating is stated in the text.

Fix

The report records that the bug was fixed by Meta on 5 October 2018 and that the researcher confirmed the fix the same day. It does not describe the change that was made.

Timeline

Date Actor Event
17 Sep 2018 Sarmad Initial report
19 Sep 2018 Meta Bug Bounty Report triaged
05 Oct 2018 Meta Bug Bounty Bug fixed
05 Oct 2018 Sarmad Fix confirmed
10 Oct 2018 Meta Bug Bounty Bounty awarded

Variants to test

  1. Nested-object mutations elsewhere. Look for GraphQL or REST mutations that take two object references, such as a parent ID and a child ID, and try mixing a parent you own with a child you do not. A positive result is a successful write against the other user's object.
  2. Reply and edit flows. Test editing or deleting a comment by supplying a comment ID that belongs to another account while keeping the parent ID your own. A positive result is a state change on the other account's comment.
  3. Attachment and file references. Where a mutation links an attachment or upload to a post, try pairing your own post ID with someone else's attachment ID. A positive result is the attachment appearing under your object or being readable through it.
  4. Identifier enumeration. Where comment IDs are sequential or otherwise predictable, sample nearby values in a reply mutation and watch for responses that differ from the rejection case. A positive result is any accepted write to an object you do not own.
  5. Cross-check both identifiers. For any endpoint that validates one identifier, repeat the request with the validated identifier unchanged and the unvalidated one swapped for a value from a second account. A positive result confirms the check is one-sided.

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. 14 min read.

What happened, in plain words

Oculus is a virtual reality (VR) platform. Alongside the headsets and games, Oculus runs a website for the people who build things for it, called developers. That website has a support area where developers can report problems (bugs) to the Oculus support team. Each report can have comments under it, and people can reply to those comments, a bit like a thread under a social media post.

The researcher found that if you knew the internal number (the ID) of a comment on someone else's private bug report, you could post a reply to that private report, even though you were not allowed to see it. The private report belongs only to the person who filed it and to the support team. The weakness is a type of access-control bug called an IDOR, which stands for Insecure Direct Object Reference: the server takes an ID number from the request and acts on it without properly checking that the person sending the request is allowed to touch the thing that number points to.

The report walks through how the researcher found it, the two attempts he made, the one limitation that makes the attack hard in practice, and the timeline of the fix. Below is the same story, explained from the ground up.

Background you need first

A few everyday ideas come up again and again in this report, so here they are before we start.

A website and its server. When you open a page in your browser, your browser sends a request over the internet to a computer called a server, and the server sends back the page. Most of what you see is just text and images.

An API. Many websites also have a second, hidden way of talking to the server, meant for the website's own code rather than for you clicking links. This is called an API (Application Programming Interface). Think of it as the kitchen of a restaurant: you (the browser) order from the menu, and the kitchen (the API) does the actual work behind the scenes. The website's buttons quietly send messages to the API, and the API replies with data.

GraphQL. The Oculus API in this report is a GraphQL API. GraphQL is a style of API where the request describes exactly what it wants, in a structured text format. You will see a chunk of text in the request that looks like {"input":{...}}. That is the GraphQL part: it is a small package of instructions saying what to do and with which IDs.

A token. When you log in, the server needs a way to recognise you on every later request, because the web does not remember you by itself. It gives your browser a secret string, called a token (or a session cookie). Your browser sends it back with every request, and the server uses it to know who you are. In the request below, the token is called access_token. Treat it like a password: anyone who has it can act as you.

An ID. Almost everything stored on a server has a number that identifies it: a user, a post, a comment, a bug report. These numbers are called IDs. They often appear in web addresses, like the bug report address in this report, https://developer.oculus.com/bugs/bug/your-bug-ID/, where your-bug-ID is replaced by the actual number.

Intercepting a request. Normally your browser sends a request and you never see it. A tool called Burp Suite sits between your browser and the server and lets you pause, read and edit requests before they go out. That is how the researcher inspected and changed the values in this report.

Two accounts. To prove that one person can affect another person's data, you need two separate logins: one playing the attacker, one playing the victim. The researcher used two accounts.

IDOR. As above: the server trusts an ID number supplied by the client and does not check that this particular client is allowed to use it. A simple comparison: a hotel clerk who hands out a room key whenever someone reads out a room number, without checking that the person is the guest in that room.

The product and the feature

Oculus Developer support is the hub for developers and creators working with virtual reality on the Oculus platform. The researcher points to https://developer.oculus.com/support/ as the entry point for the feature set he examined.

Within that domain there is an option labelled 'Report a Bug', which lets users submit general bugs to the Oculus support team. Bug reports live under a URL of the form https://developer.oculus.com/bugs/bug/your-bug-ID/, and each report can carry comments, including replies to other comments. The finding concerns that commenting flow: a user who knows the comment ID belonging to someone else's private bug report could add a comment to that private report.

Setup

The researcher had tested Oculus a few months earlier without finding anything, and returned to the platform on 17 September for a fresh examination. The Plan B test used two separate accounts to confirm that one account could comment on a bug owned by the other. Requests were intercepted and modified with Burp Suite. No specific versions of anything are given.

The precondition for the attack is knowledge of a comment ID that belongs to a private bug report. The report treats this as the hard part and returns to it under Bug Limitation.

Finding it

While exploring the Oculus Developer domain the researcher came across the 'Report a Bug' option. The feature itself is ordinary: users submit bugs to the Oculus support team. What drew his attention was the commenting behaviour around bug reports, and specifically the identifiers carried in the request that posts a reply to a comment. If those identifiers were trusted without checking ownership, a user might be able to comment on a report that is not theirs.

In plain terms: every time you reply to a comment, your browser sends a small message to the server saying "add this reply, under this bug, in reply to this comment". The message contains numbers for the bug and for the comment. The researcher's question was: does the server check that both of those numbers belong to you, or only one?

Exploitation

Step 1: create a public bug, comment, and reply to your own comment

The researcher created a public bug and added a comment to it. He then replied to his own comment and intercepted the resulting request in Burp Suite to inspect the parameters. The request structure was as follows:

HTTP
POST /graphql?locale=user HTTP/1.1
Host: graph.oculus.com

access_token=My-Access-Token&variables={"input":{"client_mutation_id":"1","comment_parent_id":"556190998150906","external_post_id":"548709645565708","message":"whatever"}}&blablabla

Line by line, in plain words:

  • POST /graphql?locale=user HTTP/1.1: this is the first line of an HTTP request. POST means "I am sending data to the server to create or change something". /graphql?locale=user is the address on the server being called, and locale=user is a small extra setting (here, a language or region hint). HTTP/1.1 is the version of the web protocol being used.
  • Host: graph.oculus.com: tells the server which website name this request is for. Notice it is graph.oculus.com, not developer.oculus.com: the developer site's buttons talk to a separate API server.
  • The blank line separates the request headers (the labels above) from the body (the data below).
  • access_token=My-Access-Token: the token that identifies who is making the request. In the real request this was the researcher's own token; here it is replaced with a placeholder.
  • variables={"input":{...}}: the GraphQL instructions, packaged as a value called variables. Inside is an input object with several fields:
    • client_mutation_id: "1". A label the client attaches to the request, used to recognise it. A "mutation" in GraphQL means an action that changes data, as opposed to a query that only reads.
    • comment_parent_id: "556190998150906". The bug report the reply belongs to. This is the researcher's own bug.
    • external_post_id: "548709645565708". The comment being replied to. This is the researcher's own comment.
    • message: "whatever". The text of the reply.
  • &blablabla: a placeholder for other parameters that were in the request but are not relevant to the finding.

Two parameters in the GraphQL variables stood out:

  1. comment_parent_id: the bug ID, which is visible in the URL of the report, https://developer.oculus.com/bugs/bug/your-bug-ID/.
  2. external_post_id: the ID of the comment being replied to, in this case the researcher's own comment.

Why this step: by replying to his own comment on his own bug, the researcher could see a request that was guaranteed to be allowed. That gave him a clean template to modify, one value at a time, and see what the server would accept.

Step 2, Plan A: swap the bug ID

The first idea was to add a comment to another user's private bug by replacing his own bug ID in comment_parent_id with the victim's bug ID. This approach did not work: the request did not yield the desired result.

In plain words: he kept the reply aimed at his own comment but told the server the reply belonged to someone else's bug. The server refused. That refusal is useful information: it tells you the server does check the bug ID, at least in this combination.

Step 3, Plan B: swap the comment ID

The second idea kept the request aimed at the victim's private bug but changed external_post_id to the comment ID of a comment on that private bug. Tested with two separate accounts, this succeeded. The report says the security measures verified based on the bug ID and not the external_post_id (comment ID), and the reply was accepted. The researcher notes that he expected Plan B to work while he was still on Plan A, without being able to explain why.

In plain words: this time the bug ID in the request was the victim's, and the comment ID was also the victim's. The server checked the bug ID and accepted the reply, without checking the comment ID against the same rule. The comment ID was never checked against the same rule. The result: the reply was accepted on a private report the attacker should not have been able to touch.

From the original on blog.flawminers.com

Root cause

The authorisation decision on the reply mutation was tied to the bug identified by comment_parent_id and did not extend to the comment identified by external_post_id. The report says the checks were based on the bug ID and not the comment ID, so changing external_post_id to a comment on a private bug succeeded. In other words, the ownership check covered one of the two object references in the request and not the other, which is the classic shape of an IDOR in a nested-object mutation. The report describes the behaviour directly; the underlying code is not shown, so the exact check that was missing is inferred from the observed results.

A comparison: a building where the front desk checks your badge for the main door, but once you are inside, every office door opens when you say a room number, without anyone checking whether that room is yours.

Bug Limitation

The report is explicit that the bug had a single limitation: how does an attacker obtain other users' comment IDs from their private bugs? Private bugs are accessible only to the bug owner and the support team, so discovering such an identifier is inherently difficult, if not seemingly impossible.

The researcher does not claim a reliable way to obtain those IDs. He raises the possibility that an attacker who somehow uncovers other users' comment IDs, or who assembles a list of random comment IDs, could mount a methodical yet random attack. He frames this as a reminder that everything is within the realm of plausibility, not as a demonstrated technique. The practical consequence is that the vulnerability is real but its exploitation depends on a precondition the report does not solve.

In plain words: the lock is broken, but you still need to know the room number, and the room numbers are not printed anywhere you can see. That makes the bug real but hard to use in practice.

Impact

An attacker who knows the comment ID of a comment on another user's private Oculus Developer bug report can add a comment to that private report. The attack requires the comment ID as a precondition, and the report does not describe any way of obtaining it at scale. No bounty amount, CVSS score or severity rating is stated in the text.

Fix

The report records that the bug was fixed by Meta on 5 October 2018 and that the researcher confirmed the fix the same day. It does not describe the change that was made.

In plain words: check both numbers, not just one. If the comment ID does not belong to the bug ID, refuse the reply.

Timeline

Date Actor Event
17 Sep 2018 Sarmad Initial report
19 Sep 2018 Meta Bug Bounty Report triaged
05 Oct 2018 Meta Bug Bounty Bug fixed
05 Oct 2018 Sarmad Fix confirmed
10 Oct 2018 Meta Bug Bounty Bounty awarded

"Triaged" means the bug bounty team read the report and accepted it as a real issue worth investigating. "Bounty awarded" means the researcher was paid for the finding; the amount is not stated.

Variants to test

These are ideas for the same kind of mistake in other places. They are written for someone learning, so each one says what to look for and what a positive result looks like.

  1. Nested-object mutations elsewhere. Look for GraphQL or REST mutations that take two object references, such as a parent ID and a child ID, and try mixing a parent you own with a child you do not. A positive result is a successful write against the other user's object.
  2. Reply and edit flows. Test editing or deleting a comment by supplying a comment ID that belongs to another account while keeping the parent ID your own. A positive result is a state change on the other account's comment.
  3. Attachment and file references. Where a mutation links an attachment or upload to a post, try pairing your own post ID with someone else's attachment ID. A positive result is the attachment appearing under your object or being readable through it.
  4. Identifier enumeration. Where comment IDs are sequential or otherwise predictable, sample nearby values in a reply mutation and watch for responses that differ from the rejection case. A positive result is any accepted write to an object you do not own.
  5. Cross-check both identifiers. For any endpoint that validates one identifier, repeat the request with the validated identifier unchanged and the unvalidated one swapped for a value from a second account. A positive result confirms the check is one-sided.

Glossary

  • API: the hidden way a website's own code talks to its server, separate from the pages you click.
  • Access control: the rules that decide who is allowed to do what.
  • Authorisation: the server's decision about whether a particular user is allowed to perform a particular action.
  • Bug bounty: a programme where a company pays researchers for reporting security problems.
  • Burp Suite: a tool that sits between your browser and a server so you can pause, read and edit requests.
  • Comment ID: the number that identifies a single comment on a bug report.
  • Cookie: a small piece of data a website stores in your browser, often used to remember that you are logged in.
  • CVSS: a standard scoring system for how severe a security bug is.
  • Developer: a person who builds software or content for a platform.
  • Endpoint: a specific address on a server that accepts requests, such as /graphql.
  • Enumeration: trying many ID values in turn to find ones that exist or behave differently.
  • GraphQL: a style of API where the request describes exactly what it wants, in a structured text format.
  • HTTP: the protocol browsers and servers use to exchange requests and responses.
  • ID: a number or string that identifies a stored object, such as a user, post or comment.
  • IDOR (Insecure Direct Object Reference): a bug where the server trusts an ID supplied by the client without checking that the client is allowed to use it.
  • Impact: the harm a bug could cause if exploited.
  • Intercept: to pause a request in a tool before it reaches the server, so you can read or change it.
  • Mutation: in GraphQL, a request that changes data, as opposed to a query that only reads.
  • Oculus: a virtual reality platform.
  • Parameter: a named value sent with a request, such as comment_parent_id.
  • POST: an HTTP method meaning "I am sending data to create or change something".
  • Precondition: something that must be true before an attack can work.
  • Private bug report: a bug report visible only to its owner and the support team.
  • Request: the message a browser (or tool) sends to a server.
  • Response: the message a server sends back.
  • Root cause: the underlying reason a bug exists.
  • Server: the computer that stores data and answers requests.
  • Session: the period during which a server recognises you as logged in.
  • Severity: a rating of how serious a bug is.
  • Token: a secret string that identifies you to a server, like a password for a single session.
  • Triaged: reviewed and accepted as a real issue by a bug bounty team.
  • URL: the address of a page or resource on the web.
  • Vulnerability: a weakness that could be used to break security.

More by Sarmad Hassan

View all

17 more disclosed reports, best first.

More from Meta

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.