Saturday, December 22, 2007

A Quick Update on Configuring proxy server settings for edge on your Iphone [OBSOLETE]

Please Note: This is an old post, now you can configure airtel live automatically by adding my source www.kansara.in/installer.xml to your installer sources, for more info go here [Update: 31/03/2008]

This is in reference to my earlier post regarding configuring 'Airtel Live on your Iphone'. I would just like to inform people that this is a universal solution, you just have to put in your proxy server and port address in the proxy.pac file. Even if you are in a network in Australia or Singapore or Hong Kong or any place that requires you to set up a proxy server to configure edge on your phone, this solution should work for you.

One more tip - All those who are not interested in going through the tedious method of installing OpenSSh on the iphone and then installing WinSCP on their windows pc to access the iphone's file system, can now install Samba File server from the BigBoss repository, "BigBoss's Apps and things". Just add this source in your installer, http://sleepers.net/~iphone/repo.xml . For instruction on how to configure your iphone and computer to access the iphone's file system with the samba server goto this page http://signalblue.com/iphone/

Note: This Solution requires wifi on your comp and will also require you to setup an ad-hoc(peer-to-peer) connection between your iphone and your comp.

After you to set up the samba server, place the proxy.pac file at this location: \\192.168.1.200\Root\var\root and the preferences.plist file to this location: \\192.168.1.200\Root\var\root\Library\Preferences\SystemConfiguration. Don't forget to backup your original preferences.plist file.

This should also get your Edge network to work on the Iphone.

Take Care All

P.S. If you need the proxy.pac file and the preferences.plist file just leave me a comment and your email address, i'd be more than happy to email it to you.

As soon as you get the files, just edit the proxy.pac file as per your requirement by following the instructions in this post and paste the preferences.plist file to the specified location, no need to edit it as I'll send you the edited file, :)

Tuesday, December 18, 2007

Get Airtel Live working on your Iphone [OBSOLETE]

Please Note: This is an old post, now you can configure airtel live automatically by adding my source www.kansara.in/installer.xml to your installer sources, for more info go here [Update: 31/03/2008]
Okay guys, here I would list out as to how to get airtel live working on your Iphone.
I myself learnt to configure this from http://arashpayan.com/blog/index.php/category/technology/, so all credit goes to the author of this page.

Things required:
1. Jailbroken unlocked iphone, :)
2. OpenSSH installed on Iphone(as you will have to access the filesystem)
3. NetServices installed on you iphone(from installer source http://homepage.mac.com/hartsteins/copycoders/copycoders.xml , though Services App will also do, if it is the latest one and displays your IP address)
3. WINSCP installed on your PC
4. A good text editor(though wordpad will do).

Now we begin,

1. Open wordpad and paste the code below:

function FindProxyForURL(url, host)
{
if (isInNet(myIpAddress(), "10.0.0.0", "255.0.0.0"))
return "PROXY 100.1.200.99:8080";
else
return "DIRECT";
}

Note in the above block of text that the proxy used by airtel is 100.1.200.99 and the port is 8080, so in this place if hutch(vodafone now) or bsnl or Idea users insert their proxy and port address, things should be fine with them too.

2. Save the file as proxy.pac and save it on your pc. Make sure you save it as proxy.pac and not as proxy.pac.txt or proxy.pac.rtf.

3. SSH to your Iphone and goto the location /private/root/ and paste the file proxy.pac to this location.

4. Now on your phone goto the location /private/var/root/Library/Preferences/SystemConfiguration/ , here you will find a file preferences.plist, copy this file to your PC.

5.Now, open the file in your text editor(i recommend if you use Windows XP, instead of opening in notepad, open it in wordpad, as in notepad the tabs and indentations in the file are not that convenient to see and edit), and search in the file for this code:

<key>DeviceName</key>
<string>ip1<string>


Please Note: The file has multiple instances of "DeviceName", so make sure you just locate the place where "DeviceName" is succeeded by "ip1" and not by something like ip2 or en0.

6. okay now the code around the place where you located the above lines is somewhat like this

           <key>Interface</key>
<dict>
<key>DeviceName</key>
<string>ip1</string>
<key>Hardware</key>
<string>com.apple.CommCenter</string>
<key>Type</key>
<string>com.apple.CommCenter</string>
</dict>
<key>com.apple.CommCenter</key>
<dict>
<key>AllowNetworkAccess</key>
<integer>1</integer>
<key>Available</key>
<integer>1</integer>
<key>Setup</key>

7. We will place our text in between this block of code like this(the text in red is the code you have to insert)

           <key>Interface</key>
<dict>
<key>DeviceName</key>
<string>ip1</string>
<key>Hardware</key>
<string>com.apple.CommCenter</string>
<key>Type</key>
<string>com.apple.CommCenter</string>
</dict>
<key>Proxies</key>
<dict>
<key>ProxyAutoConfigEnable</key>
<integer>1</integer>
<key>ProxyAutoConfigURLString</key>
<string>file:///private/var/root/proxy.pac</string>
</dict>
<key>com.apple.CommCenter</key>
<dict>
<key>AllowNetworkAccess</key>
<integer>1</integer>
<key>Available</key>
<integer>1</integer>
<key>Setup</key>

Please Note: Please make sure that when adding this code you maintain all the indentation in the file and provide proper tabbing as above and do not disturb the original indentation of the file.

8. Save the file.

9. SSH again to your phone and go again to the location /private/var/root/Library/Preferences/SystemConfiguration/ , rename the original preferences.plist to preferences.plist.original and upload the file you edited on the PC to this location.

10. Close the SSH connection, turn off SSH on phone too.

11. On your Iphone goto Settings-->General-->Network-->Edge. In this window fill airtelfun.com as your apn, leave username and password blank.

12. Come to home screen, switch off the iphone by pressing the power button for five seconds and then slide to power off. Switch it on again.

13. Now open NetServices to make sure Edge is turned on while Wifi is off. Close NetServices.

14. Open safari and open the page live.airtelworld.com and let it load for sometime. It normally does not open for the very first time you load it.

15. Close Safari, Open NetServices again, if at the bottom it displays your ip address as something like 10.x.x.x, congrats, you can now use airtel live to browse the web.

16. Again open Safari and reload live.airtelwolrd.com or maybe www.google.com or any other site, :).



A few Points to take care of:
1. If you have any doubts, please drop in a line in the comments section.
2. Do not mess up the preferences.plist file, do exactly as listed above, if you fail to paste it properly in the correct location, the phone might need to be restored, if you have any doubts or require the proxy.pac file and preferences.plist file, post your email in comments, I will email you both files that I have edited and are working fine on my 1.1.1 Iphone.

Take Care All