I've recently been getting SSH brute force attacks on port 22 and i'd like to change the SSH port.
However, i cannot modify nor change permissions for sshd_config file under /etc/ssh
Tried changing the immutable attribute using
Code:
chattr -i sshd_config
But didnt help.
I still cant save the file from vi editor.
chmodding it doesnt help either.
Code:
[root@YSD001 ssh]# lsattr sshd_config
-u---a------- sshd_config
Code:
[root@localhost ssh]# chmod 666 sshd_config
chmod: changing permissions of `sshd_config': Operation not permitted
[root@localhost ssh]# sudo chmod 666 sshd_config
chmod: changing permissions of `sshd_config': Operation not permitted
I'm logged in as root, and modify and change files daily. I dont know why its
not working on this particular file ?
Any help would be greatly appreciated.