Jump to content

Can access via WWW, but not ssh?


Guest J_Cubed
 Share

Recommended Posts

Guest J_Cubed

My server is accessible via the web, but I cannot seem to ssh into it. I have the security settings set to Higher, and told the firewall to allow access via WWW, SSH, and FTP. (I want to only allow SFTP, but that's another issue for later. ;)) I cannot even SSH into the machine from the box itself! :wall: I can do a ssh locahost, but not ssh 12.34.56.78.

 

Anyone have any suggestions?

:help:

Link to comment
Share on other sites

you'll need to setup /etc/hosts.allow (specifically)

 

I don't remember the exact syntax, but I believe it gives you some guidelines. Something to the effect of:

ALL: ALL

will allow any IP address to connect to your ssh server.

Link to comment
Share on other sites

with the security settings set to HIGHER the default /etc/hosts.allow will only allow localhost to connect to the ssh server. That's why you can only connect when doing ssh localhost, and why anon isn't getting a response. /etc/hosts.allow is part of a wrapper so you can run ssh and only allow in those that you want to allow in - to everyone else it will look like there's no ssh server running.

Link to comment
Share on other sites

you'll need to setup /etc/hosts.allow (specifically)

 

I don't remember the exact syntax, but I believe it gives you some guidelines.  Something to the effect of:

ALL: ALL

will allow any IP address to connect to your ssh server.

You don't need anything in there to connect via ssh, you can specify only certain hosts or IPs if you want, but its not needed to make it work. tyme may have something with the high security level though,

Try dropping it to medium and see if it works then. Also run this to see the status of ssh.

 

/etc/rc.d/init.d/sshd status

Link to comment
Share on other sites

Are you still there? :)

 

I cannot even SSH into the machine from the box itself!  I can do a ssh locahost, but not ssh 12.34.56.78.

To me, this implies you are not even listening on this IP address - you ought to be able to connect to the IP address from the same machine without changing your firewall or hosts.allow (unless you have changed them...).

 

So add the address to the sshd config (webmin?) and try again.

 

Chris

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...