Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS

Similar documents
Private-Key Encryption

Plaintext Recovery Attacks Against WPA/TKIP

Big Bias Hunting in Amazonia: Large-scale Computation and Exploitation of RC4 Biases

TLS Security Where Do We Stand? Kenny Paterson

All Your Biases Belong To Us: Breaking RC4 in WPA-TKIP and TLS

Cryptography. Dr. Michael Schneider Chapter 10: Pseudorandom Bit Generators and Stream Ciphers

Plaintext-Recovery Attacks Against Datagram TLS

Full Plaintext Recovery Attack on Broadcast RC4

Attacks on SSL/TLS. Applied Cryptography. Andreas Hülsing (Slides mostly by Ruben Niederhagen) Dez. 6th, 2016

CIS 4360 Secure Computer Systems Symmetric Cryptography

Computer Security. 10r. Recitation assignment & concept review. Paul Krzyzanowski. Rutgers University. Spring 2018

Randomness Extractors. Secure Communication in Practice. Lecture 17

CNIT 124: Advanced Ethical Hacking. Ch 9: Password Attacks

Authenticated Encryption

CHAPTER 2. KEYED NON-SURJECTIVE FUNCTIONS IN STREAM CIPHERS54 All bytes in odd positions of the shift register are XORed and used as an index into a f

Transport Level Security

Stream Ciphers. Stream Ciphers 1

Message authentication codes

Stream Ciphers - RC4. F. Sozzani, G. Bertoni, L. Breveglieri. Foundations of Cryptography - RC4 pp. 1 / 16

Network Security. Security in local-area networks. Radboud University Nijmegen, The Netherlands. Autumn 2014

Implementing Cryptography: Good Theory vs. Bad Practice

Network Security. Security in local-area networks. Radboud University, The Netherlands. Spring 2017

Cryptography. Summer Term 2010

A Surfeit of SSH Cipher Suites

Lucky Microseconds: A Timing Attack on Amazon s s2n Implementation of TLS

RC4. Invented by Ron Rivest. A stream cipher Generate keystream byte at a step

Symmetric Cryptography

Symmetric encrypbon. CS642: Computer Security. Professor Ristenpart h9p:// rist at cs dot wisc dot edu

COMPOSABLE AND ROBUST OUTSOURCED STORAGE

ScienceDirect. Efficient FPGA Implementation of the RC4 Stream Cipher using Block RAM and Pipelining

Information Security CS526

Release note Tornaborate

L5: Basic Grammar Based Probabilistic Password Cracking

Passwords. CS 166: Introduction to Computer Systems Security. 3/1/18 Passwords J. Liebow-Feeser, B. Palazzi, R. Tamassia, CC BY-SA 2.

HTTPS is Fast and Hassle-free with Cloudflare

Network Security. Security in local-area networks. Radboud University Nijmegen, The Netherlands. Autumn 2014

Key Reinstallation Attacks: Forcing Nonce Reuse in WPA2. Mathy Vanhoef, PhD Wi-Fi Alliance meeting Bucharest, 24 October 2017

Lecture 9a: Secure Sockets Layer (SSL) March, 2004

Introduction to Cryptography. Lecture 3

The Salsa20 Family of Stream Ciphers

Stream Ciphers An Overview

Cryptography and secure channel. May 17, Networks and Security. Thibault Debatty. Outline. Cryptography. Public-key encryption

Permutation-based Authenticated Encryption

PRACTICAL PASSWORD AUTHENTICATION ACCORDING TO NIST DRAFT B

Stream ciphers. Lecturers: Mark D. Ryan and David Galindo. Cryptography Slide: 91

Information Security CS526

Cipher Suite Configuration Mode Commands

Cryptography CS 555. Topic 8: Modes of Encryption, The Penguin and CCA security

TLS (TRANSPORT LAYER SECURITY) PROTOCOL

Course Business. Homework due today Final Exam Review on Monday, April 24 th Practice Final Exam Solutions Released Monday

Scanned by CamScanner

Cryptographic Concepts

Initial connection setup. Adding subflow setup. Three-way handshake with MP_CAPABLE Exchange 64 bit key(key-a, Key-B)

COPACOBANA: RECONFIGURABLE COMPUTING IN CRYPTANALYSIS. Ben Johnstone

