1. jkinghome's Avatar
    Last night, I virginzed the phone and successfully upgraded to 1.1.1, unlocked with Independence 1.2.4. I had OpenSSH on the 1.0.2 version.

    I use services.app to control turning on and off SSH, but SSH wasn't showing in the list on services.app. So, I went to installer.app to uninstall OpenSSH, but it gave me "main script executive failed".

    How can I uninstall and reinstall OpenSSH so it shows up with services.app?

    Thanks guys for any input.

    Jane
    2007-10-24 06:12 PM
  2. weirdohenrico's Avatar
    i have the same question
    2007-10-24 11:11 PM
  3. oNeLoVe's Avatar
    i have the same question
    ditto
    2007-10-25 02:06 AM
  4. korymatthew's Avatar
    Me too! But mine's for Taskbar Notifier...
    2007-10-25 02:32 AM
  5. Piz's Avatar
    Guys, I had the same problem. But it's being solved in the sticky post.

    http://modmyi.com/forums/showthread.php?t=9121

    Check out #14 jekitchen's method.

    When you upgrade, the OpenSSH & BSD are already gone. So just remove them from the plist file.

    Better search before you ask questions.
    2007-10-25 04:16 AM
  6. weirdohenrico's Avatar
    Piz, I already saw that - the problem is I cant ssh to my iphone. It does it with Independence but not with what I'm using Transmit (Mac).
    2007-10-25 07:58 AM
  7. Macfreak7's Avatar
    Same issue here except that it says "Main script execution failed!"

    Tried a bunch of things like uninstalling SSH using independence but it didn't help.
    i think i should've just stuck with 1.0.2.
    2007-10-26 09:31 AM
  8. drunknbass's Avatar
    reason it fails is because the ssh that is on the phone now is alittle diff than the open ssh, so it tries to delete a file thats not there and it fails.. if you upgraded to 1.1.1 most likely you have bsd and ssh because thats part the process of upgrading even if you dont use ijailbreak / independance and upgraded manually.

    so what you need to do is look in your var/root/Library/Installer/localpackages.plist folder on your phone and delete the key for openssh, everything between the < dict > and </ dict >
    then go into installer and you can reinstall openssh (works on 1.1.1) or just leave it alone..
    dont delete the key for the bsd subsystem. eventho you have a different version of bsd installer (the one you installed when you were upgrading your phone is different than what is on installer.app) you still want to let installer think you have bsd subsystem installed or else other apps that require bsd wont allow you to install. so basically you are tricking installer into thinking you have the old bsd installed when you have a newer one.. doesnt really matter.
    2007-10-26 09:42 AM
  9. Macfreak7's Avatar
    Ok so modifying localpackages.plist helped. thanks!
    but SSH is still being erratic especially when trying to connect via the terminal.
    anyone get services.app to work with openssh on 1.1.1?
    2007-10-26 11:26 AM
  10. jwdav's Avatar
    posted this in another thread ...

    Regarding fixing OpenSSH / Installer.app / Services.app

    1.0.2 Phone iUnlock ->virginized->updated/unlocked/activated on 1.1.1

    Installer.app 3


    During the install/upgrade, I installed SSH from Independence - I had to as it would not allow me to proceed with the "pre" step otherwise. I had OpenSSH and BSD subsystem installed from the previous unlock, but independence did not see or use them.

    All went well until I a) tried to use Services.app to turn off SSH and b) tried to use Installer.app to uninstall or reinstall OpenSSH. Neither worked, and I further discovered that I had two SSH daemons running ...

    The Fix

    First, I needed to get the leftover bits from OpenSSH removed or be able to install it over top what was there. Installer.app keeps a plist of what it thinks is installed here:

    /var/root/Library/Installer/LocalPackages.plist

    Make a safety copy and a working copy, and edit out the section for OpenSSH - select from the <dict> tag to the closing </dict> tag - and replace the existing LocalPackages.plist with your edited copy.

    Now Installer.app thinks that OpenSSH has never been installed.

    Next, using Independence (quit iTunes etc.), remove the SSH installation from the phone & reboot the phone. Do not remove the dylib that Independence warns about.

    Make sure the Phone auto lock is off and then ...

    Using Installer, re-install the BSD Subsystem (done by going to the uninstall page and selecting "reinstall"
    Using Installer, re-install OpenSSH

    Finally, I also removed the known_hosts file from /Users/myName/.ssh/known_hosts

    in Terminal

    rm -f /Users/YourShortUserName/.ssh/known_hosts

    reboot the phone, and you should have only one instance of sshd running, installer.app works and services.app works. There is a 30-40 second delay while OpenSSH generates the keys the first time you try to log in. If it fails, reboot the phone and try again.
    2007-10-26 11:43 AM
  11. Macfreak7's Avatar
    that was very helpful jwdav, thanks!

    here's what i found.. indepedence uses org.thebends.openssh while openssh.app uses com.openssh.sshd

    services.app only works with com.openssh.sshd, so they need a fix to make it work with the other one as well.

    i used UIctl.app to unload org.thebends.openssh since that usually requires a restart to disable, while servies.app doesn't require a restart to enable/disable. so instead of deleting the second instance, you could also just disable it permanently (unless you need it as some point).
    2007-10-26 06:52 PM
  12. pseudo's Avatar
    Hi I was following your instructions but when I tried to remove SSH using INdependence 1.2.5 (which I used for the upgrade to 1.1.1) it shows that my phone is jailed and trying to jailbreak it results in an error saying I have to downgrade to 1.0.2 first... What have I done wrong? INdependence indicated that my iphone is 1.1.1, activated, but jailed. TIA.

    posted this in another thread ...

    Regarding fixing OpenSSH / Installer.app / Services.app

    1.0.2 Phone iUnlock ->virginized->updated/unlocked/activated on 1.1.1

    Installer.app 3


    During the install/upgrade, I installed SSH from Independence - I had to as it would not allow me to proceed with the "pre" step otherwise. I had OpenSSH and BSD subsystem installed from the previous unlock, but independence did not see or use them.

    All went well until I a) tried to use Services.app to turn off SSH and b) tried to use Installer.app to uninstall or reinstall OpenSSH. Neither worked, and I further discovered that I had two SSH daemons running ...

    The Fix

    First, I needed to get the leftover bits from OpenSSH removed or be able to install it over top what was there. Installer.app keeps a plist of what it thinks is installed here:

    /var/root/Library/Installer/LocalPackages.plist

    Make a safety copy and a working copy, and edit out the section for OpenSSH - select from the <dict> tag to the closing </dict> tag - and replace the existing LocalPackages.plist with your edited copy.

    Now Installer.app thinks that OpenSSH has never been installed.

    Next, using Independence (quit iTunes etc.), remove the SSH installation from the phone & reboot the phone. Do not remove the dylib that Independence warns about.

    Make sure the Phone auto lock is off and then ...

    Using Installer, re-install the BSD Subsystem (done by going to the uninstall page and selecting "reinstall"
    Using Installer, re-install OpenSSH

    Finally, I also removed the known_hosts file from /Users/myName/.ssh/known_hosts

    in Terminal

    rm -f /Users/YourShortUserName/.ssh/known_hosts

    reboot the phone, and you should have only one instance of sshd running, installer.app works and services.app works. There is a 30-40 second delay while OpenSSH generates the keys the first time you try to log in. If it fails, reboot the phone and try again.
    2007-10-27 10:05 AM
  13. jwdav's Avatar
    I'm not sure what that's about ... you just connected with Independence and the status came up as "Jailed"? I think you can re-jail yourself with Independence, but I'm not sure how.

    As far as the instructions go, you would just open independence, go to the SSH tab and select uninstall - none of which is related to the Jail status of the phone.

    I'm not sure how to recover from that, but it might well require a whole downgrade/upgrade activate/jailbreak cycle.
    2007-10-27 10:19 AM
  14. vampyros_wrath's Avatar
    I am havingthe same kind of problem, but with windows, i already edited the plist file and reinstalled bsd and openssh, can i just follow the instructions for to desshify it via natetrue's method?
    2007-10-27 08:54 PM
  15. royec's Avatar
    Ok, here is the solution, if you hav WIFI, and installer, install MOBILEFINDER and MOBILETEXTEDITOR,

    first: with mobile finder copy this file to any directory (for backup)

    /var/root/Library/Installer/LocalPackages.plist

    Then
    In text editor open the original file (/var/root/Library/Installer/LocalPackages.plist)
    and whit much patience erase ALL the <dict> block that begins with:

    < dict >
    < key >bundleIdentifier< /key >
    < string >org.smxy.iphone-apps.OpenSSH< /string >
    < key >category< /key >
    < string >System< /string >
    < key >contact< /key >
    < string >[email protected]< /string >..........................
    .................................................. .......................................
    .................................................. .......................................
    < string >http://psmxy.org/iphone-apps/info/OpenSSH.html< /string >
    < key >version< /key >
    < string >4.6p1-1< /string >
    < /dict >


    Press SAVE

    open Installer and install OpenSSH
    Last edited by royec; 2007-10-30 at 02:57 AM.
    2007-10-30 02:54 AM
  16. jinxen's Avatar
    after when i re-install openssh and it shows up in services again but when i turn it on it never starts. When i open services again it slides directly to off. I have uninstalled the version that comes with independent of course. Why doesn't it stay on?
    2007-11-19 05:46 PM
LINK TO POST COPIED TO CLIPBOARD