How to SSH into your iPhone

emx620

New Member
Bronze
Jul 13, 2007
110
0
0
#1
Sorry if this has been posted before but I keep getting asked. First off to enable SSH on your phone do this:
  • SSH is a service that you can install and run on the iPhone that allows you to access the phone's files / folders from your PC or Mac
  • You need to install BSD Subsystem and OpenSSH (in that order) from under the System category in Installer in order to be able to use it
Putty is downloaded here:
http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe

Make sure your iPhone is connected to your network. To find your IP address, go to Settings -> Wi-Fi
Click the blue arrow on the network you are connected to. Your IP address will be in there. Use that number for the rest of this guide.

Cygwin Instructions:
ssh root@xxx.xxx.x.xxx Put your IP address here.
For me it was:
ssh root@10.4.9.40
It will prompt for a password which will be alpine.

Putty Instructions:
In the Putty configuration window under Host Name - put your ip address here
Click Open.
Click Yes if prompted.
Put root as the login and alpine as the password.

WinSCP Instructions:
After connecting to your iPhone, do the following:
Commands -> Open Terminal
Click Ok if prompted. After typing in each command click Execute.

CyberDuck
Click New Connection.
In the Protocol dropwdown menu, choose SSH.
In the Server field, input your iPhone's IP.
In the Username field, enter root.
In the Password field, enter alpine, unless you have changed it.
Click Connect.
--- Thanks John ---

Term-VT100
"Install http://www.trejan.com/irepo/ source in Installer. Then install "SUID Lib Fix" and "Term-vt100 SUID fix" from the Tweaks 1.1.3 cstegory."
Once you run this fix you will still be prompted for a password when launching term but it will now accept "alpine" and allow you in.
--- Thanks Griffinaz and Tinman---

Hope this helps. Let me know if you have any questions.
 

Lincoln

New Member
Gold
Aug 11, 2007
6,100
4
0
#2
Nice guide; I get asked this question very frequently.

However, if I'm not mistaken, all your listed programs are Windows programs. Inlcude Cyberduck for the Mac. The instructions are as follows:

In Cyberduck, click New Connection.
In the Protocol dropwdown menu, choose SSH.
In the Server field, input your iPhone's IP.
In the Username field, input root.
In the Password field, input alpine, unless you have changed it.
Click Connect.

- John
 

Hawk

Genius
Gold
Aug 2, 2007
6,682
241
83
49
ATL
#3
anyone have some instructions for Term VT100?
Everytime I go into it, it asks for a password right off the bat, and alpine apparently is not it.
After it fails for the first time I enter everything like it's listed for Cygwin:
ssh root@your ip address here
It will ask for a password which will be alpine.
 

Lincoln

New Member
Gold
Aug 11, 2007
6,100
4
0
#4
anyone have some instructions for Term VT100?
Everytime I go into it, it asks for a password right off the bat, and alpine apparently is not it.
After it fails for the first time I enter everything like it's listed for Cygwin:
ssh root@your ip address here
It will ask for a password which will be alpine.
I have the same issue. I always get incorrect login and incorrect password.

- John
 

emx620

New Member
Bronze
Jul 13, 2007
110
0
0
#5
anyone have some instructions for Term VT100?
Everytime I go into it, it asks for a password right off the bat, and alpine apparently is not it.
After it fails for the first time I enter everything like it's listed for Cygwin:
ssh root@your ip address here
It will ask for a password which will be alpine.
Are you specifying the user name? Maybe its trying to use some other default user name the iPhone doesn't have?
 
Jun 7, 2007
545
0
16
Queens, NY
#6
anyone have some instructions for Term VT100?
Everytime I go into it, it asks for a password right off the bat, and alpine apparently is not it.
After it fails for the first time I enter everything like it's listed for Cygwin:
ssh root@your ip address here
It will ask for a password which will be alpine.
are you on 1.1.3? cause if you are, there is a few fixes you need to install to get vt100 working properly.
 

Hawk

Genius
Gold
Aug 2, 2007
6,682
241
83
49
ATL
#7
Are you specifying the user name? Maybe its trying to use some other default user name the iPhone doesn't have?
I don't actually know. I've been instructed to input ssh root@ipaddress and then hit enter and then enter alpine for the password. Never works.
But it does just ask for a password when I first start the app.
 
Jun 7, 2007
545
0
16
Queens, NY
#8
I don't actually know. I've been instructed to input ssh root@ipaddress and then hit enter and then enter alpine for the password. Never works.
But it does just ask for a password when I first start the app.
to ssh into the phone, make sure you have openssh installed in the iPhone.

and bsdsubsystems..which is the first to get installed.

launch which ever scp client you have. I'm on a PC using winscp.

host name :root@192.168.x.xxx...what ever your ipaddress is on your iPhone
user name: root
pw: alpine
file protocol :scp

as far as vt100 with 1.1.3 you need to do a few fixes before you get it to work
1. install services
2. install services.app SUID fix
3. install SUID lib fix
4.bsd sub system 2.0 termfix.

