6.3.4 Upgrade Password Hashing Algorithm to SHA-512

Information

The SHA-512 encryption has been available since Red Hat release 5.2,. The commands below change password encryption from md5 to sha512 ( a much stronger encryption algorithm). All existing accounts will need to perform a password change to upgrade the stored hashes to the new algorithm.

Rationale:

The SHA-512 algorithm provides much stronger hashing than MD5, thus providing additional protection to the system by increasing the level of effort for an attacker to successfully determine passwords.

Solution

Perform the following to configure the system as recommended:

# authconfig --passalgo=sha512 --update

Note: If it is determined that the password algorithm being used is not SHA-512, once it is changed, it is recommended that all userID's be immediately expired and forced to change their passwords on next login. To accomplish that, the following commands can be used. Any system accounts that need to be expired should be carefully done separately by the system administrator to prevent any potential problems.

# awk -F: '( $3 >=500 && $1 != 'nfsnobody' ) { print $1 }' /etc/passwd | xargs -n 1 chage -d 0

Default Value:

OS Default: N/A

See Also

https://workbench.cisecurity.org/files/3096

Item Details

Category: IDENTIFICATION AND AUTHENTICATION

References: 800-53|IA-5, 800-53|IA-5(1), CSCv6|16.13, CSCv6|16.14, CSCv7|16.4

Plugin: Unix

Control ID: 658c639aec6db955599e38155db21761f9005e82bbc22e8a2f93dce07a14e54c