Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bypass socks proxy configuration on iphone

I am trying to reverse engineer the whatsapp protocol. I tried to use Charles Proxy (i imported the charles proxy cert).

The problem is I only see one request (the one whatsapp uses to get all contacts which are using whatsapp). All other communication is invisible to me.

I use charles as SOCKS proxy ( http://snipplr.com/view/16563/how-to-connect-to-a-socks-proxy-from-an-unjailbroken-iphoneipod-touch/ ).

How does whatsapp bypass the iPhone proxy settings? I thought all SDK classes should respect these settings.

like image 532
Alexander Theißen Avatar asked Jan 30 '12 19:01

Alexander Theißen


1 Answers

Whatsapp protocol isn't really implementing ssl. It only use port 443 to pass proxies. All of the data passes including msgs and contacts are in plain text for everyone to see.

To sniff the data:

You can create an ad-hoc wireless hotspot on your computer (make sure it's connected to the internet using an ethernet cable otherwise u'll be offline) connect to that network from ur iphone, on ur computer start any packet sniffer (I personally use wireshark) and filter tcp port 443. viola, you'll get both requests and response from the whatsapp servers without intercepting the data.

To intercept the data:

Never done this but I think you can just use iPhone settings (settings->general->network->vpn->add vpn configuration->proxy settings(manual)) to proxy all of the network under port 443 to a server u own there u'll need to run a proprietary program that handles the requests and sends them (handled) to whatsapp servers.

About the data:

From what I recall some of the data inside the protocol is encoded (substitutions/base64/other basic encodings).

About your question regarding proxy passing I hope my answer about how to sniff will solve your problem.

like image 77
Uri May Avatar answered Oct 15 '22 05:10

Uri May