Wireless Security. Comp Sci 3600 Security. Attacks WEP WPA/WPA2. Authentication Encryption Vulnerabilities

Analyzing Wireless Security in Columbia, Missouri

Security Models: Proofs, Protocols and Certification

Implementing Practical leakage-resilient symmetric cryptography. University of Illinois at Chicago, Technische Universiteit Eindhoven

Cryptography and Network Security

L13. Reviews. Rocky K. C. Chang, April 10, 2015

Symmetric and Password- based encrypdon. CS642: Computer Security. Professor Ristenpart h9p:// rist at cs dot wisc dot edu

WAP Security. Helsinki University of Technology S Security of Communication Protocols

CS 356 Internet Security Protocols. Fall 2013

Secure Internet Communication

page 1 Introduction to Cryptography Benny Pinkas Lecture 3 November 18, 2008 Introduction to Cryptography, Benny Pinkas

05 - WLAN Encryption and Data Integrity Protocols

SSL/TLS & 3D Secure. CS 470 Introduction to Applied Cryptography. Ali Aydın Selçuk. CS470, A.A.Selçuk SSL/TLS & 3DSec 1

CS 393 Network Security. Nasir Memon Polytechnic University Module 12 SSL

Overview of Security

Cryptography Functions

Phoenix: Rebirth of a Cryptographic Password-Hardening Service

Cryptography MIS

Cache Timing Analysis of LFSR-based Stream Ciphers

This Security Policy describes how this module complies with the eleven sections of the Standard:

Homework 2: Symmetric Crypto Due at 11:59PM on Monday Feb 23, 2015 as a PDF via websubmit.

Crypto: Passwords and RNGs. CS 642 Guest Lecturer: Adam Everspaugh

Introduction and Overview. Why CSCI 454/554?

Distributed Systems. 26. Cryptographic Systems: An Introduction. Paul Krzyzanowski. Rutgers University. Fall 2015

Set Up with Microsoft Outlook 2013 using POP3

Block Ciphers Tutorial. c Eli Biham - May 3, Block Ciphers Tutorial (5)

New attacks on the MacDES MAC Algorithm. 1st July Two new attacks are given on a CBC-MAC algorithm due to Knudsen and Preneel, [2],

A Brief Outlook at Block Ciphers

Verifying Real-World Security Protocols from finding attacks to proving security theorems

CSC 474/574 Information Systems Security

Presentation_ID. 2001, Cisco Systems, Inc. All rights reserved.

Distributed Key Management and Cryptographic Agility. Tolga Acar 24 Feb. 2011

Cryptography CS 555. Topic 11: Encryption Modes and CCA Security. CS555 Spring 2012/Topic 11 1

TLS connection management & application support. Giuseppe Bianchi

A Protocol for Secure Public Instant Messaging

Encryption. INST 346, Section 0201 April 3, 2018

06/02/ Local & Metropolitan Area Networks. 0. Overview. Terminology ACOE322. Lecture 8 Network Security

Distributed Systems. 25. Authentication Paul Krzyzanowski. Rutgers University. Fall 2018

CS-435 spring semester Network Technology & Programming Laboratory. Stefanos Papadakis & Manolis Spanakis

Maximizing the speed of time based SQL injection data retrieval

Cryptography: Symmetric Encryption (finish), Hash Functions, Message Authentication Codes

ECE 646 Lecture 7. Modes of Operation of Block Ciphers. Modes of Operation. Required Reading:

Tel Aviv University. The Iby and Aladar Fleischman Faculty of Engineering

Slides by Kent Seamons and Tim van der Horst Last Updated: Oct 7, 2013

Enhancing Security of Improved RC4 Stream Cipher by Converting into Product Cipher

CS November 2018

Transcription:

Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Christina Garman Kenny Paterson Thyla van der Merwe Johns Hopkins University Royal Holloway, University of London 12 August 2015 Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 1/ 19

Motivation Despite AlFardan-Bernstein-Paterson-Poettering-Schuldt (USENIX 2013), RC4 usage stood at 35% of TLS connections ICSI$Notary$Sta+s+cs$[Dec.,$2014]$ h9p://notary.icsi.berkeley.edu/$ Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 2/ 19

