Posts Tagged network

iPhone 3G Connection Tethering without Jailbreak

iPhone tethering consists of using your iPhone as a modem with your laptop or iPad to provide wireless connectivity through your 3G data connection.

Tethering is authorized by Apple as long as your carrier does authorize it as well.  And, most of the times, the providers do charge a special rate for tethered data traffic.

If you have a subscription to an unsupported carrier, you’re locked.  Other mobile phone systems have more open options.

To work around this limitation imposed by Apple and the carriers, the most common solution is to Jailbreak the iPhone, allowing to install non Apple approved applications through Cydia.

I don’t like to jailbreak my phone.  It is a cat and mouse game, each time Apple does release a new version, the jailbreak is broken and we have to wait for a new jailbreak solution.

Although it does exist some tethering without jailbreak solutions, I never found one as clever and obvious as iProxy.

First a disclaimer : iProxy does require Apple developer tools and a developer profile (or to know someone that has one).  It is not a solution for every user and certainly not for my grand’ma !

The ideas behind iProxy are so simple, I am jealous.  I wish I had these ideas myself.

First, the application is distributed as source code only.  It is an XCode project that you must compile and install on your phone.  Installing the binary on your (not jailbroked) phone requires to subscribe to Apple’s developer program.

This allows to circumvent Apple’s review process required to publish application on the App Store.

Secondly, iProxy is not a tethering solution, it is “just” a generic SOCKS v5 proxy, allowing to relay traffic between SOCKS clients (your laptop or iPad) and the Internet.

iProxy developers did not write the SOCK code themselves, they smartly reuse the code of SRelay, an open source, UNIX-based, generic SOCKS proxy (iOS is a UNIX OS, remember !)

They even include a small embedded and open-source HTTP server, to be able to provide proxy auto configuration files (PAC files) over HTTP.

Once compiled and installed on your iPhone :

  • On your laptop, create a private wifi network
  • assign a static IP address on your laptop
  • define a SOCKS proxy with the iPhone’s IP Address (see below) and the port 8888
  • On your iPhone, join the wifi network
  • Assign a static IP address in the same range as the laptop
  • start iProxy application

Should you try this with an iPad, you will realize there is no possibility to define a SOCKS proxy on the iPad.  This is where the Proxy Auto Configuration file (PAC file) and embedded HTTP server comes at hand.  In your iPad Network Settings, define the following line as “Auto Proxy Configuration”

http://<your iphone IP address>:8080

Mobile Safari will read this file.  It contains a simple JavaScript function that defines the SOCKS proxy with iPhone’s IP address and port number.

This is it.  This solution is not too complicate to setup and use (for technical users), it makes a very clever use of open source and it is pretty efficient !

, , , ,