Hashing password algorithm

How To Change Default Password Hashing Algorithm On Redhat/Cent0s 7

Passalgo is a parameter in Linux it’s used to modified the default password hashing algorithm.By default, Hashing value is MD5 This hashing algorithm is used to encrypt the user password in /etc/passwd & /etc/shadow.file.

You can change inspect the available algorithm choices by

authconfig -–help | grep passalgo

You can check the default hashing algorithm by

authconfig -–test | grep hashing

Change default password

Now Change the Hashing algorithm by

authconfig -–passalgo=sha512 –update

Now Check algorithm has been changed or not by

authconfig -–test | grep hashing

Now algorithm is changed to SHA512.

Note: This will no effect on password already stored in /etc/passwd & /etc/shadow only future password will be hashed with new algorithm.

You’re done



Please enter your comment!
Please enter your name here