Back to Security
Cryptography Fundamentals
Learn about encryption, decryption, and cryptographic algorithms used in network security.
Cryptographic Principles
Confidentiality
Information is accessible only to authorized users
Integrity
Information remains accurate and unaltered
Authentication
Verify the identity of users and systems
Non-repudiation
Prevent denial of actions or transactions
Types of Cryptography
Symmetric Key Cryptography
Uses the same key for encryption and decryption
Examples:
- • AES
- • DES
- • 3DES
- • Blowfish
Advantages:
- • Fast
- • Efficient for large data
Disadvantages:
- • Key distribution problem
- • Key management complexity
Asymmetric Key Cryptography
Uses different keys for encryption and decryption
Examples:
- • RSA
- • ECC
- • Diffie-Hellman
Advantages:
- • Secure key exchange
- • Digital signatures
Disadvantages:
- • Slower than symmetric
- • More computational overhead
Hash Functions
One-way functions that produce fixed-size output
Examples:
- • MD5
- • SHA-1
- • SHA-256
- • SHA-3
Advantages:
- • Data integrity
- • Password storage
Disadvantages:
- • Not reversible
- • Collision vulnerabilities
RSA Encryption/Decryption
Hash Function Generator
Note: This is a simplified hash function for demonstration. Real cryptographic hash functions like SHA-256 are much more complex.
Key Concepts
Encryption Process
- 1. Plaintext → Input message
- 2. Key → Secret value
- 3. Algorithm → Encryption method
- 4. Ciphertext → Encrypted output
Security Properties
- • Computational Security
- • Perfect Secrecy
- • Semantic Security
- • Forward Secrecy