Cryptography 🔐

Protecting Data with Mathematics

1. What is Cryptography?

Cryptography is the science of securing information by converting it into unreadable formats using algorithms and keys.

2. Main Goals

Confidentiality 🔒 → hide data
Integrity 🧩 → prevent changes
Authentication 🪪 → verify identity

3. Types of Cryptography

Symmetric → same key for encrypt/decrypt
Asymmetric → public + private key pair
Hashing → one-way data conversion

4. Symmetric Encryption

Same key 🔑 used for both encryption & decryption
Fast but key must be shared securely
Examples: AES, DES

5. Asymmetric Encryption

Public key 🔓 encrypts data
Private key 🔐 decrypts data
Example: RSA, ECC

6. Hashing

One-way function
Input → fixed output
Example: SHA-256 (used in Bitcoin)

7. Digital Signatures

Proves authenticity
Ensures message is not tampered
Used in blockchain & emails

8. Real Use Cases