10 ms·
Google OAuth is broken (sort of)
- cedws 3y agoIs it just me that feels $1337 is an insult? FAANG pays way too low bounties for this kind of stuff. This kind of info would be much more valuable on the black market.
- dtx1 3y agoI'd certainly try to sell the exploit to someone else instead.
- jjice 3y agoNope, I'm with you. Based on the quick blurb about what the vuln way, $1337 is an absolutely steal for Google. Paying for a team or outside pentesters to attempt to find this would be _way_ more expensive.
- nonethewiser 3y agoIt’s essentially 0 as far as they’re concerned.
- Cthulhu_ 3y ago> Paying for a team or outside pentesters to attempt to find this would be _way_ more expensive. But doesn't Google have teams of internal pentesters already? You could hire dozens of external companies and they might not find it. This system is a "no cure, no pay" approach. I do think they should have paid the reporter a lot more though.
- twisteriffic 3y agoEspecially when Microsoft paid out about 75k for essentially the same issue.
- agwa 3y agoDid Microsoft pay the entire $75k? The people who found that issue reported it to multiple stakeholders, and their blog post[1] merely says they were awarded $75k in total. I assume the bulk of the bounties were paid by the service providers who failed to heed the warning in Microsoft's documentation. Also, the Microsoft issue was far worse as it could be exploited by anyone; the Google issue requires a rogue employee or a misconfigured email ticketing system. [1] https://www.descope.com/blog/post/noauth https://www.descope.com/blog/post/noauth
- twisteriffic 3y agoOn a second read you're probably right about it being multiple vendors paying out.
- thrdbndndn 3y agoFrom a practical perspective, they probably should "match" what black market values these exploits, and I surely wish they can give much higher bounties in general (and they for sure can afford!), but I don't think they ethnically need to (so it's not an insult in my view). Turning these exploits/vulnerabilities to black market is not only immoral but also highly illegal, so the "value" is inflated due to these "risk" factors. You can't really expect the same from the affected company themselves. It's like saying if you found a lost item and you ask a large sum from the owner when you return it, because "I can get much more if I choose to just sell it on the street".
- pcthrowaway 3y ago> Turning these exploits/vulnerabilities to black market is not only immoral but also highly illegal I assumed 'black market' here means irresponsible disclosure, which there are many sites operating legally (Zerodium being a prime example) Who are the customers? Theoretically nation-state actors, but do we really know? Either way, you're selling the vulnerability to a private party. To my knowledge, selling knowledge of an exploit to almost anyone is legal (unless it could be classified treason or a threat to national security or something). As is publishing the security research after responsibly disclosing (as the blog author did here), though we've had to fight pretty hard to get to the point where warning people of threats to their digital safety (often because companies are too lazy to protect their users) is generally understood to be legal.
- thrdbndndn 3y agoI'm not a legal expert, but is it necessary for an act to pose a threat to "national" security for it to be considered illegal in places like the United States? In my country, we have a law known as "The Crime of Destroying Computer Information Systems." This law makes it a criminal offense to intentionally harm computer systems in a way that could compromise them (which is somewhat vague in its definition, I'd admit). This includes leaking private information from these systems, and it applies even if the affected systems belong to private entities. And if you sell exploits to a third party and are later caught, you will be considered an accomplice and there are precedents for this.
- tokai 3y agoCould at least have been $31337.
- sp332 3y agoGoogle hasn't fixed it, so it seems they really don't value this info.
- dpedu 3y agoPer the article, Google fixed it, but only for google.com accounts.
- rahkiin 3y agoMight this be because to be actually vulnerable a company needs to have the ticketing-like system in a sort-of unsafe setup?
- lightedman 3y ago"Is it just me that feels $1337 is an insult?" Y0U 4R3N7 31173 3N0U6H 70 C47CH 7H3 R3F3R3NC3
- agwa 3y agoTo be clear, the information shows a rogue employee how to create accounts in third-party apps (Slack, Zoom, etc.) that won't be automatically deleted when the employee is terminated. I'd love to hear why you think this information would be "much more valuable" than $1337 on the black market as that is not obvious to me. Also, if anyone should be paying bounties, it's the third-party apps, since they're the ones which are vulnerable. I'm impressed Google is paying a bounty just for pointing out a footgun. I would probably not have bothered reporting this to Google if I had found it; $1337 would be more of a pleasant surprise to me than an "insult".
- paxys 3y agoIn fact I'd argue that Google paying a bug bounty for something that is well-defined and documented behavior and will never be "fixed" actually undermines the program.
- dpedu 3y ago> Because these non-Gmail Google accounts aren’t actually a member of the Google organization, they won’t show up in any administrator settings, or user Google lists. That's why. This bug allows an attacker to retain access to various accounts attached to an already-compromised company or employee of the company. Not only that, but the retention is completely invisible to the account administrators. Needing the same level of access that an employee has in order to utilize it doesn't make it less valuable. There are plenty of valuable bugs that can only be utilized from specific positions. Consider how many hacks have happened because an employee's devices or accounts were compromised, rather than some server system that no one individual owns. The recent Okta hack happened that way.
- agwa 3y agoThe rogue accounts would show up in the administrative settings in the third-party apps, and they would stick out like a sore thumb because they'd have weird email addresses. So they're not completely invisible, albeit not visible from one central place. > Needing the same level of access that an employee has in order to utilize it doesn't make it less valuable. The only way that would be true is if compromising an employee account has no cost, which is obviously not the case. Thus, attackers would prefer to purchase a vulnerability that doesn't require also compromising an employee account. I trust tptacek is correct that Zerodium wouldn't even pay $133.70 for this: https://news.ycombinator.com/item?id=38722395 https://news.ycombinator.com/item?id=38722395
- vultour 3y agoBuy why should Google pay them at all? One of the first screenshots of their documentation says you shouldn't trust the email claim, so they're obviously aware of this issue. The problem is third parties using Google's OAuth incorrectly. If anything, Slack/Zoom/etc should be paying.
- toasted-subs 3y agoEh depends on if the person is financially stable. The tongue and cheek number may stand out stronger on a resume.
- LelouBil 3y ago> Following this flow, you can create a Google account using a support ticket email address, potentially view the contents of the ticket to finish the account creation, and start using the support email address to Oauth into stuff. That could impact lots of small companies.
- CaptainOfCoit 3y ago> Today I’m publicizing a Google OAuth vulnerability that allows employees at companies to retain indefinite access to applications like Slack and Zoom, after they’re off-boarded and removed from their company’s Google organization. The vulnerability is easy for a non-technical audience to understand and exploit. > October 5th- Google paid $1337 for the issue Is that a joke? Does Google really value security so low?
- deleted 3y ago[deleted]
- bawolff 3y agoIf i read the post right, the behaviour in question was already mentioned in the docs before they reported this. I'm more surprised they got any money instead of a "its a feature not a bug" response.
- chuckadams 3y agoExactly. They paid for a detailed example they can point to of why one should follow the docs. Lot cheaper than a tech writer.
- deleted 3y ago[deleted]
- dividuum 3y agoWhy is it even possible to create a new Google account with an email like 'user+suffix@domain' if 'user@domain' is already handled by google's mail servers and thus applies the plus-routing rules? Even in the non-exploity case that seems like a great way to create confusing mail setups.
- hypeatei 3y agoI think this aliasing feature is too complex for its own good. Especially at Google's scale.
- paxys 3y agoA domain can freely move between mail servers. Google has a specific handling for a+b@domain.com, other servers might not. At the end of the day they are two unique email addresses, and that's how they should be treated across the internet.
- asylteltine 3y agoBecause of how old and legacy googles authorization system is. A “Google account” is just a string.
- Racing0461 3y ago> user+suffix@domain It's even worse than that. At least the +XYZ is specified in the email rfc. Google has decided even further that periods in the name also go to the cononical email. ie hi.my.name@google.com is equal to himyname@google.com and routes all emails to the second.
- Too 3y agoAnother fun one is upper case vs lower case. I’ve been bitten by systems that are case sensitive, while the rest of the email world mostly is not.
- hudell 3y agoI could swear I at least once received an email that was sent to myname.mydomain@gmail.com or something similar in my myname@mydomain email. It's been several years but I remember thinking that was fucked up and looking into the full email to see if there was any other explanation for me receiving it, which I did not find.
- theK 3y ago> * August 7th - The issue was triaged > * October 5th - Google paid $1337 for the issue Is it just me or does it seem a bit odd that payout after triage took almost two full months? Initially I was positively surprised that they came up with a triage verdict within 2-3 days but what's the deal with the payout coming so late?
- j0hnyl 3y agoNot sure about Google VRP, but I've gotten multiple payouts from Chrome over the years and I believe there's a schedule. The rewards panel meets every x weeks in order to award payouts on qualifying reports. Almost no bug bounty programs pay upon triage by the way, they pay after resolution.
- imroot 3y agoI run a bug bounty program and I pay upon successful triage: while our engineering teams do have security SLA’s, it’s not fair to whomever reported the vulnerability to wait for our (sometimes broken) processes in order to be paid.
- rwmj 3y agoIt's pretty normal for large companies to take ages to pay up. The real problem here is this major bug only elicited a token $1337 payment.
- toasted-subs 3y agoYeah, definitely should have had a higher payout.
- theK 3y ago> The real problem here is this major bug only elicited a token $1337 payment. Agreed.
- paxys 3y agoI work in this space and have dealt with variants of this exact vulnerability 20+ times in the last 3-4 years across a wide range of login providers and SaaS companies. The blog post is correct, but IMO the core problem itself is too far gone to be fixable. Delegated auth across the internet is an absolute mess. I have personally spoken with plenty of Google and Microsoft engineers about this, so I can guarantee they are all already well aware of this class of problems, but changing the behavior now would just break too many existing services and decades-old corporate login implementations. The "fix" at this point is simply – if you are using "Sign in with XYZ" for your site, do not trust whatever email address they send you. Never grant the user any special privileges based on the email domain, and always send a confirmation email from your own side before marking the address as verified in your database. All the major OAuth providers have updated their docs to make this explicit, as the post itself points out. In fact I'm surprised there even was a payout for this.
- tln 3y agoWhy couldn't Google prevent signups using domains of Google Apps customers? That doesn't seem like it would break anything.
- _cenw 3y agobecause the collisions can already exist when someone signs up for google workspace. and what are you going to do, delete those accounts? a lot of those would be personal accounts on educational domains...
- tln 3y agoThat's not a reason to not allow individual signups on @customer.domain AFTER customer.domain is a Google Workspace domain, which is the hole being discussed in the article. FWIW Adobe actually lets businesses take ownership of individual accounts with the same domain... see https://www.adobe.com/legal/terms.html https://www.adobe.com/legal/terms.html section 1.4
- 3y ago
- rowls66 3y agoIs this really a Google OAuth issue, or more failure my many service providers to properly verify the OAuth token assertions before allowing access? Seems to me the latter.
- kr0bat 3y agoIt sounds like the issue is that these service providers are obeying Google's aliasing rules, but also ignoring the fact that you shouldn't be using email as a primary identifier [1]? It's funny, if they had adhered to the spec more they'd be fine; but if they adheredess and treated alias' as distinct emails, these platforms would at least be more secure. [1] https://developers.google.com/identity/openid-connect/openid-connect https://developers.google.com/identity/openid-connect/openid...
- mikea1 3y agoI believe OAuth is working as expected. It provides valid authentication/identity for email addresses because "user@domain" and "user+wildcard@domain" are still validated as email addresses "owned" by the user. The issue is with the Google org website: admins cannot revoke credentials for accounts/emails they cannot see. > Because these non-Gmail Google accounts aren’t actually a member of the Google organization, they won’t show up in any administrator settings, or user Google lists.
- rwmj 3y agoMy main takeaway from this is that web authentication is still a horrible mess.
- c0pium 3y ago…because people don’t read the docs and instead just assume that it works how they think it should.
- asylteltine 3y agoIf so many people are making the same mistakes, it’s your fault, not the users.
- deleted 3y ago[deleted]
- c0pium 3y agoIf people don’t read, it’s their fault. Reading the docs is not a big ask.
- asylteltine 3y agoTypical engineer spotted.
- pests 3y agoHow dare we read documents before we put technology into use. Like asking a bridge engineer to know the spec of his bolts.
- asylteltine 3y agoAnd if every purchaser of said bolts implemented them incorrectly, is it more likely that your specs, docs, or bolt design are faulty? Or do you just think no it’s everyone else who is stupid?
- apitman 3y ago> I remember being surprised to learn that Microsoft would send Email claims that were not created or validated by Microsoft, and that the email claim in general was not considered reliable. > This was counter-intuitive to me, because I had thought the entire purpose of OIDC was to establish reliable identity via a 3rd party like Microsoft. That might have been the original intent, but I find it very useful that OIDC can be more flexible. For example, I run a free login provider[0], and it works by validating an identity with a 4th party identity provider (IdP) either with upstream OIDC or direct email, and creating a privacy screen between the app and that IdP (ie so Google can't track every app you're logging into). The fact that you can bring your own email to Google means you can get the security and UX of Google OIDC with the privacy of email + password, with the huge caveat that now you have to trust LastLogin instead of Google. But we're working on protocols to reduce that dependence. > Google’s documentation in fact warned against using Email as an identifier I completely disagree with Google on this. Email is the only truly federated identity that people actually use. Until we have something better widely deployed (and there are some promising alternatives in the works), I believe email addresses should be treated as identities. [0]: https://lastlogin.io https://lastlogin.io
- throwawaaarrgh 3y ago> I believe email addresses should be treated as identities. Because nobody ever shares an email address, and email is super secure We can wait forever or we can begin building the solution
- apitman 3y agoSharing email identities is a reasonable way to give group access to a resource. And solutions are being built. The mission of LastLogin is to accelerate this.
- caseysoftware 3y ago> I believe email addresses should be treated as identities. No, for two reasons: Outside of the western world, phones are more common than computers and easier UIs in general so a phone number is more likely to be their identity. In addition, that means you're completely handing off your identity to your email provider. Considering many - looking at you google - are faceless organizations that can and will shut down your access without notice or appeal, you could lose everything. Background: I launched Okta's OAuth and OIDC products, put together LinkedIn's courses on the same, and doing it again at Pangea Cyber.
- deleted 3y ago[deleted]
- clintonb 3y agoRelated: More service providers need to stop using email as the primary identifier (as Google’s docs recommend). When I changed my username on Google Apps, I spent a lot of time dealing with issues at Slack, Datadog, GoLinks, and others.
- mattgreenrocks 3y agoWhat should providers be using? I've always presumed email was the most stable global identifier for a user, but that assumption appears to be wrong.
- sirius87 3y agoCurious to hear answers to this too. People forget usernames and that alone would lead to drop off. People are also reluctant to give out phone nos. which is anyway a terrible identifier and has the same issues as email.
- rajasimon 3y agoWhy can't the phone number be unique? I have a unique phone number and trust them as my email unless I transfer myself out of my country.
- JohnFen 3y agoJust like with email addresses, there are a nontrivial number of people who share the same phone number.
- SoftTalker 3y agoPhone numbers are also recycled, probably much more often than email addresses.
- kahnclusions 3y agoAnother edge case is that phone numbers get transferred and reused. I might verify the number, and then stuff happens in the real world while I haven’t logged into your service, and someone new registers with my number. The number is assigned to my account, but the new account can prove they own the number. If you’ve made the number unique, then you need special handling here.
- merb 3y agoWell the best solution is basically to allow the creation of the account but keep it deactivated so that a human needs to check it. That at least works for things like gitlab or other things were an Organisation signs up. The problem of the hd claim is actually not one since you need to validate your domain and if your a saas provider that is b2b only that’s ok. Microsoft is even worst tough, where you need a different claim than email, depending on what you are doing. (UPN)
- superkuh 3y agoA microcosm. There is no such thing as OAuth2. OAuth2 is just a way for megacorps to implement their own arbitrary/proprietary auth systems. It is a toolkit for making auth systems, not an auth system. So we end up in a world where oauth2 was supposed to be a standard, but instead every megacorp has their own incompatible implementation. And sure, people will dev for the megacorp use cases... but that just means the "standard" is now whatever google does/etc. And they all have their own little bugs like this. We should go back to oauth1. It was a real standard. Not a toolkit for making standards.
- kevindamm 3y agoI wouldn't really call this a bug, more like an unfortunate side effect of combining these particular components: domain names that can change ownership, BYO email (as backup email & email provenance), the liberal allowance of plus-aliases (which I'm sure someone somewhere is claiming a business need or they would have killed it long ago), and service implementers not reading the documentation (or largely copying solutions from a video or example with cut corners for brevity/simplicity, likely to facilitate its easy consumption). If I were designing a circuit with a few PCB components and needed to introduce resistors and transistors as appropriate for the voltage and current needs of the device .. would you expect me to read the data sheet or just guess it from a simpler example and run with it? In a lot of cases the circuit would still work, or it would after a few bench tests and a bit of probing. But maybe it wouldn't be as efficient and a component would short out leading to low MTF and sad customers. Worst case scenario maybe combusting batteries and real harm. Now ask yourself, is it really the PCB modules' manufacturers fault that the device fails prematurely? Or is the device manufacturer the one responsible for reading the data sheet? I don't typically hold all software to such rigorous expectations but when it deals with authentication and authorization I would expect service owners to be thorough. TFA even says that the issue doesn't exist if the docs are followed. Alphabet did at least acknowledge there's a weakness there by granting the bounty, maybe they'll provide some controls for company administrators to allowlist/rejectlist plus-aliases or nonexistent roles, or maybe restrict the migration of Apps-affiliated emails to non-org claims? (My guess is they're measuring the impact of this, or prioritizing the measurement of impact, where priority is low because it is a problem with clients that assume email claims are more authoritative and permanent than they actually are). I suppose the definition of "bug" depends a lot on the definition of "expected" and who's expecting, but I would assert it is not a deviation from intended behavior, at least, and not unexpected to those who grokked the docs.
- physicsguy 3y agoThe OIDC spec tells you that you must not to use e-mail as a unique identifier. You must use the 'iss' and 'sub' fields as username in your application. Why? Well, for a start, it's obvious that user e-mail addresses can be re-used. If you've got a contractor working for Business A and Business B, both who create a user account in their authentication service for them, then as a SaaS platform, you can't match their e-mail address to a single B2B customer. Secondly, there's the really obvious thing that e-mail addresses change. Businesses get bought, change name, go through mergers, etc. etc., and people's names change too (marriage, divorce, because they feel like it). I found implementing SSO to be really challenging for a start-up. Getting it correct is hard, and you need to have a good understanding of the general concepts and OIDC and OAuth2 before trying to put it into use. Auth0 have a good book. If you don't understand this, then you'll probably end up doing something like implementing password grant auth everywhere and leave your application insecure.
- k8svet 3y agoSometimes reading articles like these are a good well to alleviate any accumulating imposter syndrome. "Oh, I'm interfacing with a third party system for something that represents an abstract actor. it better have a stable, non-stringy reliable identifier". And yes, the spec is very clear about this, beyond just basic considerations of building a remotely robust system.
- SergeAx 3y agoNot that I am being vain (though I actually am), but how's that my post of the same link 4 days ago got just one upvote? :) https://news.ycombinator.com/item?id=38670644 https://news.ycombinator.com/item?id=38670644
- JohnFen 3y agoWhether or not a link gets any attention here depends on a lot of things aside from the link itself. For instance, if it happens to hit the front page at the same time as something else that is drawing everyone's attention then it may simply go unnoticed. Also, although this isn't the case here, if it's just a link without a description or some sort of commentary explaining why the link is of interest, it may not get the traction you'd expect.
- sam0x17 3y ago> October 5th- Google paid $1337 for the issue love the tongue-and-cheek "leet" amount of 1337
- wizofaus 3y agoAnyone else unable to access what I assume are supposed to links for the centred bits of text throughout that article? I had a hard time understanding parts of it...
- wizofaus 3y agoTurns out, once I got to read it on desktop machine, they weren't links at all but captions for images that weren't showing for me on mobile.
- ok123456 3y agoThis is a feature, not a bug. Anyway, what is to stop someone who owns a domain from doing this with actual forwards to do this sort of ban evasion?
- FergusArgyll 3y agoI may or may have not used a version of this to sign up for multiple free trials - for multiple products. sign up johndoe@gmail.com then next time johndoe+1@gmail.com then +2 ad infinitum
- intrasight 3y agoI use OAuth2 all the time. And I don't understand the conflation of email and OAuth2 being discussed in that article. With Google's OAuth2, I can get the user's email - but so what? I have no need for it and I never use it. "Because these non-Gmail Google accounts aren’t actually a member of the Google organization, they won’t show up in any administrator settings, or user Google lists." I don't understand that statement either. They do show up. Now of course the org could choose to not do anything to manage the access of those users - which is common enough. I made a tool used by some of my larger clients to a) get reports of users and their permissions (available via Google's APIs) and b) batch delete those user permissions.
- VoodooJuJu 3y agoI'm struggling to understand how to reproduce this. I have a Google Workspace organization: org.com I create a new user: sneed@org.com Where/when/how is the sneed+alias@org.com created? How is the user sneed@org.com doing this if they don't have administrative access to organization management?
- uxp8u61q 3y agoJust try it, google will merrily redirect all emails to a+b@org.com to a@org.com. To answer your questions: > Where/when/how is the sneed+alias@org.com created? Where: in gmail's alias list When: at account creation How: gmail/gw redirect everything of the form abc+xyz@domain to abc@domain > How is the user sneed@org.com doing this if they don't have administrative access to organization management? The user isn't doing anything, it's a "feature" of google mail.
- egamirorrim 3y agoWhat am I missing here? Outside of the support system/zendesk and unattended old domain methods identified I can't make a new Google account for whatever@mydomain.com without being asked to verify it - so what's the real likelihood of abuse?
- JeremyNT 3y agoThe idea is that you do this in advance, at a time when you have legitimate access, then you later lose that access. So say you have a egamirorrim@mydomain.com google account legitimately. You can use an alias like egamirorrim+woopsie@mydomain.com to create a new google account with a verified email address, resulting in "log in with google" google sending an email claim egamirorrim+woopsie@mydomain.com. Then, later, mydomain.com fires you. You can no longer log in with the real egamirorrim@mydomain.com associated account, as it was disabled by an administrator. However you can still log into the new google account, egamirorrim+woopsie@mydomain.com , since it's not associated with your organization. The thing is, afaict this then only becomes a problem if the provider is doing authz based exclusively off of the email claim. I've used OIDC in the past and you are not supposed to grant access to resources based on parsing text in email addresses claim! I can understand why the blog post author found this counterintuitive, but as they note the docs even warn against doing this. The blog post goes on to make this statement: > Most of the service providers I tested did not use HD, they used the email claim. ... OK, well what are they "using" it for? Does this trick actually work on any real world services? If so, I would like for them to be named and shamed. Even if you (erroneously) assume this value is unique and immutable, that alone doesn't necessarily grant access to anything in and of itself.
- agrberg 3y agoPerhaps my assumption is faulty. If an email is sent to egamirorrim+woopsie@mydomain.com it would go to egamirorrim@mydomain.com which you no longer have access to. Do you simply never again need to receive an email at egamirorrim+woopsie@mydomain.com?
- AtNightWeCode 3y agoUsing emails like this is usually found during pen tests. Not Googles fault I would say even though I think OAuth is overly complicated. This is along the line of sending secrets in the token. Tokens are signed, not encrypted.
- deleted 3y ago[deleted]
- theteapot 3y agoWhat's the actual vulnerability? Steps to reproduce?