Comprehensive Study Notes on Cryptography and Encryption Systems

Deciphering Method
  • Key Presence: Successful decryption is easy when the key is known.
  • Without Key: Decryption without the key is computationally difficult.
  • One-way function: The ideal scenario is having a mathematical one-way function that is impossible to decrypt without the key.
    • Current Status: No true one-way functions exist at this time.
    • Implication: Without one-way functions, perfectly secure cryptography is not achievable; mathematically hard forms of cryptography are utilized instead.
Mathematical Hard Cryptography
  • Definition: Cryptographic methods that are computationally hard to break without the key, leading to an assumption of security.
  • Issues: Quantum computing poses potential vulnerabilities, which could compromise various encryption methods previously thought secure.
Cryptographic System Analysis
  • Attacks Against Cryptographic Systems:

    1. Ciphertext-Only Attack:
    • The attacker only possesses ciphertext and attempts to decipher it without access to plaintext or keys.
    • Example: U.S. government monitoring of data traffic through various channels.
    1. Known Plaintext Attack:
    • The attacker has both ciphertext and some of the known plaintext.
    • Example: Breaking the Enigma machine during WWII using known formats of weather reports.
    1. Chosen Plaintext Attack:
    • The attacker can choose specific plaintexts to be encrypted and analyze the resulting ciphertexts.
  • Cryptography Guidelines: a robust cryptographic system should withstand these attacks without revealing more information under chosen plaintext conditions compared to known plaintext scenarios.

Encryption System Security Principles
  • Hiding Encryption Method: Relying on secrecy of the encryption method is ineffective and has been disproven by multiple incidents.
  • Public Methods: Security through openness encourages review and improvement of encryption methods by experts.
    • Example: The case of cordless phones using secret encryption methods which were broken after reverse engineering.
Examples of Encryption Systems
  1. Caesar Cipher:

    • A shift cipher where each letter is shifted by a fixed number down the alphabet (key).
    • Mathematical Definition: For decryption, apply the inverse shift: ( C = (P + K) mod 26 ) (where P = plaintext letter and K = key).
    • Problematic: Only 25 keys make it easy to break (brute force).
  2. Symmetric Key Encryption:

    • Same key used for both encryption and decryption.
    • Example: Caesar cipher is a classical symmetric key encryption system.
    • Terminology:
      • Plaintext: Original unencrypted text.
      • Ciphertext: Encrypted jumbled text produced by the encryption algorithm.
      • Encryption Algorithm: A procedure that transforms plaintext using a key into ciphertext.
      • Decryption Algorithm: The reverse procedure that transforms ciphertext back into plaintext, also using the key.
One-Time Pad
  • Description: An encryption method where the key is as long as the message, used only once.
  • Security: Provably secure if the key is truly random and never reused.
    • Practical Use: Historically used for extremely classified communications pre-Internet.
  • Implementation Challenge: Lengthy and complex key management makes it impractical for general use.
Historical Context and Practical Applications
  • Classic Encryption Issues: The original Data Encryption Standard (DES) was compromised due to short key lengths (64 bits).
    • Brute-force attack by the Electronic Frontier Foundation took only 22 hours to break DES.
  • Advanced Encryption Standard (AES): Recommended to replace DES with longer key lengths and robust security.
Public Key Encryption
  • Introduction: Developed by Diffie and Hellman in 1976.
  • Dual Key System:
    • Public Key: Can be shared openly for encrypting messages.
    • Private Key: Kept confidential and used for decrypting messages.
  • Authentication: Public key enables verification of message authenticity by linking it with the private key.
Digital Signatures
  • Functionality: Digital signatures ensure integrity and authentication of digital messages.
  • Hash Functions: Often used to create unique identifiers for data, ensuring message integrity by producing a fixed-size output from variable-length input.
    • Hash Collision: Occurs when two different inputs yield the same hash output, a known risk that security systems aim to minimize.
Key Exchange Protocols
  • Key Agreement Protocols: Methods to establish a shared key between parties without prior coordination, often utilizing the efficiency of symmetric encryption post-agreement.
    • Diffie-Hellman Key Exchange: A method for securely exchanging cryptographic keys over a public channel, although not without potential vulnerabilities.
Key Infrastructure and Digital Privacy
  • Certificate Authorities: Trusted entities that validate and issue digital certificates for secure communication over networks (e.g., HTTPS).
  • Legacy Systems: Older systems like Pretty Good Privacy (PGP) provided end-to-end encryption through manual key management but have largely been replaced by automated processes in modern applications.