Friday, April 4, 2008

Iphone/Ipod Hacking

After a demonstration of the sheer utility of the IPod touch, AP has taken on the task of trying to convince NIH that an IPhone is really just a pocket pc and is, therefore, as much a work related expense as a laptop. I don't know if this will fly, but if you just list the features of a hacked Iphone, leaving out the phone part, it certainly does sound like an efficiency enhancing device. I certainly feel that way about my new life partner, SuperFunky. He keeps me on time for appointments, up to date with new issues of my favorite journals, helps me review papers on the airplane, check my email and the progress of jobs running on the cluster. Not only that, but like me he looks good in leather.

Anyway, in response to a few requests, i am posting the procedure which i followed to get you and your iphone into a state of sheer mobile computing bliss:

Step 1: Prep
Update Itunes to the latest version.
Plug in Iphone and update it to the latest version (1.1.4)
Exit Itunes

Step 2: Jailbreak and Unlock
Download ziphone
Run the Program, Follow the instructions (This should only involve one mouse click).

Iphone Step 3: Unlock Iphone
Power off Iphone by holding top and bottom buttons until slider appears...
Use paperclip to pop out sim card
Put in sim card of choice.
Turn on Iphone with top button
Use Iphone to call your friends to boast of your accomplishments.

Ipod Touch Step 3: Install IPhone Apps
Start Installer: Click Install at bottom. Scroll down to iPhone 1.1.4 Applications and select it. Select iPhone 1.1.4 Apps. Then click install in the upper right hand corner. ****You may need to install the community sources and big boss's recommended.

Step 4: Installing Terminal app
Now the fun part. Most of the applications you would like to install can be found through the install app icon which ziphone provided (its the blue one). The problem is that not all of them work and not all of them work together very well. I have traced most of the problems i have had to ownership and file permission issues, which likely result from Apple's creation of a secondary user called "mobile" which does not have root access. Fortunately, straight foreward use of the terminal app (or ssh) can remedy these issues. Ziphone installed ssh, but the terminal app is something you must do yourself. The terminal app in Installer seems to be broken, but a second installer app, Cydia, has one which works just fine. So first we will install Cydia. Here are steps.

(0) First goto Click on the "Settings" Icon. Select "General" then set "Auto-lock" to "Never"
(1) Open Installer App. Click on "Sources" in lower right corner, then "Edit" in the upper right, then "Add" in the upper left. Enter the url: http://apptapp.saurik.com/
(2) After the sources are refreshed. Click "Install". Under the "System" Menu, you should find "Cydia Packager". Select Cydia and then click "Install" in the upper right.
(3) Once its completed, exit the installer. A new icon labeled cydia should have appeared. Click on it. Select "Install" and then "All Packages". Scroll down to "MobileTerminal" and then select it and then press "Install" in the upper right.
(4) While your here i would suggest also installing "lighttpd", "BossPrefs", "BossPrefs Lighttpd..", "BossPrefs Safari DL...", "1.1.3/4 Safari Patch", "Python" and, of course, "PuzzleManiak"

Step 4: Fixing broken stuff.
As mentioned there are a few bugs associated with bad file permission stuff which are relatively easy to fix now that you have the terminal app up and running. So reboot your iphone and then start the terminal app. Then execute the following commands:
mkdir Media/Downloads
su
alpine
cd
rmdir Media
ln -s /var/mobile/Media /var/root/Media
ln -s /var/mobile/Media/Downloads /var/root/Downloads
ln -s /var/mobile/Media /var/root/Sites/Media
chmod -R og+rx .
cd /var/mobile
chown -R mobile .
chmod -R og+rx .
exit

Step 5: Installing more stuff with Installer.
Start up installer, hit install at bottom. Scroll down to "Sources" and install "community sources" and "Bigboss's Recommended...". Then install:
Under "Copy Coders" install "1.l1.2 - Download Plugin".
Under "Development" install "PHP",
Under "Productivity" install "Lockbox" and "MobileToDoList2"
Under "Toys" install "Flashlight"
Under "Tweaks" install "PDF/DOC/XLS viewer", "Weather Icon Fix"
Under "Multimedia" install "PocketTcouch" and "SendSong (ver 0.31)", "Pocket Touch"
Under "Utilities" install "DropCopy (ver.0.461)" and "Sendfile (ver.0.37)

Step 6: To navagate your media files using safari open up "bossprefs" turn SafariDL to OFF and Lighttpd to ON. Then open up safari and open up http://127.0.0.1 You should be able to view any files that safari can view including pdf's and doc's. Most of the other programs are relatively self explanatory. The flashlight is particularly useful, as in drop copy. Also, since ssh is installed, a program like WinSCP can be used to easily transfer files to and from the iphone via its wireless connection. The ip address of the phone can be obtained from the bossprefs windows. Also, when surfing the web you can download some files (mostly media files) by turning ON bossprefs safari download option. Clicking on media files will cause them to be downloaded to the Media/Downloads directory.

Step 7: Install simplify mobile media which is under Multimedia in the installer. This app will allow you to stream media from your pc to your iphone wherever you are. When this first came out the poor interface made it useless so I was using the web-based mycast.orb.com solution. Now Simplify Media has a very nice interface. Install it on your phone, then download and install the server software on your pc. It's found here. Create an account (share it with me!) and we're off.

Also here is a workaround for copy and paste. Its not exactly elegant but it works in a pinch.

No comments: