ssh into iphone

hakuna-matata

macrumors 6502
Original poster
Sep 25, 2011
260
2
hi guyz! Being new to jailbreak, i want to know what's the best place to start learning about ssh, installing themes from pc, and terms like winscp, openssh etc.

i Know a little about ifunbox and a bit about operating it..Can i use it to put theme and other files into specific directories on iphone, without the need of any other s/w? thnx
 

dccorona

macrumors 68020
Jun 12, 2008
2,033
1
with openSSH installed on your iPhone, you can connect using any SSH program...that's all you need. iFunbox works differently I believe, it is not SSH, but requires a direct connection (via USB)...if it is anything like iExplorer, it won't allow access to locked directories, so would be useless for things like uploading dreamboard themes.

If you google SSH application windows (or mac if that's what you're using), then you will find several apps you can use to SSH into your phone. To connect, select SSH connection, then go into settings>wifi on your iPhone and look for the wifi IP address that is listed for your phone. This is the "address" you will be connecting to via your SSH program. The username is root, and the default password is alpine

WARNING: It is VERY IMPORTANT that you change your password as soon as possible. Without doing so, ANYONE can theoretically gain access to your phone, and do whatever they want...download pictures, texts, install viruses, delete vital system files, etc. It is pivotal that you are very careful with this. Also, make sure you don't delete anything from SSH unless you are sure what it does and know you need to remove it. There are no safeties on SSH...you could delete important files that keep your phone from working properly.

To change your password: Open up terminal (on mac/linux) or a terminal program on windows, and enter the following:

ssh root@<your iPhone's IP address...note there is no space between this and the @ sign>

yes

it will now prompt you for a password. enter alpine. Then enter:

passwd

it will ask you for the new password. Enter it twice, and your password will be changed. Don't forget it!

Hope this has been helpful
 

hakuna-matata

macrumors 6502
Original poster
Sep 25, 2011
260
2
with openSSH installed on your iPhone, you can connect using any SSH program...that's all you need. iFunbox works differently I believe, it is not SSH, but requires a direct connection (via USB)...if it is anything like iExplorer, it won't allow access to locked directories, so would be useless for things like uploading dreamboard themes.

If you google SSH application windows (or mac if that's what you're using), then you will find several apps you can use to SSH into your phone. To connect, select SSH connection, then go into settings>wifi on your iPhone and look for the wifi IP address that is listed for your phone. This is the "address" you will be connecting to via your SSH program. The username is root, and the default password is alpine

WARNING: It is VERY IMPORTANT that you change your password as soon as possible. Without doing so, ANYONE can theoretically gain access to your phone, and do whatever they want...download pictures, texts, install viruses, delete vital system files, etc. It is pivotal that you are very careful with this. Also, make sure you don't delete anything from SSH unless you are sure what it does and know you need to remove it. There are no safeties on SSH...you could delete important files that keep your phone from working properly.

To change your password: Open up terminal (on mac/linux) or a terminal program on windows, and enter the following:

ssh root@<your iPhone's IP address...note there is no space between this and the @ sign>

yes

it will now prompt you for a password. enter alpine. Then enter:

passwd

it will ask you for the new password. Enter it twice, and your password will be changed. Don't forget it!

Hope this has been helpful
thanx a lot, this was indeed very helpful. :) BTW, which app to SSH (for windows) would you advice?
 

monogasuki

macrumors newbie
Jun 18, 2009
6
0
WARNING: It is VERY IMPORTANT that you change your password as soon as possible. Without doing so, ANYONE can theoretically gain access to your phone, and do whatever they want...download pictures, texts, install viruses, delete vital system files, etc. It is pivotal that you are very careful with this. Also, make sure you don't delete anything from SSH unless you are sure what it does and know you need to remove it. There are no safeties on SSH...you could delete important files that keep your phone from working properly.

To change your password: Open up terminal (on mac/linux) or a terminal program on windows, and enter the following:

ssh root@<your iPhone's IP address...note there is no space between this and the @ sign>

yes

it will now prompt you for a password. enter alpine. Then enter:

passwd

it will ask you for the new password. Enter it twice, and your password will be changed. Don't forget it!

Hope this has been helpful
Do you need to change your root and mobile passwords even if you don't install SSH, but are jailbroken?
 

BumpyFlatline

macrumors 68030
Apr 11, 2012
2,668
0
Do you need to change your root and mobile passwords even if you don't install SSH, but are jailbroken?
I was always told it is unnecessary to change your root and mobile passwords if you do not have OpenSSH installed. But the moment you install OpenSSH, you need to change both passwords.
 

ZCherub

macrumors 6502a
Jul 7, 2010
653
1
GA, USA
I don't run OpenSSH currently, but I have on JBs on the past. At the time, I changed my password using a terminal program directly on the phone installed via Cydia. Last I checked, this wasn't compatible with the new firmware anymore - is that still the case?

Thanks!
 

BumpyFlatline

macrumors 68030
Apr 11, 2012
2,668
0
I don't run OpenSSH currently, but I have on JBs on the past. At the time, I changed my password using a terminal program directly on the phone installed via Cydia. Last I checked, this wasn't compatible with the new firmware anymore - is that still the case?

Thanks!
Nope. There's a fully compatible MobileTerminal ver. 520-2 found in the bigboss repo. I use that version with no problems. I like to periodically run a command that removed all the extra language packs on my phone. Boy do those add up and waste space haha. Don't get me wrong, it's fantastic there are so many translations of the apps found in the App Store and Cydia but I also like knowing that I can go through my entire phone and delete all the unnecessary language packs.
 

mlts22

macrumors 6502a
Oct 28, 2008
538
32
I do three things on my JB-ed devices to improve security.

First, I change the root and mobile passwords to something longer.
Second, I install sudo and vim and allow mobile to access root without a password.
Third, I change sshd's config file (/etc/ssh/sshd_config) to only allow access via RSA keys, then copy a public key from my desktop. That way, brute forcing passwords becomes impossible.
 

ZCherub

macrumors 6502a
Jul 7, 2010
653
1
GA, USA
Nope. There's a fully compatible MobileTerminal ver. 520-2 found in the bigboss repo. I use that version with no problems. I like to periodically run a command that removed all the extra language packs on my phone. Boy do those add up and waste space haha. Don't get me wrong, it's fantastic there are so many translations of the apps found in the App Store and Cydia but I also like knowing that I can go through my entire phone and delete all the unnecessary language packs.
Good to know - that's probably the route I'll go with again just because it's familiar (never used terminal on my Mac to change root PW).
 

BumpyFlatline

macrumors 68030
Apr 11, 2012
2,668
0
Good to know - that's probably the route I'll go with again just because it's familiar (never used terminal on my Mac to change root PW).
If you have any questions hit me up. You definitely want to change both the root and mobile passwords though.
 

ZCherub

macrumors 6502a
Jul 7, 2010
653
1
GA, USA
If you have any questions hit me up. You definitely want to change both the root and mobile passwords though.
Hm - I changed the root PW when I had open SSH installed before, but never read anything about changing the mobile PW... I plan on updating to 5.1.1 & re-jailbreaking this weekend (assuming I get my ATT unlock by then :) ), so I'll PM you for more details then if you don't mind.

Thanks!!
 

BumpyFlatline

macrumors 68030
Apr 11, 2012
2,668
0
Hm - I changed the root PW when I had open SSH installed before, but never read anything about changing the mobile PW... I plan on updating to 5.1.1 & re-jailbreaking this weekend (assuming I get my ATT unlock by then :) ), so I'll PM you for more details then if you don't mind.

Thanks!!
Sounds good! Good luck with AT&T!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.