Sunday, March 08, 2009

Using Vodafone Live! on your computer

=== The specific services I talk about here, are applicable only to India; but the concepts apply to anywhere in the world ===

This post is the continuation of my previous post on sharing your mobile's GPRS/EDGE connection on a computer.

Vodafone Live! and other similar services (Airtel Live!?) do not allow the use of the mobile's internet service on a computer. Generally these types of services are called as WAP Internet package (or something similar, but with a WAP tag in there description).

There are two restrictions that are common here:

1. They cannot reach any of the Internet servers "directly". ie., you need to always connect through a proxy server which supports most common protocols. This provides the service provider an easier management to restrict the users from accessing certain services that are not allowed under this package (something like VoIP?)

Solution: This is a straight-forward solution. Once you share the connection with your computer as I explained in my earlier post, you need to configure your browser to use your service-provider's proxy server at the right port (you should have used this info already to configure Internet connection in your mobile phone). You can try ping'ing the proxy server from a command prompt on your computer and you should see replies. You can also notice clearly that you will not be able to ping any other webservers/public IP other than your service provider's proxy server -- clearly indicating the idea behind the use of proxy server.

2. They do not allow any device other than a mobile to use the Internet service. This infact is difficult to ascertain. This is because of the lack of support in the underlying protocols. Most protocols do not carry (actually they aren't meant to) the user related information. The only information that the service provider is able to rely on is the user-agent attribute in the HTTP header in every HTTP request. The idea behind this attribute was to allow the webservers to format the output based on the user's device profile so it can fit well on the user's device. Generally the user-agent information carries the browser's name, operating system information. Given that most of our requests are going to be HTTP(S) based (while browsing), this is enough for the service provider to restrict the use of internet on the computer.

Solution: With a few experiments with wget, I could figure out that the user-agent indeed was used to restrict the usage. wget was able to retrieve the pages successfully on my computer while sharing my Vodafone Live! connection from my mobile. With wget configured to use the user-agent as-is that firefox 3.0 uses, I could get 'access denied' even when requested from wget. After playing around a while with various user-agents I finally figured out that it was indeed the OS part of the user-agent that they care and not the browser itself. Even though Firefox 3.0 does not exist on a mobile platform (yet!), they do allow the use of firefox 3.0 in the user-agent if I make sure I tweak the OS part of it. That having proven the concept now, how do we make the browsers work with the phone; after all wget cannot be used to browse. Thankfully, the great Firefox supports a config variable that allows the user to override the user-agent (I'm not sure about other browsers; I'm fairly confident MS Internet Explorer does not support). To configure, just type 'about:config' in the firefox browser URL and add a new String config variable with the name 'general.useragent.override' (this does not exist already) and set its value to whatever you want (basically it should be devoid of Windows NT etc.,) and you are all set. Just start browsing (don't forget to set your proxy server appropriately if required).

It should look something like this:


I would suggset not to leave the user-agent with an arbitrary value all the time. When you are not accessing Internet over your phone, delete (Reset) that config variable so that the actual user-agent is sent.

6 comments:

  1. wow... you've done quite an research on that :-)

    ReplyDelete
  2. Awesome work buddy

    ReplyDelete
  3. great ............


    more detailed version pl..........

    ReplyDelete
  4. Hi,

    Worked like a dream..Awesome :)

    Is there a way to make my windows mobile which uses a normal GPRS connection into a wifi hub?

    Thanks,
    GP

    ReplyDelete
  5. Thanks.

    No, WinMo can't become a wifi acess-point. That's a very useful feature though -- I use my Android phone as Wifi AP many times on travel.

    ReplyDelete