SSH and SCP into your Iphone with USB instead of WIFI. Only the Useful.

I had to go through four or five iphone SCP/SSH howto tutorials before I got it to work. So I figured I’d put only the useful steps here without all the garbage that the other sites spew. Here are the useful steps that allowed me total root access through SSH and SCP to my iphone harddrive. This guide requires that you have already jailbroken your iphone. Jailbreaking is stupidly easy and there is plenty of tutorials out there on how to do it.

First download this file. You will need to unzip it.
Run that file and a black DOS window should be displayed.

Next download this file. You will also need to unzip this one.

Before we log into the iphone with SCP we need to disable Auto-Lock because when the phone goes to sleep it drops the connection. On your iphone go to Settings -> General -> Auto-Lock. Set it to Never.

Make sure you have the OpenSSH package installed on the Iphone. If you don’t then go to Cydia on your iphone and select categories. I think it is in the networking category but I could be wrong. It’s in there somewhere. Install it.

Make sure you still have that black DOS window running. Without it you will be unable to connect to your iphone.

Now run WinScp. Enter 127.0.0.1 as the Host name. Leave the port number on 22. User ‘root’ for the username and ‘alpine’ as the password. Hit the Login Button.

SCP to Iphone

SCP to Iphone

You will be prompted about adding a RSA host key. Click Yes.

Now you have complete access to the Iphone’s filesystem.
If you want to SSH in then download Putty and use the same settings to SSH in. Always make sure that the itunnel black console (DOS) window is running.

-Cody Taylor

EDIT :
I did this again today and it wouldn’t work right away. I was getting this error on the iphone tunnel black screen when I tried to use SCP to log in.


new connection !
AMDeviceNotificationSubscribe = 0
iPhone attached !
AMDeviceConnect = 0
AMDeviceIsPaired = 1
AMDeviceValidatePairing = 0
AMDeviceStartSession = 0
MobileDevice: AMDeviceStartService: AMDeviceStartService: Could not connect to USB mux (error 10061)
AMDeviceStartService = -402653131
AFCConnectionOpen = 0

I was puzzled at first but then I realized why I couldn’t SCP into my iphone. I had turned SSH off from within the SBSettings menu. How would SCP work without SSH? It won’t.

Share

7 Responses to “SSH and SCP into your Iphone with USB instead of WIFI. Only the Useful.”

  • Jeremy Says:

    Thanx….worked like a charm after hrs of research

  • andreas Says:

    very helpfull, thanx

  • Cody Taylor's Tutorial on using SCP to access the Iphone | Quick Tech News Says:

    […] out Cody Taylor’s tutorial on using SCP to access your iphone through your usb port on your […]

  • Read PDF's Locally on the Iphone With Safari. No More Emails or URI Hacks | tech stuff from cody taylor Says:

    […] I’ve been trying recently to find a proper PDF reader for the iphone that doesn’t really screw up the formatting or require very manual conversions and it seems that safari’s built in pdf reader is better than stanza and other readers. Because safari on the iphone is not able to view files that are local on the device we need to do some quick work to make safari on the iphone read local files. For this to work you will need to be able to access the iphone file system from a personal computer somehow. Check out how to get SCP on the iphone working. […]

  • Foo Foo Bar Says:

    Try the Good Reader Application for reading PDFs — it costs a dollar but I found it to be much better than the other free options especially for large PDFs where bookmarking is necessary

  • Foo Foo Bar Says:

    Once you install Good Reader Application, create a folder with a recognizable name and then search for it with “find” from a shell and you’ll see where you have to store files on the file system

  • yacine Says:

    My SSH is turned on but I still have the same error msg:
    AMDeviceStartService = -402653131