Motivation Despite AlFardan-Bernstein-Paterson-Poettering-Schuldt (USENIX 2013), RC4 usage stood at 35% of TLS connections Can we strengthen these attacks? Passwords are widely used for authentication and the fact that they are not uniformly distributed may give us a boost Get RC4 closer to the point where it needs to be abandoned! Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 2/ 19

RC4 in TLS h:p tcp Applica7on Transport Internet Data Link TLS C S ClientHello(,[RC4, ]) Handshake protocol ServerHello(,RC4) K u, K d... K u, K d ClientFinshed C r = P r Z r. ServerFinshed Record protocol (encrypted with RC4, keys K u and K d ) Integrity, HMAC- SHA1 36 protected FINISHED bytes applica7on data... Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 3/ 19

RC4 Biases 255 INFILE using 1:2:(max(min(4194304*$3,1.0),-1.0)) 1 224 Byte value, Position 2 [0...255] 192 160 128 96 64 0.5 0-0.5 32 0 0 32 64 96 128 160 192 224 255 Byte value, Position 1 [0...255] -1 Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 4/ 19

Attack Setting First described by Mantin and Shamir in 2001 A fixed plaintext, P, is encrypted multiple times under independent RC4 keys, K i P,#K 1# P,#K S# Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 5/ 19

Plaintext Recovery via Bayesian Analysis We want to maximize (for a position in the plaintext stream r): Pr(X = x C = c) X is the random variable corresponding to a plaintext byte, x C is the random variable corresponding to a vector of ciphertext bytes Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 6/ 19

Plaintext Recovery via Bayesian Analysis Using Bayes Theorem: Pr(X = x C = c) = = Pr(C = c X = x) Pr(X = x) Pr(C = c) Pr(C = c X = x) Pr(X = x) x X Pr(C = c X = x ) Pr(X = x ) Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 6/ 19

Plaintext Recovery via Bayesian Analysis So we actually want to maximize this: Pr(C = c X = x) Pr(X = x) However, and it suffices to maximize: Pr(C = c X = x) = Pr(Z = z) Pr(X = x) Pr(Z = z) Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 6/ 19

