[Windows RT General] ocsrubik:
Dear Admins, sorry for posting this here. I only have 3 posts and could not post at http://xdaforums.com/forumdisplay.php?f=2130.

I hope you can help to move this thread there, took me some time to research this and then type all this out.

High-speed Non-photo Large File Transfers between iDevices to Surface RT via USB (without WIFI/3G/Bluetooth/iTunnel/USB Tunnel/openSSH)

As you know, iDevices do not like to communicate with anything that is not:

1. Another iDevice

2. Windows (limited only to read-only camera photos, subject to successful Apple driver installation)

3. iTunes (PC/Mac)

There are more options for jailbroken iDevices with Windows, e.g. Bluetooth (Airblue sharing), WIFI (OpenSSH + SSH Client), USB (iFunbox, iTunnel, Usbmuxd, iTunes). But now, with Windows RT and its ARM architecture, there are even more restrictions than Windows, e.g. no iTunnel, no usbmuxd, no iFunbox, no iTunes.

Just a preamble, all these would not have been possible without the great work of the iPhone jailbreaking community, and the excellent work with the Surface RT jailbreaking community. My main aim of developing this method is to allow large file transfers from iPhone to Surface RT without Wifi/3G or Bluetooth (too slow) and purely via a USB cable. Just hope that my little tutorial can contribute somehow to the pool of knowledge out there.

Let me first list out the ways that I can think of that iDevices can communicate with Surface RT and the pros and cons, before presenting my preferred method last.

1. Adapters

- Method: Use an lightning to microSD adapter to connect to iDevices, then transfer the file via iFile, then plug the microSD into Surface

- Pros: Easy, pretty straightforward

- Cons: Need to bring adapter around, sometimes the mounting fails or the file transfer gets interrupted halfway

- Conclusion: Good if you carry the adapter around

2. Bluetooth

- iDevices’ native Bluetooth stack does not communicate with non-iDevices, including bluetooth enabled Surface RTs, Android tablets

- Method: Download AirBlue Sharing from Cydia. Enable “Receive file” under Bluetooth icon at the task bar of Surface RT. Then receive files.

- Pros: Easiest

- Cons: May need to pay for AirBlue Sharing. Bluetooth file transfer is slow! Sometimes I get speeds at 10-50kb/s. (Not sure if it is due to the location of the file within the iPhone, the Surface RT bluetooth hardware or the iPhone bluetooth hardware

- Conclusion: Good if you are transferring small files e.g. text files, photos, videos < 5 MB

3. OpenSSH, then Putty for Surface RT

- Works via WIFI

- Pros: Fast, relatively convenient, good if you are intending to use VNC as well

- Cons: Does not work if you are not connected to the same wifi network, e.g. if you are at an airport trying to transfer files from iPhone to Surface RT. Potential security risk (always change the alpine password)

- I tried creating a USB tunnel using iTunnel-mux/usbmuxd (Python script hung) – maybe others may have better luck (please let me know)

- iFunbox/Make-iTunnel does not work on ARM architecture, not recompiled for ARM

4. Transfer via cloud computing

- Method: Use skydrive/rainbow drive/google drive/etc.

- Pros: Convenient, Easy

- Cons: Need to be connected to internet, incurring cost, if you are travelling.

5. Transfer via Windows masquerading as a JPG file! :)

- Background: instead of trying so hard to create my own USB tunnel, I decided that it is easier to fool iPhone into thinking that the non-picture file you are trying to transfer is a picture file from Camera Roll, then transfer it over via

- Prerequisites:

1. Jailbroken iDevice

2. Smallest.jpg (see below for link and use a Hex editor to create this file, if you are using Surface RT, use Be.Hex Editor) – 134 bytes

Credit: http://www.techsupportteam.org/foru...tography/1892-worlds-smallest-valid-jpeg.html

3. iFile and MobileTerminal installed on your iDevice

4. USB Cable

5. Surface RT

6. The file you want to transfer, e.g. example.avi

Method:

1. Locate the file you want to transfer and zip it using iFile to create, e.g. example.zip

2. Copy the file to /var/mobile

3. Copy Smallest.jpg to /var/mobile

4. Open MobileTerminal and go to /var/mobile

5. Execute the command “cat Smallest.jpg example.zip > IMG_0001.JPG”

This will combine the smallest jpeg file with the example.zip (a technique known as steganography)

6. Copy IMG_0001.JPG to /var/mobile/Media/DCIM/10*APPLE and rename it to the number following the last picture you have taken.

E.g. if the last photo you took is “/var/mobile/Media/DCIM/105APPLE/IMG_5555.JPG”, then rename and place it as “/var/mobile/Media/DCIM/105APPLE/IMG_5556.JPG”

7. The most complicated step so far: Tricking iPhone to recognize this as a valid JPG file. I have tried a few ways, but the most reliable way seems to be rebuilding the Camera Roll.

Credit: http://www.iphoneincanada.ca/how-to...l-crash-and-photos-turned-to-other-in-itunes/

(I suggest you back up your photos before attempting this step from the DCIM folder)

On iFile, go to “/var/mobile/Media/PhotoData” and delete

- com.apple.photos.caches_metadata.plist or

- Photos.sqlite or

- PhotosAux.sqlite

On iOS6, it should be Photos.sqlite.

You may also delete “/var/mobile/Media/PhotoData/Thumbnails/120x120.ithmb and 158x158.ithmb”, I find it speeds up the rebuilding process.

Then restart your phone and wait a minute or so and if you have little files in your camera roll, the non-Photo file will be recognized as a Photo file in seconds.

This method works for large files e.g. whole music albums zipped up into 80 Mb files for instance.

Other ways to add without restarting are

Relatively reliable

- Adding to Camera roll by Mail app

Less reliable

- Adding to Camera roll by Camera+ app

- Adding to Camera roll by Downloads/browser apps

Least reliable

- Adding to Camera roll by iFile app

8. Extracting the files

- On Surface RT, use 7-zip File Manager and double click the “IMG_5556.JPG” and voila, it opens like an archive!

- Extract the non-Photo files

- Pros: Good for transferring large files (>80MB) in seconds!

- Cons: Complicated, unidirectional (iPhone to Windows RT), may need to rebuild Camera Roll, may need to reboot iPhone

- Conclusion: Ideal if you want to quickly transfer a non-Photo file (e.g. movie file >80MB) without incurring cost with 3G/Wifi and without wasting too much time on Bluetooth. E.g. transferring a large zip containing your PDFs/movies/music/photos into your Surface RT from your iPhone at the airport with no WIFI.

Please let me know your comments or if you have any ways to trick iPhone into adding the non-Photo files (masquerading as a JPG file) into Camera Roll, without rebuilding the Camera Roll/restarting your iPhone. Thanks for reading!