Comments on: iPhone Tip: Things To Check If You Cannot Connect Via SSH https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/ #1 Source for iPad, iPhone, iPod, Mac and AppleTV Mon, 28 Jan 2013 22:36:00 +0000 hourly 1 https://wordpress.org/?v=5.4.6 By: leetut https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-52121 Mon, 28 Jan 2013 22:36:00 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-52121 rm /bin/poc-bbot
cannot remove no such file or dir!!!!!!!!!!!!!

arrrrgggghhhhhhhh!!!!!!!!!!

still cant ssh using cyberduck
used to work fine
sometimes connects but always disconnects and wont reconnect
who ever invented that virus is a CUNT

]]>
By: IkeeHater https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-42750 Fri, 27 Jan 2012 19:56:08 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-42750 I also cant ssh!
how do you see that you’ve got the ikee worm?

]]>
By: x https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-42466 Mon, 02 Jan 2012 20:52:58 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-42466 Probably a bit late to the party, but I finally had a need to jailbreak and decided to use greenpois0n for my iOS4.2.1. It turned out that I also had the ikee virus. (I thought that I was safe because I had never jailbroken before nor had openSSH.) In any case, this article, http://www.iphonefaq.org/archives/97723, pointed to my problem – I didn’t have all of the files, but you pretty much have to check for every one listed to be sure. Since I didn’t know which variant that I had, I ended up removing all of them.

For known variants A, B or C

1. Run the Terminal app.
2. Enter each of the following commands followed by “return” to remove these files.

rm /bin/poc-bbot
rm /bin/sshpass
rm /System/Library/LaunchDaemons/com.ikey.bbot.plist
rm /var/lock/bbot.lock
rm /var/log/youcanbeclosertogod.jpg
rm /var/mobile/LockBackground.jpg

3. Reboot your iPhone.
4. Reinstall the SSH package from Cydia.
5. Follow these instructions to change your default root password and prevent reinfection!

For known variant D

1. Run the Terminal app.
2. Enter each of the following commands followed by “return” to remove these files.

rm /System/Library/LaunchDaemons/com.saurik.Cydia.Startup.plist
rm /usr/libexec/cydia/startup
rm /usr/libexec/cydia/startup-helper
rm /usr/libexec/cydia/startup.so

There’s more to the article.

]]>
By: Roger Delongo https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-41541 Wed, 16 Nov 2011 23:29:30 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-41541 Thanks for your help! Turns out my ssh was disabled in SSH settings.

]]>
By: @ric https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-39735 Mon, 03 Oct 2011 07:38:47 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-39735 I am having excessive trouble sshing to my iphone 3g, ios 4.1. I keep seeing an error message connection refused by machine. I assume this is the iphone refusing the connection. I do not have wifi on this device as it was stopped after an apple update several updates ago. Question is, can I ssh into my iphone without the wifi working. sbsettings gave me an ip address 10.205.213.214. This appears to be a private ip address, should work without any probs. Any suggestions would be nice.

]]>
By: Siva https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-35389 Sat, 07 May 2011 14:21:40 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-35389 “Server unexpectedly closed network connection.”
Same problem.
Using Windows Vista Home Premium. Latest WinSCP (4.3.2) and OpenSSH (in Cydia) Ver.5.8p1-9

Also, autolock is set to Never.

]]>
By: PatrickJ https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-32021 Tue, 25 Jan 2011 19:00:00 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-32021 @Michael – SBSettings is the easiest jailbreak app to use for this. It lets you toggle SSH on and off just like other services.

]]>
By: Michael https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-32017 Tue, 25 Jan 2011 17:08:25 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-32017 how can I make sure that OpenSSH is turned on on my iphone? Witch software I need to use?

]]>
By: Visar https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-27487 Mon, 11 Oct 2010 17:31:45 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-27487 In reply to KAZ.

