Deprecated: Assigning the return value of new by reference is deprecated in /var/www/vhosts/pleskhosts.com/httpdocs/forum/includes/init.php on line 49

Secure SSH [Archive] - Forums

View Full Version : Secure SSH


speedy
06-15-2007, 06:49 AM
This is for Red hat / Fedora

Make sure you do this in a new and separate console window or you could lock yourself and everyone else out of SSH completely.

You will also need to make sure that you have added at least one user to the wheel group before doing this or else you will never be able to login as root again.

We are going to disable direct root login, and we are also going to disable SSH Protocol 1 and only use SSH 2.

Now, lets setup the Config file for SSH
-----command-----
nano -w /etc/ssh/sshd_config
-----command-----
Find
#Protocol 2,1

Change to
Protocol 2

Find
PermitRootLogin yes

Change to
PermitRootLogin no

Save and exit.

Restart service
-----command-----
/sbin/service sshd restart
-----command-----


Transfer a Domain Name $9.99
Register A Domain Name  $9.99
www.