Notifications
Clear all
Topic starter 04/08/2025 11:35 pm
SHA-2 (Secure Hash Algorithm 2) is a family of cryptographic hash functions commonly used to protect data in computer systems, especially in cybersecurity, authentication, and digital signatures.
🧠 What SHA-2 Is
SHA-2 transforms input data (like a password, file, or message) into a fixed-length string of characters known as a hash. Even the tiniest change in the input produces a totally different hash, which helps verify the integrity and authenticity of data.
📚 SHA-2 Family Members
SHA-2 includes several different algorithms based on output size:
SHA-224
: Generates a 224-bit hashSHA-256
: Generates a 256-bit hash (widely used)SHA-384
: Generates a 384-bit hashSHA-512
: Generates a 512-bit hashSHA-512/224
andSHA-512/256
: Variants with different output lengths
🔐 Why SHA-2 Is Important
- Security: Unlike older versions like SHA-1 (which is now considered broken), SHA-2 is much more resistant to attacks such as collision and preimage attacks.
- Verification: Commonly used to check if downloaded files are unaltered and authentic.
- Digital Signatures: Used in certificates, like HTTPS on websites, to verify identity and secure communication.
🧪 Example Use Case
Input: "Hello World"
SHA-256 Hash: a591a6d40bf420404a011733cfb7b190d62c65bf0bcda32b57b277d9ad9f146e
Change just one letter, and the entire hash changes—like a digital fingerprint!