when you launch vt100 hit enter
login: root
pw: alpine, it will not type out with ***** so just keep typing.

good luck.

ps. make sure the phone and the computer you are using is on the same network or else your gonna hit a brick wall!
 

Griffinaz

Zealot
Gold
Oct 5, 2007
1,046
13
38
Phoenix, Arizona
#9
To get Term-VT100 to permit you to login, follow these steps (Thanks to Tinman for posting these in a different thread):

"Install http://www.trejan.com/irepo/ source in Installer. Then install "SUID Lib Fix" and "Term-vt100 SUID fix" from the Tweaks 1.1.3 cstegory."

Once you run this fix you will still be prompted for a password when launching term but it will now accept "alpine" and allow you in.
 

timothy

Member
Bronze
Nov 4, 2007
177
0
16
Thousand Oaks, Californication
#10
ok. This worked for me in this order:
1. install BSD
2. install openSSH
3. install VT100
4. (I'm 1.1.4 I know) install the VT100 fix (despite it saying for 1.1.3 only
5. [PC] install WinSCP
6. following the above persons login info -
host name :root@192.168.x.xxx...what ever your ipaddress is on your iPhone (located in settings/wifi)
user name: root
pw: alpine
file protocol :scp
7. don't connect yet.
8. type in VT100 "ssh" (obviously without the quotes)
9. while iPhone is opening that, use winSCP to connect.
10. in my case, wait 5 seconds, get a window that looks like WSftp and many other ftp programs
11. do happy dance

Hope this helps!
 

OhWhyMe

New Member
Bronze
Jan 17, 2008
46
0
0
#12
How do you turn openssh off? Hit unload -w? Then hit Load -w when you want to turn it on?
What does regular load do?
 

emx620

New Member
Bronze
Jul 13, 2007
110
0
0
#13
How do you turn openssh off? Hit unload -w? Then hit Load -w when you want to turn it on?
What does regular load do?
Uninstall it I guess or install a Services app and do it through that.
 

Lincoln

New Member
Gold
Aug 11, 2007
6,100
4
0
#15
Turning SSH off is a good idea when you aren't using it, as it eats up battery like crazy.

- John
 
Mar 17, 2008
1
0
0
#16
Problem SSHing to iPhone.

Hi I am having SSHing to my iPhone. It says unable to connect. Do you have anyother steps to continue or troubleshoot the situation?

- Hemanth
:(
Sorry if this has been posted before but I keep getting asked. First off to enable SSH on your phone do this:
  • SSH is a service that you can install and run on the iPhone that allows you to access the phone's files / folders from your PC or Mac
  • You need to install BSD Subsystem and OpenSSH (in that order) from under the System category in Installer in order to be able to use it
You can use Cygwin or Putty...two different downloads.
Putty is downloaded here:
http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe

Make sure your iPhone is connected to your network. To find your IP address, go to Settings -> Wi-Fi
Click the blue arrow on the network you are connected to. Your IP address will be in there. Use that number for the rest of this guide.

Cygwin Instructions:
ssh root@your ip address here
For me it was:
ssh root@10.4.9.40
It will ask for a password which will be alpine.

Putty Instructions:
In the Putty configuration window under Host Name - put your ip address here
Click Open.
Click Yes if prompted.
Put root as the login and alpine as the password.

WinSCP Instructions:
After connecting to your iPhone, do the following:
Commands -> Open Terminal
Click Ok if prompted. After typing in each command click Execute.

CyberDuck
Click New Connection.
In the Protocol dropwdown menu, choose SSH.
In the Server field, input your iPhone's IP.
In the Username field, input root.
In the Password field, input alpine, unless you have changed it.
Click Connect.
--- Thanks John ---

Hope this helps. Let me know if you have any questions.
 

Ramesh

Zealot
Gold
Jul 12, 2007
4,571
3
38
Irvine, Ca.
#17
Turning SSH off is a good idea when you aren't using it, as it eats up battery like crazy.

- John
Really? I've noticed no difference in battery drain. None at all, and I've run jailbroken and jailed for extended times. No diff on my end.
 

michael180

Zealot
Gold
Jun 14, 2007
1,249
3
38
Santa Cruz, CA
moderntimes.com
#19
Cygwin Instructions:
ssh root@xxx.xxx.x.xxx Put your IP address here.
For me it was:
ssh root@10.4.9.40
It will prompt for a password which will be alpine
Hope this helps. Let me know if you have any questions.
I am trying to ssh into my phone via terminal.

I did as you suggested above, but I keep getting the error, "RSA host key for my IP ADDR has changed and you have requested strict checking.
Host key verification failed.

Now I know my IP ADDR is correct.

Any suggestions?
 

emx620

New Member
Bronze
Jul 13, 2007
110
0
0
#20
I am trying to ssh into my phone via terminal.

I did as you suggested above, but I keep getting the error, "RSA host key for my IP ADDR has changed and you have requested strict checking.
Host key verification failed.

Now I know my IP ADDR is correct.

Any suggestions?
Did you read Timothy's post at the bottom of the first page of this thread?