Live data from Hacker News

A Facebook Sixth Sense

kirszenberg.com

61–70 of 84 posts

Re: A Facebook Sixth Sense

#61
post #12
post #7

Fascinating article, and thanks for taking the time to research it and write up the results. This kind of thing makes me think that Facebook et al will eventually push for a way of having closed source client-side scripting.

Good for us that there is no such thing as closed source client side logic in web applications (without installing extensions/plugins). You can only obfuscate.

How exactly is that different from non-web applications?

If you have the binary, you can reverse-engineer it.

Re: A Facebook Sixth Sense

#62

Earlier quoted context omitted.

Facebook users are apparently broadcasting the fact that they are typing to their conversation partners, why should you ignore that information? If you don't like that, disable that feature, or complain to Facebook if it is not something you can disable yourself (or don't use Facebook). It can't hurt to raise some awareness of what you are invisibly broadcasting in terms of data on-line. (I always liked how this feat…

I suppose it would be even easier to make a script that blocks facebook from sending this information? Does it already exist?

There's one called Facebook Unseen that works well. It's a Chrome extension that gives you a toggle.

Re: A Facebook Sixth Sense

#63
post #59
post #56

Neat tool! Are you able to make it record who/when for when the notification occurs but no message follows? It'd turn it from neat to useful imo.

That's a great suggestion! If you'd like to see this implemented, please open an issue. https://github.com/Morhaus/facebook-sixth-sense/issues

Glad you think so. Done!

Re: A Facebook Sixth Sense

#64

A somehow similar hack I want to do when I have the time: When you have a WhatsApp Web tab opened, it keeps a socket connection opened that gives you information such as your phone battery level. I really want an icon on the Chrome toolbar showing me that charge level.

You can install owntracks (http://owntracks.org/) on your phone, and configure it to publish the battery level (as well as your location) to an mqtt broker.

Re: A Facebook Sixth Sense

#66
The article is great and I enjoyed it. It gives good insight into React and inspecting minified web apps, however I'd like to point out two other ways you could go about it.

Sometimes you can't get inside the application, because the JavaScript is scoped in such a way that nothing leaks out. In those cases you can make an extension that runs before any script on the page, and hijacks native JS such as XMLHttpRequest or WebSocket.

In other words, declare your own WebSocket, and pass everything through to the real one, while intercepting any data you're interested in.

Also for this specific case, you could use Chrome's built-in API for extensions to intercept requests.[1]

As a benefit in some cases these methods can be less prone to breaking changes in the web app, but the opposite can also be true.

[1] https://developer.chrome.com/extensions/webRequest

Re: A Facebook Sixth Sense

#68

Earlier quoted context omitted.

is this really a contrarian opinion? i feel like this is a pretty obvious fact that it's easier to read network requests to scrape a website than parsing html

I'm not sure why, but many scraping tools handle javascript websites by emulating clicks and running the javascript.

I think the idea is that clicking on the button is less likely to change suddenly than whatever protocol they're running on top of AJAX.

In my experience internal layout changes seem to happen way more often than changes to the AJAX handlers.

Re: A Facebook Sixth Sense

#69

So, as a code example, fine---but I'd caution against actually using this with your friends unless you know they're okay with it. They will be acting under certain social expectations with regard to when and how people can see their typing notifications based on when and how they were able to see them before, and if you tweak your way into getting more access without your conversation partners knowing it beforehand,…

This reminds me of how people get arrested for pointing out security flaws in important systems, trying to help. Let's don't shoot the messenger.

Re: A Facebook Sixth Sense

#70
post #66

The article is great and I enjoyed it. It gives good insight into React and inspecting minified web apps, however I'd like to point out two other ways you could go about it. Sometimes you can't get inside the application, because the JavaScript is scoped in such a way that nothing leaks out. In those cases you can make an extension that runs before any script on the page, and hijacks native JS such as XMLHttpRequest…

Thanks for the extension. To quickly see what's going on you can also just monkey patch the native functions right in the console.
Post reply on HN