TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Facebook detects if you are logged in Gmail

268 pointsby phwdover 13 years ago

15 comments

raganwaldover 13 years ago
Not sure how they are doing this, but I have gotten tired of having to play “whack-a-mole” with FB scraping private information from my browser in other ways, so what I have done is sandboxed it: I have a separate “Facebook” account on OS X, and I assume that anything I do on that account is shared with Facebook.<p>I don’t log into Facebook for any reason on my normal user account, and I don’t log into anything else on my Facebook account. They can still sniff certain things using browser fingerprinting and so on, but this seems like the best I can do for the moment on my desktop.
评论 #3201537 未加载
评论 #3202544 未加载
评论 #3201503 未加载
评论 #3202338 未加载
评论 #3201362 未加载
评论 #3201482 未加载
评论 #3204385 未加载
评论 #3201510 未加载
评论 #3201998 未加载
评论 #3201718 未加载
评论 #3202158 未加载
评论 #3201828 未加载
评论 #3202411 未加载
评论 #3203465 未加载
the_mitsuhikoover 13 years ago
It's not very hard to do. The trick is to know a resource that only the user can access and then trigger an HTTP request to it.<p>For instance if you have website a and say the user profile "mitsuhiko" can only be edited when you are logged in as "mitsuhiko" on <a href="http://a.example.com/profile/edit/mitsuhiko" rel="nofollow">http://a.example.com/profile/edit/mitsuhiko</a> you could use this code to see if the logged in user is "mitsuhiko":<p><pre><code> &#60;script type="text/javascript" src="http://a.example.com/profile/edit/mitsuhiko" onload="user_is_logged_in()" onerror="user_is_logged_out()" async="async"&#62;&#60;/script&#62; </code></pre> Why does this work? Because onload is fired if the resource answers with 200 OK, not if it's a valid script. onerror is called for any other error code.<p>So if you know what you are probing for: easy.<p>// Edit: Yes, this is most likely not what Facebook is doing if that's their only method of security. However see my reply to the first comment here about the security aspect for a possible way to solve this problem.
评论 #3201281 未加载
评论 #3202760 未加载
评论 #3201290 未加载
评论 #3201300 未加载
评论 #3201286 未加载
antimatter15over 13 years ago
When I tried the same thing, it popped up a OpenID dialog the first time, and I confirmed it by seeing facebook.com on <a href="https://accounts.google.com/b/0/IssuedAuthSubTokens" rel="nofollow">https://accounts.google.com/b/0/IssuedAuthSubTokens</a> Revoking the facebook token causes Facebook to prompt again.<p>Subsequent attempts make the auth dialog flash briefly without displaying any content and still present the "You can change your password immediately because you are logged into your email account on this browser" message.
irrumatorover 13 years ago
That's pretty neat, I wish they'd publish on how they did this so others could use it. Sounds like another great way to remove friction for the user, always a great thing.
评论 #3201777 未加载
评论 #3201270 未加载
评论 #3201277 未加载
nikcubover 13 years ago
It must be using oAuth. I think it was a mistake in the oAuth protocol to not build in a default, short, expiration for secret keys. Now users (most of them non-tech savvy) have to rely on visiting the apps page and manually removing authorizations.<p>Edit: I just profiled the process, and it is using OpenID. It pops open a new window that will check your OpenID login and call back with a success and will close the window if it is. I had to slow down my connection to actually see it.
nchuhoaiover 13 years ago
I think they should have used that information differently. Given they know that you are already logged into your gmail, any visitor to your machine will therefore know how to reset the password to his advantage.<p>Instead, they should have make a block, so that you are forced to logout of your gmail and login to your gmail to enhance security.
评论 #3201390 未加载
jvandenbroeckover 13 years ago
So Facebook uses oauth to login with google, I don't get why this is worth 114 points..
评论 #3201743 未加载
dylangs1030over 13 years ago
Question...has anyone noticed if this relationship is reciprocal? I keep an eye on my Gmail ads to see how far along they track my activity while I am logged in and browsing, but has anyone noticed Gmail ads showing content that wouldn't be there without placement or data from Facebook? Obviously this doesn't apply if you sandbox Facebook as some commenters have, but if you use both in one browser I mean. I may use Firebug and see if the two communicate while I'm logged in...
zecgover 13 years ago
This is really handy: <a href="http://disconnect.me/" rel="nofollow">http://disconnect.me/</a>
Canadaover 13 years ago
This is why facebook never gets on my noscript whitelist, why I only use it in a private browsing session and why I hardly ever login.
jarinover 13 years ago
I ran into that the other day, and was pleasantly surprised. This is how interconnectivity is supposed to work.
评论 #3202351 未加载
zerostar07over 13 years ago
I ve seen this screen, but it only comes up after you give facebook Oauth access to your Gmail.
MartinMondover 13 years ago
I bought <a href="http://fluidapp.com/" rel="nofollow">http://fluidapp.com/</a> just for Facebook.<p>Now I have a nice separate window for browsing Facebook and nothing but Facebook.<p>Separate cookie store is awesome.
评论 #3202680 未加载
评论 #3201794 未加载
评论 #3201813 未加载
whackberryover 13 years ago
Facebook is amateur when compared to Google
res0nat0rover 13 years ago
Another day, another post up in arms about Facebook privacy. This is getting old.