Plaintext Recovery via Bayesian Analysis C1( C2( encryp7ons(of(fixed(byte(( under(different(keys( r"" byte(candidate(( (x(" x" x" yields(induced(distribu7on(on( keystream(bytes(z r" combine(with(known(distribu7on( C3( x" CS(...(( x"...(( Combine(with(a"priori"plaintext( distribu7on(( Recovery(algorithm:(( Compute(most(likely(byte(by(( considering(all(byte(possibili7es( ( a"posteriori"likelihood(of(x(being(( correct(byte( Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 7/ 19

Attacking Cookies [ABPPS13] C1( C2( encryp7ons(of(fixed(byte(( under(different(keys( r"" byte(candidate(( (x(" x" x" yields(induced(distribu7on(on( keystream(bytes(z r" combine(with(known(distribu7on( C3( x" CS(...(( x"...(( assume(a"priori"plaintext( distribu7on(uniform( Recovery(algorithm:(( Compute(most(likely(byte(by(( considering(all(byte(possibili7es( ( Repeat(for(all(bytes(of(the(cookie( a"posteriori"likelihood(of(x(being(( correct(byte( ((256(posi7ons,(2 34 (encryp7ons,(2000(hrs!( Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 8/ 19

Attacking Passwords Widely used for authentication on the web, NOT uniformly distributed RockYou leak of 32 million passwords in 2009, about 14 million unique, 123456 most popular Have a priori information from leaked datasets Multiple bytes, not just one... Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 9/ 19

Attacking Passwords For n bytes we want to maximize Pr(X = x) Pr(Z = z) where X is the random variable corresponding to a vector of plaintext bytes, x = (x 0, x 1,..., x n 1 ) Z is the random variable corresponding to the matrix of keystream bytes?? Pr(Z = z)?? Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 10/ 19

Attacking Passwords For n bytes we want to maximize Pr(X = x) Pr(Z = z) where X is the random variable corresponding to a vector of plaintext bytes, x = (x 0, x 1,..., x n 1 ) Z is the random variable corresponding to the matrix of keystream bytes?? Pr(Z = z)?? Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 10/ 19

Approximations Pr(Z%=%z)%% A"ack&1:&& Assume&keystream&bytes&behave& independently& &use&single6byte&probabili8es& (product&distribu8on)& A"ack&2:&& Assume&keystream&byte&is&influenced&only&by& byte&directly&adjacent&to&it& &use&double6&and& single6byte&probabili8es& (Picture of the double-byte biases, 2 44 keystreams, 4800 core-days) Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 11/ 19

Approximations Pr(Z%=%z)%% A"ack&1:&& Assume&keystream&bytes&behave& independently& &use&single6byte&probabili8es& (product&distribu8on)& A"ack&2:&& Assume&keystream&byte&is&influenced&only&by& byte&directly&adjacent&to&it& &use&double6&and& single6byte&probabili8es& (Picture of the double-byte biases, 2 44 keystreams, 4800 core-days) Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 11/ 19

Approximations encryp8ons(of(fixed(password(( under(different(keys( r,"r+1,,"r+n11" password(candidate(( (x(=(x 0",x 1",,"x n " yields(induced(distribu8on(on( keystream(bytes(z r,z r+1,,z r+n11"" C1( C2( x 0,"x 1,","x n " x 0,"x 1,","x n " combine(with(known(distribu8on( C3( x 0,"x 1,","x n " CS(...(( x 0,"x 1,","x n "...(( approximate!using!known!! distribu:on! combine(with(a"priori"password( distribu8on(!recovery!algorithm:!( (Compute(most(likely(password(from(((( (dic8onary(of(n(passwords( a"posteriori"likelihood(of(x(being(( correct(password( Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 12/ 19

What s different? n bytes instead of one T attempts before lockout dictionary of size N single-byte vs double-byte estimator Base64 or ASCII r starting position S ciphertexts guessing attacks Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 13/ 19

Simulation Results Use a dictionary built from RockYou leak dataset to attack Singles.org dataset More realistic but limits our success rate Default parameters, n = 6, T = 5, S = 2 20, 2 22,..., 2 28 Success rate based on 256 experiments Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 14/ 19

Simulation Results Single-byte vs double-byte, n = 6, T = 5 Success Rate 1 0.8 0.6 0.4 db, 2 20 db, 2 22 db, 2 24 db, 2 26 db, 2 28 sb, 2 20 sb, 2 22 sb, 2 24 sb, 2 26 sb, 2 28 0.2 0 0 64 128 192 256 Starting Position Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 15/ 19

Simulation Results T vs success rate, n = 6, r = 133 - double-byte and guessing log 2 (T) 25 20 15 10 2 14 2 16 2 18 2 20 2 22 2 24 2 26 2 28 optimal guessing 5 0 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Recovery Rate Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 16/ 19

Practical Validation Applicable to BasicAuth and IMAP We need multiple, independent encryptions of the password We need the password to be encrypted at a favourable position Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 17/ 19

Practical Validation r = 133! www.evil.com! PW! PW = 123456! TLS channel! www.good.com! Resumption latency of 250ms, 2 26, 6 parallel connections, 776 hours (at 100ms, 312 hours) Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 18/ 19

Closing Remarks Made use of a generally applicable Bayesian inference technique Strengthened the results of AlFardan et al., good recovery rates at 2 26 vs. 2 34 ciphertexts and an attack time of 312 vs. 2000 hours ICSI$Notary$Sta+s+cs$[Jul./Aug.,$2015]$ h=p://notary.icsi.berkeley.edu/$ 12.8% of TLS connections make use of RC4 Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 19/ 19

Closing Remarks Made use of a generally applicable Bayesian inference technique Strengthened the results of AlFardan et al., good recovery rates at 2 26 vs. 2 34 ciphertexts and an attack time of 312 vs. 2000 hours DEC$ 2015$ FEB$ MAR$ JULY$ NOW$ Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 19/ 19

Closing Remarks Made use of a generally applicable Bayesian inference technique Strengthened the results of AlFardan et al., good recovery rates at 2 26 vs. 2 34 ciphertexts and an attack time of 312 vs. 2000 hours DEC$ 2015$ FEB$ MAR$ JULY$ NOW$ We need to stop using RC4! Attacks Only Get Better: Password Recovery Attacks Against RC4 in TLS Thyla van der Merwe 19/ 19