Skip to content
OAuth / SSO Disclosed report Intermediate

Incorrect details on OAuth permissions screen allows DMs to be read without permission

The OAuth permission screen for certain official Twitter API keys incorrectly stated that the app could not read direct messages, while the keys actually allowed access to DMs. An attacker using these keys could read a user's private messages despite the screen showing otherwise.

edent Follow

Originally disclosed on HackerOne

Bounty$2,940 Medium 4.3 View original
  • Triaged in 10 hours
  • Fixed in 30 days
  • Paid in 10 days
  • Disclosed after 38 days

Summary by the program

The reporter discovered that when a select set of applications are authenticated using a PIN or non-intended OAuth flow, the permission dialog that is shown may not show the permissions that the application has. We do not believe anyone was mislead by the permissions that these applications had or that their data was unintentionally accessed by the Twitter for iPhone or Twitter for Google TV applications as those applications use other authentication flows. To our knowledge, there was not a breach of anyone's information due to this issue. There are no actions people need to take at this time.

The report

NOTE! Thanks for submitting a report! Please replace all the [square] sections below with the pertinent details. Remember, the more detail you provide, the easier it is for us to triage and respond quickly, so be sure to take your time filling out the report!

Summary: The OAuth screen can be tricked into saying that an app cannot read Direct Messages. Despite that, DMs can be read.

Description: The official Twitter API keys have been leaked and are in use in several popular apps. The iPhone keys and Google TV keys (as seen on https://gist.github.com/shobotch/5160017) present an OAuth screen which says the app "Will not be able to: Access your direct messages." This is false. The apps can read DMs.

Steps To Reproduce:

(Add details for how we can reproduce the issue)

  1. Ask the user to do the OAuth dance with a token generated from the official keys.
  2. User sees that the app cannot read DMs.
  3. User authorises.
  4. App now has unauthorised access to DMs.
  5. User is sad that their privacy has been violated.

Impact: [add why this issue matters]

A user may not want a 3rd party app to have access to their DMs.

They rely on the OAuth screen to adequately inform them of the permissions they are granting.

Is this a GDPR violation? I'm not sure. You are telling users that the 3rd party app can't read their private information - but that is false. These API keys do allow access from any app which integrates them.

Supporting Material/References:

  • Screenshot of the OAuth screen for Google TV
  • Screenshot of the OAuth screen for iPhone

Impact

Unauthorised access to Direct Messages.

Attachments

Google_TV_Twitter_DMs.png
Google_TV_Twitter_DMs.png From the original on HackerOne
iphone_dm.png
iphone_dm.png

The original report as published on HackerOne, by edent. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

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 OAuth permission screen was not correctly reflecting the actual scopes granted to tokens generated from certain official API keys.

Impact

A user's direct messages could be read by a third-party app even though the OAuth screen said they could not be, though Twitter stated it did not believe anyone was misled or that data was unintentionally accessed.

What the attacker needed

Victim uses an app with leaked official keys; victim authorises the app via OAuth

How it was found

  1. Ask the user to start the OAuth flow with a token from the official keys.
  2. The user sees that the app cannot read DMs.
  3. The user authorises the app.
  4. The app then has unauthorised access to DMs.

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 log in to an app with your Twitter account, Twitter shows a screen listing what the app can and cannot do. This report found that for some official Twitter apps, that screen wrongly said the app could not read your private messages, even though it could. So you might give permission thinking your messages are safe, but the app could still read them.

What is OAuth / SSO?

Mistakes in OAuth, OpenID Connect, SAML or token handling that leak codes and tokens or link an attacker's identity to a victim's account.

More from X / xAI

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

OAuth and single sign-on flaws

The lesson behind this report.

Mistakes in OAuth, OpenID Connect, SAML or token handling that leak codes and tokens or link an attacker's identity to a victim's account.