Closed
Bug 795175
Opened 14 years ago
Closed 14 years ago
measure impact of bug 793579 on users
Categories
(Cloud Services :: Server: Identity, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: warner, Unassigned)
Details
The security fix in 793579 was discovered by our own rfkelly. We should confirm that nobody exploited this before we were able to fix it.
The goal is to figure out if we need to publish a full disclosure message in the next few days (asking users to take some immediate action), or if we just explain the bug and the fix in a couple of weeks.
I don't think we record enough information to be confident, but as Ben pointed out, we could at least look at the database and see which records are marked as being "primary" addresses (meaning addresses which were added based upon a primary-backed assertion). Ryan's exploit involved adding an illegitimate address with this API, then taking advantage of secondary-backed assertions for that address to obtain power on RPs. I think his exploit could also be used to take over primary-backed addresses (thanks to the 2nd and 3rd bugs mentioned in that ticket).
There are very few primaries right now, mostly demonstration sites that we've built ourselves, so a real exploit would probably use normal non-primary addresses. So if we make a list of all the "primary"-flagged addresses in the database, and see if that includes gmail or hotmail or non-demonstration domains, that would indicate this bug was being exploited. If we only see eyedee.me and mockmyid.com, then maybe we're ok.
Maybe a query like this? (apologies for my lack of SQL fluency):
SELECT address FROM email WHERE type == primary
and then pipe into an s/^.+@// and sort/uniq the result? We throw out all the mockmyid.coms, we maybe think about the eyedee.mes, and we study carefully everything else?
| Reporter | ||
Comment 1•14 years ago
|
||
I talked with Ben.. it sounds like getting a list of "primary"-flagged email addresses would be enough to check for anything unusual. The emails are personal data: let's *not* attach them to this bug. So (gene or atoll), please:
1: take the output of a "SELECT `address` FROM `email` WHERE `type` = `primary`" on the production database, pipe through sort|uniq
2: call me over to your desk and let me page through the output
If we only see known primaries in the list (mockmyid, eyedee.me, the demos that callahad and rfkelly set up), then we're ok, and we can probably open up bug 793579. If we see any "real" IdPs in there (gmail, etc) then someone was actively exploiting this hole before we closed it, and we'd have more work left to do.
Comment 2•14 years ago
|
||
Here's my command and I have output :
mysql -e "SELECT address FROM email WHERE type = 'primary'" browserid | awk -F @ '{print $2}' | sort | uniq -c | sort -rn
Comment 3•14 years ago
|
||
Brian and I looked over this and concluded that there nobody outside of those on this ticket have exploited the bug
Updated•14 years ago
|
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
| Reporter | ||
Comment 4•14 years ago
|
||
Gene's query above gave us a list of primary-flagged addresses. We skimmed through them and concluded that everything on the list was either a known primary (eyedee.me, mockmyid) or a test site (personatest.org, etc). There were no glaring victim accounts (nothing on gmail or well-known email providers), and we manually checked for .well-known/browserid on the handful of questionable ones and found that they *were* running primaries.
We also did a:
SELECT * FROM user,email WHERE email.user=user.id AND type="primary" AND user.passwd IS NOT NULL
then we stripped out the eyedee.me and mockmyid entries, leaving three addresses, all of which are running primaries (two by known developers).
Since the known attack requires adding a primary-type address to an attacker-controlled account that *does* have a password set (so the attacker can use /wsapi/cert_key to get an assertion for that address), this query would show all the accounts that could have been used in the attack. To be exploited, the email.address field would need to point to a victim's address on a non-primary IdP. And since all of those addresses point to a primary IdP, it seems that there are no exploited accounts.
An account could have been deleted after being used for an exploit: we'd have no record of it. Now that the main bug is fixed, such an attacker would no longer be able to get assertions for the RP.
Updated•13 years ago
|
Group: mozilla-services-security
You need to log in
before you can comment on or make changes to this bug.
Description
•