-1

I know your time is valuable so I'm not waiting for specific answers to my situation. I don't mind reading documentation, so pointers to something that converges would be greatly appreciated. I don't plan to waste anyone's time..

This is not an urgent matter and I'm doing this to learn (the "site" doesn't serve anything but to learn to be honest, I'm paying for the hosting just to tinker with that).

This having been said:

I have a Linux shared hosting with GoDaddy. A lot of things need root privileges, which I don't have, since it's a shared account. For instance, changing the /etc/ssh/ssh_config file can't be done since I don't have the permission.

I am having difficulties since my ISP assigns me a dynamic IP address which changes whenever the router is rebooted, so each time the IP changes, I have to allow that IP to SSH to the GoDaddy host.

Issue 1:

I am able to SSH tunnel, but I have to go through cPanel in the following steps:

  • Login to my GoDaddy account.
  • Go to Hosting and then "Launch" the "site".
  • Go to "Security" and enable "SSH" which then opens a window with my IP address to allow.

I have an iMacro that does all this, so I only have to "Play" the iMacro to do that, and then "open a tunnel" using:

ssh -D 9999 user@remote_host -N

And then, on my laptop (Ubuntu) go to Network Proxy, choose "Manual":

"Socks Host" : localhost and port 999

Side question: Is there a better way to do it.

Question 1: Is there a better way to do it ? Like store a key here and whenever I try to SSH to the box, it authenticates me based on that key present in my laptop whatever my IP happens to be ?

Issue 2: I scanned that remote machine recently and found about 17 ports open. I don't like that.

Question 2: How can I close ports without having root privileges and without going through the crappy cPanel (since it's limited to the buttons they put in there and lacks flexibility).

I want to make it less insecure than it already is. Maybe assign SSH another port than 22, etc..

Any pointers would be greatly appreciated.

Thank you for your time.

uname -a

Gives

Linux host 2.6.32-458.18.1.lve1.2.39.el6.x86_64 #1 SMP Mon Sep 16 12:10:28 EEST 2013 x86_64 x86_64 x86_64 GNU/Linux

ssh -V

Gives

OpenSSH_5.3p1, OpenSSL 1.0.1e-fips 11 Feb 2013

If you need any further detail, I'm here.

  • You do realise that what you want to do as number 2 is something you are explicitly not allowed to do on a shared server hosted by GoDaddy. I would suggest re-reading the Terms and Conditions, and going to another platform if you don't like that one. – Rory Alsop Mar 14 '14 at 18:30
4

Question 1: Is there a better way to do it ? Like store a key here and whenever I try to SSH to the box, it authenticates me based on that key present in my laptop whatever my IP happens to be ?

Yes, it's called SSH Keys. This concept has been explained already hundreds of thousands of times. Adding another explanation here is unnecessary.

Issue 2: I scanned that remote machine recently and found about 17 ports open. I don't like that.

... uhm... ok...

Question 2: How can I close ports without having root privileges and without going through the crappy cPanel (since it's limited to the buttons they put in there and lacks flexibility).

You don't close ports without root privileges. That's why root privileges exist. So that non-administrators can't shut down core services.

I want to make it less insecure than it already is. Maybe assign SSH another port than 22, etc..

That's configured in /etc/ssh/sshd_config

As for tips for securing a cPanel server, feel free to search for tips for securing a cPanel server. There you will find many relevant articles, often with names like "10 tips for making your cPanel server more secure" and "A Beginners guide to securing your cPanel server." Those are for you.

Note that everything with respect to securing the server requires root. If you don't have root, then it's not your server, not your responsibility, you do not get to decide how it is secured.

If you want to secure your own server, that's fine. But it has to be your server.

  • Thanks for your answer, I can't up it for now. For the SSH Keys, the point is I can't even get to that step, since my IP changes (I don't know if you read that part). I mentioned the keys and asked if it were possible to use 'em with a dynamic IP. For changing the SSH port through /etc/ssh/sshd_config: - The file isn't there. - Even if it were, I wouldn't be able to change it (I'm not root). So, tell me something I don't know. My question was about what a user with no root privileges can do. Will check out the cPanel tips. I know I'm a beginner. Tell me something I don't already know. – Jugurtha Hadjar Mar 14 '14 at 19:06
  • @JugurthaHadjar if you had done any basic reading - virtually any - on SSH keys, you would know that they aren't affected by IP. – strugee Mar 15 '14 at 0:22
  • @JugurthaHadjar with respect to what you can do: it was stated in the answer. nothing. it isn't your server, it's GoDaddy's. – strugee Mar 15 '14 at 0:25
  • Okay. It's GoDaddy's server. Little quizz: Do you have a dynamic IP and trying to connect to a remote computer. If you had done any basic reading -virtually any- on SSH keys, you would know that it is a recurrent issue (one only needs to type SSH key dynamic" No offense, but you gotta love people jumping to point lack of knowledge on a specific point (SSH) while the problem still is real: GoDaddy needs to allow my IP (so it's an IP problem) to SSH to the box. SSH may not have anything to do with IP, but the issue is still there. – Jugurtha Hadjar Mar 15 '14 at 0:55
  • 1
    @JugurthaHadjar SSH keys are completely independent of IP addresses. Same IP, different IP, doesn't matter. The server verifies your private key matches the public fingerprint, and you're in. GoDaddy may (independent of SSH keys) apply IP restrictions to who can use SSH, but that's a godaddy thing. Not an SSH thing. You gotta complain to them. – tylerl Mar 15 '14 at 6:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.