hi please if you've solve tha problem can you share it please

]]>
By: James https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-25972 Sat, 14 Aug 2010 09:02:55 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-25972 Turn auto-sleep mode off in your settings. Tell it to never auto-lock the phone or itouch

]]>
By: KAZ https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-25015 Thu, 08 Jul 2010 23:46:24 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-25015 i got the same problem as jonathan….i tried reinstalling openssh,openssl,winscp,sbsettings and i still got "Server unexpectedly closed network connection." HELP PLSSSSSS THANKS ALOT!

]]>
By: Jonathan https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-24938 Mon, 05 Jul 2010 06:38:26 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-24938 In reply to patrickj.

hi, "Server unexpectedly closed network connection." I've tried reinstalling OpenSSH and also reinstalled WinSCP, but it still shows. I have no idea how to solve this, anyone can help?

]]>
By: Carlos https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-24323 Wed, 16 Jun 2010 17:20:48 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-24323 In reply to Al Dunbar.

It happened exactly the same to me. Step by step. Now I cannot us ssh. Did you find a solution for this?

]]>
By: patrickj https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-22767 Wed, 28 Apr 2010 00:17:03 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-22767 Have you tried reinstalling OpenSSH?

]]>
By: d8lom https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-22766 Tue, 27 Apr 2010 22:13:23 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-22766 What if you get an error message saying: "Server unexpectedly closed network connection."

]]>
By: patrickj https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-21334 Wed, 24 Mar 2010 01:14:04 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-21334 In reply to Michael Richardson.

Both the iPhone and the computer you're connecting from need to be on the same local WiFi network. This is do-able at a public WiFi spot but you'll want to make sure you turn SSH back off on your iPhone as soon as you are done transferring files or whatever you're up to.
You get a 169.254.x.y address when a device is unable to obtain a valid DHCP address. The way to fix that is to connect successfully to a WiFi network with a device that is dishing out dynamically assigned addresses correctly.

]]>
By: Michael Richardson https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-21333 Wed, 24 Mar 2010 00:32:41 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-21333 Q#1 can you use SSH while connected to a wifi hotspot?
Q#2 how to change a 169.254 non use able IP?

]]>
By: patrickj https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-20126 Sun, 21 Feb 2010 19:11:56 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-20126 In reply to Sanketh .

You've lost me there. Which WiFi IP address? Generally the only IP address you need to know during this process is he one for your iPhone – which will change periodically if you are using DHCP. When it does, you just make sure to enter the correct / current one in your desktop app you're using for SSH connections

]]>
By: Sanketh https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-20125 Sun, 21 Feb 2010 18:51:12 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-20125 What if the Wifi IP Address and Your Computer's IP Address are different what do you do now?

]]>
By: Al Dunbar https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-19736 Thu, 11 Feb 2010 00:30:12 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-19736 @Markus, did you have the Ikee virus without seeing the customary Rick Wallpaper? My personal wallpaper disappeared, replaced with the default earth pic, then (or I subsequently noticed) my SSH toggle in SBSettings disappeared. I had trouble connecting via Cyberduck, but managed to get in. After reinstalling some sbsettings and open ssh, I was able to connect. Then my SBsettings toggle mysteriously reappeared. However I am again unable to SSH in using CD (I get a "Premature Connection close." error message. Do these symptoms sound at all like what you had? If so, did you manage to get things fixed?

]]>
By: patrickj https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-19377 Thu, 04 Feb 2010 14:58:42 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-19377 In reply to Markus Hallberg.

Ah, ok – well hope you get restored and back to normal quickly.

]]>
By: Markus Hallberg https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-19369 Thu, 04 Feb 2010 08:13:44 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-19369 In reply to Markus Hallberg.

Found out whats wrong… I've got the Ikee virus! google for info.

]]>
By: Markus Hallberg https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-19296 Wed, 03 Feb 2010 19:09:56 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-19296 /me have problems… ssh’ing my iPhone 2G is working fine til I respring, then it won’t accept my connection. After respring I have to reinstall/restore openssh in cydia to be able to connect again, sometimes I also lose my sbsetting toggle for ssh after respringing.

