Control Web Panel

WebPanel => How to => Topic started by: fotobo on January 05, 2016, 05:22:58 PM

Title: Disable root ssh?
Post by: fotobo on January 05, 2016, 05:22:58 PM
Hello All,

The How to forum looks like the best option for my question. I apologize that it isn't a straight How to, but more of a should I/could I discussion. Prior to using the centos-panel, I had root login to ssh disabled and used sudo. I now have root enabled but working with the panel now, I really am rarely needing to use ssh. I see from the security logs/email notices that IPs from China are hammering away at my root account trying to guess the password (and getting blocked thanks to CWP security measures). Should I worry about this? Is it possible to disable root login with CWP working and/or is it even needed?

Thank you for your input!

PS. Really loving CWP and wishing I'd found it earlier.
Title: Re: Disable root ssh?
Post by: Darkroom on January 05, 2016, 05:59:24 PM
edit /etc/ssh/sshd_config and add/change/uncomment the following line to:
PermitRootLogin no
Title: Re: Disable root ssh?
Post by: Administrator on January 17, 2016, 01:47:43 AM
also the best security would be to change the ssh port in the same file.
Title: Re: Disable root ssh?
Post by: bytecanarias on August 29, 2019, 11:40:16 PM
WARNING: Security vulnerability! Your server is using default SSH Port 22, to make your server more secure change SSH port in config file /etc/ssh/sshd_config and in CSF firewall !
After changes are done don't forget to restart SSH and CSF Firewall.

I get this warning every time I enter the panel, but I have ssh disabled, why do I get it?
#Port 22
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::

HostKey / etc / ssh / ssh_host_rsa_key
#HostKey / etc / ssh / ssh_host_dsa_key
HostKey / etc / ssh / ssh_host_ecdsa_key
HostKey / etc / ssh / ssh_host_ed25519_key

# Ciphers and keying
#RekeyLimit default none

# Logging
#SyslogFacility AUTH
SyslogFacility AUTHPRIV
#LogLevel INFO

# Authentication:

#LoginGraceTime 2m
#PermitRootLogin yes
#StrictModes yes
#MaxAuthTries 6
#MaxSessions 10