HOW-TO Disable CBC Ciphers and weak MAC Algorithms in Unix / Linux
102
Created On 11/10/26 11:00 AM - Last Modified 11/10/26 13:04 PM
Objective
You may have run a security scan or your auditor may have highlighted the following SSH vulnerabilities and you would like to address them.
SSH Server CBC Mode Ciphers EnabledSSH Weak MAC Algorithms Enabled
Environment
N/A;12.6;14.2
Procedure
To disable CBC mode ciphers and weak MAC algorithms (MD5 and -96), backup the current file and add the following lines into the /etc/ssh/sshd_config file.
Afterwards, restart the sshd service.
1. Backup:
# cp /etc/ssh/sshd_config /etc/ssh/sshd_config.bak
2. Edit file:
# vi /etc/ssh/sshd_config Ciphers aes128-ctr,aes192-ctr,aes256-ctr MACs hmac-sha1,umac-64@openssh.com,hmac-ripemd160
3. Restart the SSHD service
# systemctl restart sshd.service or # service sshd restart