NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.

Forum Discussion

testerek's avatar
testerek
Aspirant
Oct 23, 2011

Lost access to ssh :(

Ehh, after magic command "chmod 777 -R *" instead of "chmod 777 -R /Movies" I lost access via ssh. In auth.log I have somethign like this

Oct 23 15:45:33 freenas sshd[4255]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Oct 23 15:45:33 freenas sshd[4255]: error: @ WARNING: UNPROTECTED PRIVATE KEY FILE! @
Oct 23 15:45:33 freenas sshd[4255]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Oct 23 15:45:33 freenas sshd[4255]: error: Permissions 0777 for '/etc/ssh/ssh_host_rsa_key' are too open.
Oct 23 15:45:33 freenas sshd[4255]: error: It is recommended that your private key files are NOT accessible by others.
Oct 23 15:45:33 freenas sshd[4255]: error: This private key will be ignored.
Oct 23 15:45:33 freenas sshd[4255]: error: bad permissions: ignore key: /etc/ssh/ssh_host_rsa_key
Oct 23 15:45:33 freenas sshd[4255]: error: Could not load host key: /etc/ssh/ssh_host_rsa_key
Oct 23 15:45:33 freenas sshd[4255]: error: Could not load host key: /etc/ssh/ssh_host_dsa_key
Oct 23 15:45:48 freenas sshd[4268]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Oct 23 15:45:48 freenas sshd[4268]: error: @ WARNING: UNPROTECTED PRIVATE KEY FILE! @
Oct 23 15:45:48 freenas sshd[4268]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Oct 23 15:45:48 freenas sshd[4268]: error: Permissions 0777 for '/etc/ssh/ssh_host_rsa_key' are too open.
Oct 23 15:45:48 freenas sshd[4268]: error: It is recommended that your private key files are NOT accessible by others.
Oct 23 15:45:48 freenas sshd[4268]: error: This private key will be ignored.
Oct 23 15:45:48 freenas sshd[4268]: error: bad permissions: ignore key: /etc/ssh/ssh_host_rsa_key
Oct 23 15:45:48 freenas sshd[4268]: error: Could not load host key: /etc/ssh/ssh_host_rsa_key
Oct 23 15:45:48 freenas sshd[4268]: error: Could not load host key: /etc/ssh/ssh_host_dsa_key

Yes, I know Im stupid :oops: , but I want my ssh back. I have found something like this http://www.debian-administration.org/articles/476 but dont know how to change this without access to shell.
Please help me.

3 Replies

Replies have been turned off for this discussion
  • No luck, still the same problem :(

    Oct 23 22:21:06 freenas sshd[2809]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
    Oct 23 22:21:06 freenas sshd[2809]: error: @ WARNING: UNPROTECTED PRIVATE KEY FILE! @
    Oct 23 22:21:06 freenas sshd[2809]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
    Oct 23 22:21:06 freenas sshd[2809]: error: Permissions 0777 for '/etc/ssh/ssh_host_rsa_key' are too open.
    Oct 23 22:21:06 freenas sshd[2809]: error: It is recommended that your private key files are NOT accessible by others.
    Oct 23 22:21:06 freenas sshd[2809]: error: This private key will be ignored.
    Oct 23 22:21:06 freenas sshd[2809]: error: bad permissions: ignore key: /etc/ssh/ssh_host_rsa_key
    Oct 23 22:21:06 freenas sshd[2809]: error: Could not load host key: /etc/ssh/ssh_host_rsa_key
    Oct 23 22:21:06 freenas sshd[2809]: error: Could not load host key: /etc/ssh/ssh_host_dsa_key
    • theluke79's avatar
      theluke79
      Aspirant

      I have a RN102, ReadynasOS 6.4.0

      For some unknown reason my SSH was lost.

      I followed the suggested link, the "backup" of the original sshd_config file seems to have some effect, but it is not enough.

      TO actually fix it I have opended the zip file, edited the ssd_config file within the zip and REMOVED all kind of authetications (publickey, password, pam).

      By doing so I was able to login and fix everything.

      My SSH was inforcing Google 2FA, so this might have created issues with PAM

NETGEAR Academy

Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology! 

Join Us!

ProSupport for Business

Comprehensive support plans for maximum network uptime and business peace of mind.

 

Learn More