Author Topic: Why SSH port doesnot change?  (Read 6269 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Why SSH port doesnot change?
« on: July 24, 2018, 03:53:28 PM »


Hi

I changed  SSH port 2 days ago in config file /etc/ssh/sshd_config and in CSF firewall and restartd SSH and CSF Firewall many times but I receive a warning about it always:
 

"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. "


Thanks for your help
I love CWP

Offline
*
Re: Why SSH port doesnot change?
« Reply #1 on: July 24, 2018, 06:17:54 PM »
I  removed the # character from the beginning of the line and now changed.
It shoud look this way:

Code: [Select]
port 2211
I love CWP

Offline
***
Re: Why SSH port doesnot change?
« Reply #2 on: July 26, 2018, 04:35:43 AM »
I  removed the # character from the beginning of the line and now changed.
It shoud look this way:

Code: [Select]
port 2211

and then don't forget to perform the following command to restart the ssh service

Code: [Select]
service sshd restart

Offline
*
Re: Why SSH port doesnot change?
« Reply #3 on: October 02, 2018, 12:21:54 PM »
There's some kind of bug.  When I change the ssh port in Services Config -> SSH Configuration, you would expect this part of the

/etc/csf/csf.conf to change accordingly:

# This list is replaced, if present, by "Port" definitions in
# /etc/ssh/sshd_config
PORTS_sshd = "2221"

But it doesn't.   For me,  I had to change this setting and manually open the port in firewall settings.   So this PORTS_sshd does nothing.   Definitely glitchy.