Live data from Hacker News

Consumer key/secret for official Twitter clients

gist.github.com

61–70 of 104 posts

Re: Consumer key/secret for official Twitter clients

#61
post #6

Earlier quoted context omitted.

Yes. And that's the point of the disclosure.

Anyone know what are the API limits for these keys? Is Twitter really favoring this key, or is that hypothetical? Of course, you still have to log in as a user, and Twitter could blacklist accounts that use this key on non-Twitter apps, which are going to have a lot of 'tells' and a specific signature in patterns of how they use the API. (Twitter could even take advantage of that by hiding a code in a usage pattern,…

> Is Twitter really favoring this key, or is that hypothetical?

I don't know about API quotas, but I'm totally sure that they allow more than 100K tokens.

Re: Consumer key/secret for official Twitter clients

#62

uh, this is not good. Why would someone post that under their own github account?

Isn't this actually a great thing since it enables developers to develop Twitter clients that aren't dependent on tokens and approval from Twitter?

One could also develop Twitter clients that abuse the service since the regular API rules no longer apply to them..

Re: Consumer key/secret for official Twitter clients

#64
post #6

Earlier quoted context omitted.

Yes. And that's the point of the disclosure.

Anyone know what are the API limits for these keys? Is Twitter really favoring this key, or is that hypothetical? Of course, you still have to log in as a user, and Twitter could blacklist accounts that use this key on non-Twitter apps, which are going to have a lot of 'tells' and a specific signature in patterns of how they use the API. (Twitter could even take advantage of that by hiding a code in a usage pattern,…

> Is Twitter really favoring this key, or is that hypothetical?

In at least one way, yes. New third-party Twitter clients are limited to 100k users, but Twitter's official clients are unlimited. If those clients built in a "use your own authentication token" UI, you could put your official client's tokens in and work around that limit.

Re: Consumer key/secret for official Twitter clients

#66
post #20

Earlier quoted context omitted.

> OAuth just doesn't work with locally installed applications That's not really true, Twitter just has a broken model where they want to authenticate the application as well as the user... The rest of your comment is quite spot on, though. This is going to be a cat and mouse game for Twitter and I'm not sure they can win.

> That's not really true, Twitter just has a broken model where they want to authenticate the application as well as the user... No, it is still true. There's no point, at all, to OAuth on a native client. Native clients can: 1) Present fake browser chrome 2) Present no browser chrome 3) Inject their own scripts into the webview to acquire the username/password 4) Extract the browser username/password from the keycha…

> There's no point, at all, to OAuth on a native client.

As far as I understand it, you're right, except when OAuth is the only authentication mechanism provided and you want to, you know, develop a desktop app.

Of course, providing OAuth as the only authentication mechanism appears then to be the problem. But that is not a problem application writers can solve; it seems to be a problem that OAuth deployers have to deal with.

Re: Consumer key/secret for official Twitter clients

#67

Does twitter honor the the oauth_callback parameter? Otherwise, how can those keys be used by an attacker?

oauth_callback is only interesting for web app authorization. For out-of-band authorization flows, you can't protect it with a callback filter.

Since these keys were lifted from an application that does out-of-band auth flows, any other app could use them similarly at will.

Re: Consumer key/secret for official Twitter clients

#68
post #25
post #13

And with this one of the huge flaws of OAuth comes to play. OAuth just doesn't work with locally installed applications as it's impossible to hide anything there, but OAuth strongly relies on the client having some secret knowledge (the client token). As long as all clients are equal when using the API, this might go well (minus some malicious clients), but once some clients start to be more equal than others - even…

This is a surprise to absolutely no-one. That client keys & secrets were semi-public knowledge was obvious years ago, before I started working on OAuth at a much younger Twitter. The client key and secret is a rough trust metric for clients that are distributed publicly. Twitter can distribute new clients with new more-hidden secrets, and gain a bit more trust, for a while. The place where the client id and secret ac…

[deleted]

Re: Consumer key/secret for official Twitter clients

#69

Earlier quoted context omitted.

OAuth prevents apps from nabbing passwords, though.

If the app is displaying its own internal web view for OAuth, it can load any page it wants in there and tell the user it's Twitter. It can even fake an address bar with a twitter.com URL if it wants. Then use the common phishing technique of 'oops, you must have entered your password wrong' (the user didn't, but now the phisher has it), followed by a forward to the real site so the user suspects nothing. But this is…

> But this is hypothetical. In reality there is little motivation for apps in an App Store-like environment, which survive on customer goodwill, to want to do this.

Would anybody ever find out though?

It's clear that the App Store does no real checking of the apps they accept. Since the GUID use was banned, everyone has just switched to the just-as-unique MAC address to identify devices.

Re: Consumer key/secret for official Twitter clients

#70
post #47

For some reason several of the commenters here are explaining this away as a protocol bug (specifically with OAuth) but the challenge isn't at all protocol specific. Rather, it's a hardship with all client/server apps, specifically in that trusting any client requires additional support from the platform (self-assertion or possession of a secret by the client alone is insufficient) and even then it's known hard probl…

I have a work around for this. Is it mathematically provable that it is more secure? I don't know but I beieve it to be much better in many respects for native apps. It essentially leverages push notifications to deliver bearer tokens.

Push, in my mind, makes way more sense for mobile and benefits from code signing, known users, known devices, and an essentially private out of band network for push messaging, much of this exists because of the app publishing model in play. You can trust the binary because the developer is known via a developer code signing certificate. The user is known because they had to create an account in the platform's app store. You can trust the device (pretty sure of this) because of the unique device id. Incidentally this process could be achieved with any out of band communication it could be a whisper in the ear, a note delivered by carrier pigeon, an email or whatever, push just makes it more user friendly because its directly tied into the app making the request through a service managed by the OS. This system is basically a bearer token with an out-of-band delivery mechanism.

There is a "distributed authentication service" in this flow. This is essentially a central registry of all apps and services that use this auth strategy (I'm thinking something is needed like a certificate signing authority), The apps and services are catalogued and users can see security warnings from this service before they grant access to an app or service. Have you ever wondered what happens if a trusted compant goes out of business and the app gets bought by the mafia and an update goes out making it a malicious app? OK. you surely have not but a company going out of business, a blog post about a security breach, things like this are thret indicators and should play into the system, How DO you know if it is safe to grant access to an app or service you are new to? The only recourse you have is revoke access after you find out the problem. This is not good enough. I think there should be something like community awareness of security issues with apps and services that can alert users of said issues and that should be integrated into the auth process. This service provides a management console for users to enable and disable application access to specific user data or other third party services and audit activity by the user, their apps and by third party services. This management console also has the concept of levels of security. If the code has been audited and is from a highly reputable source it is put in a certain group, if it is a new app from a new company then it would not be graded as highly. We have something like this with green bar ssl certs. Banks and credit card companies do this kind of risk grading all the time, if we want an auth system to be worthy of our efforts and then is should be worthy of banking and e-commerce, we should be serious about preempting, identifying, and responding to risk throughout the auth process not just let people revoke access tokens when and IF they find out there was a problem.

Post reply on HN