Hashing and encryption are both cryptographic, but they serve opposite goals. One is a reversible lock for confidentiality; the other is a one-way fingerprint for integrity. Mixing them up is a common exam trap.
Last updated June 2026
| Aspect | Hashing | Encryption |
|---|---|---|
| Reversible? | No, one-way by design | Yes, two-way with the key |
| Purpose | Verify integrity, store passwords | Protect confidentiality |
| Output | Fixed-length digest | Ciphertext that scales with the input |
| Key | No key (may use a salt or an HMAC key) | Requires a key |
| CIA goal | Integrity | Confidentiality |
| Examples | SHA-256, SHA-3, MD5 (broken) | AES, RSA, ChaCha20 |
Encryption protects confidentiality and can be reversed with the key; hashing is a one-way fingerprint that proves integrity and cannot be reversed. Passwords should be hashed with a salt and a slow algorithm, never encrypted.
Reading the difference is a start. SecPlus Mastery drills it with over 1,000 practice questions, timed mock exams, and spaced review across all five SY0-701 domains, so it sticks for exam day.
Written to the CompTIA Security+ SY0-701 objectives. CompTIA and Security+ are trademarks of CompTIA, used here for identification only.