Summary
Here is a master sheet summarizing all the protocols, algorithms, and cryptographic concepts mentioned across the lectures. They are categorized to clearly outline their differences and specific use cases.
1. Symmetric Cryptography
Symmetric cryptography uses the same key for both encryption and decryption.
Stream Ciphers: Encrypts data by combining a sequence of plaintext symbols with a sequence of keystream symbols one at a time.
Block Ciphers: Operates on fixed-size blocks of plaintext to yield blocks of ciphertext.
AES (Advanced Encryption Standard): The current standard block cipher. It uses a fixed block size of 128 bits and supports key sizes of 128, 192, or 256 bits.
Padding Schemes: Required when plaintext does not fit exactly into fixed-size blocks.
Zero Padding: Adds zero bytes.
ANSI X.923: Adds a sequence of 0s, with the final byte indicating the number of added bytes.
PKCS7: Adds a sequence of bytes where each byte's value is the number of bytes added.
Modes of Operation: How block ciphers encrypt sequences of blocks.
ECB (Electronic Codebook): Each block is encrypted independently. Flaw: Identical plaintext blocks encrypt to identical ciphertext blocks, preserving data patterns.
CBC (Cipher Block Chaining): XORs each plaintext block with the previous ciphertext block (or an Initialisation Vector for the first) before encryption. Masks patterns, but a 1-bit error in ciphertext corrupts one full block and one bit of the subsequent plaintext.
CTR (Counter): Uses a unique nonce and an incrementing counter for each block. Allows for parallel decryption.
2. Asymmetric Cryptography (Public Key Cryptography)
Uses a mathematically linked pair of keys: a public key for encryption/verification and a private key for decryption/signing.
RSA: Based on the mathematical difficulty of factoring large prime numbers ($N=pq$).
Textbook RSA: Deterministic encryption () and decryption ().
OAEP (Optimal Asymmetric Encryption Padding): Adds randomness to RSA to make it probabilistic, preventing guessing/dictionary attacks.
RSA Digital Signatures: Uses the private key to sign and public key to verify. Hashed RSA prevents forgery attacks exploiting textbook RSA's homomorphic properties.
Diffie-Hellman (DH) Key Exchange: Allows two parties to create a shared secret over a public, eavesdropped channel. Relies on the Discrete Logarithm problem. Vulnerable to active Man-in-the-Middle (MITM) attacks if unauthenticated.
ElGamal: An encryption scheme whose security is also based on Discrete Logarithms. Features built-in randomness and supports homomorphic operations (multiplying encrypted values).
DSS/DSA (Digital Signature Standard/Algorithm): A signature scheme based on ElGamal concepts and Discrete Logarithms.
Schnorr Signature: Another highly practical discrete logarithm-based signature scheme.
Hybrid Encryption: Combines symmetric and asymmetric cryptography. A fast symmetric key is used to encrypt the large data file, and the slow asymmetric public key is used to encrypt and securely transmit the symmetric key itself.
3. Hashing and Message Authentication
Hash Functions: Map variable-length data to fixed-length hash codes without using keys. Provide one-way (pre-image), second pre-image, and collision-resistance properties. Examples include MD4, MD5, SHA-1, SHA-2, and SHA-3.
MAC (Message Authentication Code): A fixed-size data block generated with a shared secret key to assure both data integrity and origin authenticity.
HMAC: A MAC constructed using a hash function (e.g., $MAC_k(m) = h(k, m)$).
CBC-MAC: A MAC built using a block cipher in CBC mode, where the final encrypted block serves as the MAC.
Authenticated Encryption: A system providing confidentiality, integrity, and authenticity simultaneously (e.g., the Encrypt-then-MAC approach).
4. Authentication Types & Password Security
Authentication Factors: Categorised by Knowledge (what you know: passwords), Presence (what you are: biometrics), Possession (what you have: tokens/keys), and Involvement (what you are associated with: society).
Password Security Enhancements:
Salt: A random, non-secret string added to hashes to thwart dictionary attacks and rainbow tables.
Pepper: An additional secret value stored strictly in a Hardware Security Module (HSM).
Slow Hash Functions: Algorithms like bcrypt, scrypt, PBKDF2, and Argon2 use iteration to demand high CPU/memory, thwarting fast parallel brute-force guessing.
One-Time Passwords (OTPs): Passwords valid for only a single use to prevent replay eavesdropping.
HOTP: Boundless OTP generated from a secret key and an incrementing counter.
TOTP: Based on HOTP, but substitutes the counter with a time-step (e.g., every 30 seconds).
FIDO (Fast IDentity Online):
UAF: A framework for true passwordless authentication using a local device (e.g., biometrics).
U2F: Augments standard passwords with a second physical factor (e.g., hardware USB key).
5. Key Establishment & Authentication Protocols
Challenge-Response: The verifier sends a fresh, unpredictable nonce; the claimant must respond with a calculation utilizing their secret. This guarantees "recent aliveness" and prevents replay attacks.
AKE (Authenticated Key Exchange): Protocols that simultaneously establish a shared session key while verifying both parties' identities.
Needham-Schroeder Protocol: Uses a trusted central Key Distribution Centre (KDC) to safely establish symmetric session keys between parties in a hub-and-spoke network.
Kerberos: A highly practical, ticket-based mutual authentication system born from Needham-Schroeder. It implements timestamps to definitively resist replay attacks and handles Single Sign-On (SSO).
STS (Station-to-Station): Upgrades basic Diffie-Hellman by forcing parties to swap Digital Signatures over their public keys. This thwarts active MITM adversaries.
Dolev-Yao Adversary Model: A standard framework where the attacker fully controls the communications network (eavesdropping, injecting, modifying, impersonating) but cannot magically break cryptographic primitives without the keys.
6. Network Security & PKI
X.509 Digital Certificates: A standardized data structure that binds a public key to an entity's identity, authenticated via a signature from a Certificate Authority (CA).
PKI Trust Models: Establish how certificates are verified. Include Single CA, Strict Hierarchy (clear chains to a Root of Trust), and Forest Model (the disjoint tree approach used by modern web browsers).
Certificate Revocation: Handling compromised keys via Certificate Revocation Lists (CRLs), partitioned CRLs, Online Certificate Status Protocol (OCSP), OCSP-Stapling (web server fetches the status), or using Short-lived Certificates.
TLS (Transport Layer Security): Defends data in transit. Establishes a secure connection via a Handshake (negotiating ciphersuites, key derivation, and CA validation) and then performs Data Transfer utilizing records and MACs. It ensures Forward Secrecy—compromising a current key does not expose old session data.
VPNs (Virtual Private Networks): Packages data payloads over public networks via encrypted tunnels. It features Transport Mode (Host-to-host) and Tunnel Mode (Network-to-network/host).
SSH (Secure Shell): Application-layer protocol for secure remote command execution and administration. Trusts host keys via TOFU (Trust On First Use) or CA-certified models.
7. Operating System & Disk Security
Memory Protection: OS logic that enforces process isolation, supervisor versus user privilege modes, and strict boundary access control.
Access Control Models:
DAC (Discretionary Access Control): The resource owner dictates who gains access (e.g., standard Unix/Linux UGO permissions).
RBAC (Role-Based Access Control): Permissions are assigned strictly to roles, and users inherit those permissions by acting in that role.
MAC (Mandatory Access Control): Rigid model where access is gated by a central authority and predefined security clearances.
ACLs vs. Capability Lists: Access Control Lists define permissions categorized by the object (who can touch this file?), whereas Capability Lists define permissions by the subject (what files can this user touch?).
Disk Encryption:
FSE (File System Encryption): Encrypts individual files/directories tied to user credentials, retaining metadata in plaintext.
FDE (Full Disk Encryption): Transparently encrypts the entire block device via a singular master media key before the OS boots.
AES-XTS: An advanced AES mode explicitly designed for disk sectors. It incorporates position-based "tweaks" to prevent identical blocks from creating identical ciphertext and prevents error propagation between blocks.