Information
Cipher Block Chaining (CBC) is an algorithm that uses a block cipher.
A vulnerability exists in SSH messages that employ CBC mode that may allow an attacker to recover plaintext from a block of ciphertext. If exploited, this attack can potentially allow an attacker to recover up to 32 bits of plaintext from an arbitrary block of ciphertext from a connection secured using the SSH protocol.
Solution
Create or edit a file in /etc/crypto-policies/policies/modules/ ending in .pmod and add or modify one of the following lines:
cipher@SSH = -*-CBC # Disables the CBC cipher for SSH
Example:
# printf '%s\n' "# This is a subpolicy to disable all CBC mode ciphers" "# for the SSH protocol (libssh and OpenSSH)" "cipher@SSH = -*-CBC" >> /etc/crypto-policies/policies/modules/NO-SSHCBC.pmod
Run the following command to update the system-wide cryptographic policy
# update-crypto-policies --set <CRYPTO_POLICY>:<CRYPTO_SUBPOLICY1>:<CRYPTO_SUBPOLICY2>:<CRYPTO_SUBPOLICY3>
Example:
# update-crypto-policies --set DEFAULT:NO-SHA1:NO-WEAKMAC:NO-SSHCBC
Run the following command to reboot the system to make your cryptographic settings effective for already running services and applications:
# reboot
Impact:
CBC ciphers might be the only common ciphers when connecting to older SSH clients and servers