And sometimes winscp will disconnect during session and the same prob occurs.

Any ideas?

]]>
By: patrickj https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-18727 Thu, 21 Jan 2010 17:46:04 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-18727 In reply to Kadiblov.

Hey – thanks for sharing and glad you got it worked out. Hate to say it, but I have a feeling another method might have been just to remove Icy and reinstall Cydia. My impression is that Icy is known to cause a number of severe issues.

]]>
By: Kadiblov https://isource.com/2009/05/05/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/#comment-18712 Thu, 21 Jan 2010 11:03:18 +0000 http://isource.com/iphone-tips/iphone-tip-things-to-check-if-you-cannot-connect-via-ssh/%20#comment-18712 Thanks Patrickj. This is how I fixed WiFi erratic, Cydia and SSH after Pwnage 3.1.2 on my iPhone 2G. I can´t guarantee is works for everyone, but here were my symptoms after I upgraded to FW 3.1.2 on my iPhone 2G using WinPwn(QuickPwn):

– Cydia didn´t worked – Opens windows, and closed suddenly. Same thing with Cycorder and Terminal (SSH for iPhone)
– Icy works, but with late packages – very old versions.
– Erractic Wifi (sometimes worked for 5 minutes, sometimes for 5 seconds, sometimes doesn´t even shown SSIDs Networks)
– SSH trials over Wifi (while it was working), using puTTY Terminal provided a error with dyld, on _login package and freezed (dropped connection). Connections using WinSCP however, worked fine, and I was able to browse my iPhone.
(reason I posted this message originally).

I searched for several forums, (yes, Google is our friend, despite of its intention to take over the world 🙂 ) to compile what I here propose – and worked fine fine for me:

FIRST STEP: GAINING ACCESS OVER SSH USING TERMINAL

1) Open Icy
2) Go to sources and remove apt.saurik.com as a repository
3) Close Icy and reboot your iPhone (Power Off cycle, or Reboot using bigboss.us package)
4) Add apt.saurik.com as a repo again.

This process refreshed the cache and versions, solving the old package availability. Prior to that, my OpenSSH package was on version 0.4xxx, which caused the dyld _login error, trying to access over puTTY due to lack of library.

5)Enter on Icy 1.4xxx and find the OpenSSH package on version 0.5xxx (updated). Install and exit Icy.

SECOND STEP: RESTABLISHING CYDIA

After OpenSSH update to 0.5xx, you must connect using Wifi. This was a tricky task, due to Wifi erractic behavior. I´ve tried several recipes, looking for a consistent workaround. What worked the most was 1) Reset Network Settings, 2) Enter Airplane Mode and 3) while in Airplane mode, activate only Wifi. This lead to a status where you have no phone service, which in the end, is good as we´re trying to fix over terminal and don´twant anyone bothering us with a call
Whenever in Wifi config settings screen, you can see your Wifi networks, reconfigure your SSID Password to your router, and login immediately using puTTY using your iPhone´s IP over SFTP.
As usual, login as ´root´ and password ´alpine´ standard procedure. It took me more than 5 times to get access, probably due to erractic Wifi behavior, but I finally got access to the terminal prompt.

Then follow these steps to reinstall cydia and update library
1) Remove outdated Cydia application by typing: 'apt-get remove cydia' and confirmation phrase.
2) Refresh entire library by typing ´apt-get update´ and see your library refreshing
3) Reinstall Cydia by typing ´apt-get install cydia´ It will reinstall and add the apt7 library, which I believe was key to move forward.

THIRD STEP: REFRESH ALL PACKAGES WITH CYDIA

Here were when my Wifi became stable. Cydia identified 36 packages to update !!! Hopefully some of them fixed the Wifi preferences and priorities – I really don´t know exactly what happened, but as you´re stuck as I was, there´s nothing really to lose if you got till here. o/

Hope it helps !

]]>