Home >Common Problem >what is sha
What is sha?
Secure Hash Algorithm (English: Secure Hash Algorithm, abbreviated as SHA) is a family of cryptographic hash functions and is a secure hash algorithm certified by FIPS. An algorithm that can calculate the fixed-length string (also called message digest) corresponding to a digital message. And if the input messages are different, the probability that they correspond to different strings is very high.
The SHA family of algorithms was designed by the U.S. National Security Agency (NSA) and published by the U.S. National Institute of Standards and Technology (NIST). It is a U.S. government standard. They are:
SHA-0: Released in 1993, it was called the Secure Hash Standard at the time. It was quickly withdrawn by the NSA after its release. It is the predecessor of SHA-1.
SHA-1: Released in 1995, SHA-1 is widely used in many security protocols, including TLS and SSL, PGP, SSH, S/MIME and IPsec. It was once considered to be MD5 (earlier The successor of the previously widely used hash function). However, the security of SHA-1 is no longer accepted by most encryption scenarios after 2000. In 2017, the Dutch cryptography research group CWI and Google officially announced that they had broken SHA-1[1].
SHA-2: Released in 2001, including SHA-224, SHA-256, SHA-384, SHA-512, SHA-512/224, SHA-512/256. Although there has been no effective attack on SHA-2 so far, its algorithm is still basically similar to SHA-1; therefore, some people have begun to develop other alternative hashing algorithms.
SHA-3: Officially released in 2015, SHA-3 is not intended to replace SHA-2 because SHA-2 currently has no obvious weaknesses. Due to the successful cracking of MD5 and the emergence of theoretical cracking methods for SHA-0 and SHA-1, NIST felt that an alternative cryptographic hash algorithm was needed that was different from the previous algorithm, which is now SHA-3.
The above is the detailed content of what is sha. For more information, please follow other related articles on the PHP Chinese website!