About Hash Functions
Hash functions are one-way cryptographic algorithms that convert input data into a fixed-size string. They are widely used for data integrity verification, password storage, and digital signatures.
Algorithm Comparison
- MD5: 128-bit hash, fast but cryptographically broken. Use only for checksums.
- SHA-1: 160-bit hash, deprecated for security use but common in legacy systems.
- SHA-256: 256-bit hash, part of SHA-2 family. Recommended for most security applications.
- SHA-512: SHA-2 with a 512-bit output. Choose SHA-256 or SHA-512 according to the protocol you must interoperate with; neither is a password-storage function.