Authentication Protocols
Exam Information
- The upcoming exam will cover the second part of the course, focusing on public key cryptography.
- The exam will only cover topics taught in class.
- Assignment 5 grades will be available before the exam.
- Assignment 6 grades may not be available before the exam.
- A study guide will be provided over the weekend.
Authentication Protocols
- Focus has been on ensuring secrecy and integrity of messages.
- Private key setting: Private key cryptosystems for encryption, Message Authentication Codes (MACs) for integrity.
- Public key setting: Public key systems for encryption, digital signature schemes for integrity.
- Today's topic: Authentication protocols for authenticating users, not messages
- Authentication: Proving you are who you claim to be (e.g., logging into a computer).
- Alice and Bob can be humans or computers; authentication can be one-way or mutual.
- Mutual authentication: Both parties prove their identities to each other.
- Session key: A key used only for the current session, discarded afterward; not a long-term key.
- Additional requirements:
- Use of symmetric or public keys only.
- Use of only a hash function.
- Anonymity, plausibility, deniability, and other constraints.
- Problem: Verifying identity of the person you are talking to online.
- Example: Minnesota state senator case where he thought he was communicating with an underage girl, but it was an FBI agent. Illustrates the importance of authenticating users.
Authentication on Standalone vs. Networked Computers
- Standalone computer: Authentication via login name and password; relatively straightforward.
- Network: More complex; sending login and password over the network in plain form is insecure.
- Replay attack: Observing network traffic and reusing the captured information to impersonate someone.
- Adversary types:
- Passive: Can only observe network traffic.
- Active: Can modify network traffic.
Simple Authentication Protocol
- Alice says, "I am Alice."
- Bob says, "Prove it."
- Alice sends her password, "Frank."
- Problem: Password is sent in plain text over the network.
- Vulnerable to replay attack.
Replay Attack Example
- Alice says, "I am Alice."
- Bob says, "Prove it."
- Alice sends her password, "Frank."
- Trudy (troublemaker) observes the communication.
- Trudy learns Alice's password.
- Trudy contacts Bob, says "I am Alice," and provides the password "Frank."
- Bob verifies the password and grants Trudy access.
Preventing Replay Attacks
- Improved protocol (but still insecure):
- Alice sends, "I am Alice, and my password is Frank."
- Still vulnerable to replay attack.
Using Hash Functions
- Alice says, "I am Alice."
- Bob says, "Prove it."
- Alice sends a hash of her password, .
- Bob computes and compares with Alice's sent hash.
- Since H is preimage resistant, it's difficult for Trudy to determine the password from .
*Problem: Trudy can still replay the hashed password.
Challenge-Response Protocol
- Bob issues a unique challenge to Alice that only Alice can answer.
- Prevents replay attacks because the challenge is different each time.
- Uses a nonce (number used only once).
Nonce-Based Protocol
- Alice says, "I am Alice."
- Bob sends a nonce, .
- Alice sends , where is concatenation.
- Bob computes and compares it with Alice's sent hash.
- Trudy cannot replay the response because the nonce is different each time.
*Bob needs to know Alice's password.
Challenge-Response Protocol Requirements
- Challenge must be new each time.
- Response must be something only Alice can produce.
- Response must be verifiable by Bob.
Using Symmetric Key Encryption
Notation: (encryption of plaintext p with key k gives ciphertext c), (decryption).
Assumptions: Underlying cryptosystem is secure.
Symmetric Key Authentication Protocol
- Alice and Bob share a common key, , known only to them.
- Alice says, "I am Alice."
- Bob sends a random number (nonce), .
- Alice sends .
- Bob encrypts with and compares with Alice's response.
- Secure method for Bob to authenticate Alice.
- Alice does not authenticate Bob.
Mutual Authentication
- Both Alice and Bob authenticate each other.
Attempted Mutual Authentication Protocol (Insecure)
- Alice says, "I am Alice" and sends a random number .
- Bob sends .
- Alice sends .
- Problem: Alice can send back the same message she received from Bob without knowing .
- Anyone can impersonate Alice.
Secure Mutual Authentication Protocol
- Alice says, "I am Alice" and sends random number .
- Bob sends .
- Bob sends a random number .
- Alice sends .
- Alice authenticates Bob by verifying .
- Bob authenticates Alice by verifying .
Grandmaster Chess Analogy
*One can draw with grandmasters in chess without knowing strategy using simple mimicking tactics.
Insecurity of Authentication Protocol Illustrated
*An attack can occur with concurrent sessions and Trudy mimicking moves in sessions
Mutual Authentication Protocol
- Alice says, "I am Alice" and sends random number .
- Bob sends .
- Bob sends a random number .
- Alice sends .
Mutual Authentication with Public Key Encryption
- Notation:
- means M is encrypted with Alice's public key.
- means M is signed with Alice's private key.
- Alice says, "I am Alice" .
- Bob sends .
- Alice sends .
- Problem: Alice is decrypting a message, which could be exploited.
*Bob is authenticating Alice but it opens the door to Trudy getting Alice to decrypt a message for her.
*Must use two different key pairs to avoid exploitation.
Public Key Authentication using Digital Signatures
- Alice says, "I am Alice" .
- Bob sends random number .
- Alice sends .
- Bob verifies Alice's signature.
- Only one-way authentication.
- Alice is signing a message, which could have unintended consequences.
Session Keys
- After authentication, a session key is used for secure communication.
- Often a symmetric key.
- Perfect forward secrecy: If the secret key is later compromised, previous communications remain secure.
Session Key Exchange (Insecure)
- Alice says, "I am Alice" and gives random number .
- Bob selects session key and sends .
- Alice sends .
- Problem: Does not achieve mutual authentication.
- Anyone could send the second message.
Mutual Authentication and Session Key Exchange
- Alice says, "I am Alice" and gives random number .
- Bob selects session key and sends .
- Alice sends .
- Provides mutual authentication.
- However, session key is sent in plain text (signed but not encrypted).
Secure Mutual Authentication and Session Key Exchange
- Alice says, "I am Alice" and gives random number .
- Bob selects session key and sends .
- Alice sends .
- Provides mutual authentication and a secret session key.
Alternative Approach
- Alice sends random number .
- Bob selects session key and sends .
- Alice sends .
- Also provides secure session key and mutual authentication.
Perfect Forward Secrecy
- Even if long-term keys are compromised, past session keys remain secret.
Perfect Forward Secrecy in Private Key Setting
- Alice and Bob share common key .
- Trudy records all ciphertext messages.
- Later, Trudy learns .
- Goal: Trudy should not be able to decrypt recorded messages.
Session Key Exchange (Insecure for Perfect Forward Secrecy)
- Alice encrypts session key with and sends to Bob.
- All subsequent messages encrypted with .
- Problem: Trudy can decrypt the first message to obtain .
Using Diffie-Hellman for Perfect Forward Secrecy
- Use Diffie-Hellman key exchange to establish session key.
- Alice sends to Bob.
- Bob sends to Alice.
- Session key is .
- Ephemeral: Alice and Bob forget and after the session.
*Man in the Middle Attack is possible