160 likes | 793 Views
Strong Password Protocols. CS 519 Cryptography and Network Security Instructor: Ali Aydin Selcuk. Password Protocols. Humans are incapable of remembering strong, random cryptographic keys; hence weak secrets (passwords/PINs) Risks of password protocols: Eavesdropping (*)
E N D
Strong Password Protocols CS 519 Cryptography and Network Security Instructor: Ali Aydin Selcuk Strong Password Protocols
Password Protocols • Humans are incapable of remembering strong, random cryptographic keys; hence weak secrets (passwords/PINs) • Risks of password protocols: • Eavesdropping (*) • Online password guessing: easy to defend • Offline password guessing (dict.attack): possibly with active impersonation • Server database disclosure (+ dict.attack) Strong Password Protocols
Password Protocols • Send pwd, compare against h(pwd) • Send h(pwd), compare against h(pwd) • Send h(pwd), compare against h(h(pwd)) • Use h(pwd) as the key in a C-R protocol; server stores h(pwd). (why not h(h(pwd))?) (What are the limitations of each?) • Lamport’s hash (S/KEY) • Strong password protocols Strong Password Protocols
Lamport’s Hash • Server stores <username, n, Hn(password)> • Workstation sends Hn-1(password) • If successful, n is decremented Alice Alice, pwd Alice’s terminal n Alice Bob Hn-1(password) Strong Password Protocols
Lamport’s Hash Salting: • Hn-1(pwd|salt) is used for authentication • Salt is installed with the server at setup time.Sent by the server along with n. • Advantages: • Easy password reset • Using same password over different servers • Slows down dictionary attacks Strong Password Protocols
Lamport’s Hash Properties: • Safe against eavesdropping, database reading • No mutual authentication (login only) • Small n attack: Intruder sends n’ < n Defense: Alice verifies displayed n value • Can be used from dumb terminals as well (human-paper setting) Strong Password Protocols
Strong Password Protocols • Achieving benefits of cryptographic authentication while users remember only weak secrets (passwords). • Problems of password protocols: • Eavesdropping • Offline password guessing (dictionary attacks) • Server database disclosure Strong Password Protocols
Encryption-with-Password Protocols A basic protocol: Problems: • Dictionary attack (from R & W{R}) • Server database disclosure share weak secret W = f(pwd) “Alice” Alice Bob challenge R W{R} Strong Password Protocols
share weak secret W = f(pwd) Enhanced with PKC: E & D: public/private key pair generated per-session (by the terminal) • Why not possible with secret key encryption? • What is the weakness in this protocol? (Passive attack? Active attack?) “Alice”, E Alice Bob E{R} W{R} Strong Password Protocols
share weak secret W = f(pwd) How about this one? • Is an active attack still possible? (What if encryption E{.} is deterministic or randomized?) • One of the W{.} encryptions can be removed. “Alice”, W{E} Alice Bob W{E{R}} R Strong Password Protocols
Encrypted Key Exchange (EKE) • Key establishment as well as authentication: “Alice”, W{E} W{E{KAB}} RA Alice Bob KAB{RA}, RB KAB{RB} Strong Password Protocols
EKE Why per session E/D ? • Dictionary attack if E is known. • Replay attack possible from server side. Why encrypt a “public” key (i.e. W{E}) ? • Authentication • In fact, one of W{.} can be removed. (Then the non-encrypting side should not issue the first challenge.) Risk of W{E}: Public keys can easily be distinguished from random string; enabling a dictionary attack. Risk of W{E{KAB}}: E-residue attack. Strong Password Protocols
EKE with Diffie-Hellman “Alice”, W{ga mod p} • Why are “public” ga, gb encrypted? W{gb mod p}, RB (KAB = gab mod p) Alice Bob RA, KAB{RB} KAB{RA} Strong Password Protocols
Augmented EKE • EKE vulnerable to database disclosure(since server has to store W) • Augmented EKE: defense against this threat • Client has to know the password. Server stores a one-way derivation of it. Strong Password Protocols
“Alice”, ga mod p gb mod p, H(gab mod p, gbW mod p) Alice Bob H’(gab mod p, gbW mod p) Augmented D-H EKE Server stores gW mod p • How does this protocol protect against database disclosure? • Why is this protocol not secure? Strong Password Protocols
Alternative Approaches Things become easy if server has a long-term public key, securely distributed. Password exchange or C-R can take place over a secured channel. • Gong, Lomas, Needham, Saltzer(’93): server’s public key is installed at terminals in advance. • SSL: server’s PK is distributed by certificates. • SSH: weak authentication (by “leap of faith”) Strong Password Protocols