Understanding the WPA/WPA2 Break



Similar documents
WEP Overview 1/2. and encryption mechanisms Now deprecated. Shared key Open key (the client will authenticate always) Shared key authentication

12/3/08. Security in Wireless LANs and Mobile Networks. Wireless Magnifies Exposure Vulnerability. Mobility Makes it Difficult to Establish Trust

Authentication in WLAN

Lecture Objectives. Lecture 8 Mobile Networks: Security in Wireless LANs and Mobile Networks. Agenda. References

Security (WEP, WPA\WPA2) 19/05/2009. Giulio Rossetti Unipi

Key Hopping A Security Enhancement Scheme for IEEE WEP Standards

Wireless Networks. Welcome to Wireless

Security+ Guide to Network Security Fundamentals, Third Edition. Chapter 6. Wireless Network Security

Hole196 Vulnerability in WPA2

Cipher Suites and WEP

Overview. Summary of Key Findings. Tech Note PCI Wireless Guideline

Introduction to WiFi Security. Frank Sweetser WPI Network Operations and Security

Table of Contents. Cisco Wi Fi Protected Access 2 (WPA 2) Configuration Example

Chapter 6 CDMA/802.11i

Configuring Security Solutions

CS 356 Lecture 29 Wireless Security. Spring 2013

White paper. Testing for Wi-Fi Protected Access (WPA) in WLAN Access Points.

Symm ym e m t e r t ic i c cr c yptogr ypt aphy a Ex: RC4, AES 2

Vulnerabilities of Wireless Security protocols (WEP and WPA2)

A SURVEY OF WIRELESS NETWORK SECURITY PROTOCOLS

WiFi Security Assessments

CS5490/6490: Network Security- Lecture Notes - November 9 th 2015

CS 336/536 Computer Network Security. Summer Term Wi-Fi Protected Access (WPA) compiled by Anthony Barnard

WLAN w Technology

Security in IEEE WLANs

Attack Lab: Attacks on TCP/IP Protocols

IPsec Details 1 / 43. IPsec Details

COMPARISON OF WIRELESS SECURITY PROTOCOLS (WEP AND WPA2)

WPA Migration Mode: WEP is back to haunt you...

Wireless Security. Jason Bonde ABSTRACT. 2. BACKGROUND In this section we will define the key concepts used later in the paper.

Enterprise A Closer Look at Wireless Intrusion Detection:

Wireless Pre-Shared Key Cracking (WPA, WPA2)

Cryptanalysis of IEEE i TKIP

Research In Motion D. Stanley, Ed. Aruba Networks March 2009

Wireless Local Area Networks (WLANs)

How To Analyze The Security On An Ipa Wireless Sensor Network

How To Protect A Wireless Lan From A Rogue Access Point

Methodology: Security plan for wireless networks. By: Stephen Blair Mandeville A. Summary

Wireless security. Any station within range of the RF receives data Two security mechanism

Session Hijacking Exploiting TCP, UDP and HTTP Sessions

VPN. Date: 4/15/2004 By: Heena Patel

WI-FI SECURITY: A LITERATURE REVIEW OF SECURITY IN WIRELESS NETWORK

Offensive Security. Wireless Attacks - WiFu

Your Wireless Network has No Clothes

Wi-Fi Protected Access: Strong, standards-based, interoperable security for today s Wi-Fi networks Wi-Fi Alliance April 29, 2003

The Trivial Cisco IP Phones Compromise

Wireless USB Adapter

NXC5500/2500. Application Note w Management Frame Protection. ZyXEL NXC Application Notes. Version 4.20 Edition 2, 02/2015

chap18.wireless Network Security

WIRELESS SECURITY. Information Security in Systems & Networks Public Development Program. Sanjay Goel University at Albany, SUNY Fall 2006

Useful CLI Commands. Contents. Enable Logging

Wireless LAN Pen-Testing. Part I

Attacks against the WiFi protocols WEP and WPA

The Wireless Network Road Trip

Wireless Security: Secure and Public Networks Kory Kirk

The Importance of Wireless Security

Lecture 2 Secure Wireless LAN

Network Security. Security of Wireless Local Area Networks. Chapter 15. Network Security (WS 2002): 15 Wireless LAN Security 1 Dr.-Ing G.

Vulnerabilities in WEP Christopher Hoffman Cryptography

Attacking Automatic Wireless Network Selection. Dino A. Dai Zovi and Shane A. Macaulay

Wireless Traffic Analysis. Kelcey Tietjen DF Written Report 10/03/06

Wi-Fi Client Device Security & HIPAA Compliance

Wireless Security with Cyberoam

Optimizing Converged Cisco Networks (ONT)

Chapter 2 Wireless Networking Basics

IEEE 802.1X For Wireless LANs

Configuration Notes Trapeze Networks Infrastructure in Ascom VoWiFi System

Topics in Network Security

WIRELESS NETWORKING SECURITY

Final exam review, Fall 2005 FSU (CIS-5357) Network Security

Quick Start Guide. WRV210 Wireless-G VPN Router with RangeBooster. Cisco Small Business

Lucent VPN Firewall Security in x Wireless Networks

TCP/IP Security Problems. History that still teaches

WIRELESS NETWORK SECURITY

How To Secure Your Network With 802.1X (Ipo) On A Pc Or Mac Or Macbook Or Ipo On A Microsoft Mac Or Ipow On A Network With A Password Protected By A Keyed Key (Ipow)

Wireless Security Overview. Ann Geyer Partner, Tunitas Group Chair, Mobile Healthcare Alliance

CSE 127: Computer Security. Network Security. Kirill Levchenko

Nokia E90 Communicator Using WLAN

Wireless Encryption Protection

Security (II) ISO : Security Architecture of OSI Reference Model. Outline. Course Outline: Fundamental Topics. EE5723/EE4723 Spring 2012

WIRELESS SECURITY TOOLS

0) What is the wpa handhake?

A Closer Look at Wireless Intrusion Detection: How to Benefit from a Hybrid Deployment Model

A COMPARITIVE ANALYSIS OF WIRELESS SECURITY PROTOCOLS (WEP and WPA2)

SY system so that an unauthorized individual can take over an authorized session, or to disrupt service to authorized users.

VPN Lesson 2: VPN Implementation. Summary

Understanding Wireless Security on Your Polycom SpectraLink 8400 Series Wireless Phones

Key Management (Distribution and Certification) (1)

A Transport Protocol for Multimedia Wireless Sensor Networks

VIDEO Intypedia012en LESSON 12: WI FI NETWORKS SECURITY. AUTHOR: Raúl Siles. Founder and Security Analyst at Taddong

Enterprise WLAN Architecture

WHITE PAPER. FortiWeb and the OWASP Top 10 Mitigating the most dangerous application security threats

DESIGNING AND DEPLOYING SECURE WIRELESS LANS. Karl McDermott Cisco Systems Ireland

1. discovery phase 2. authentication and association phase 3. EAP/802.1x/RADIUS authentication 4. 4-way handshake 5. group key handshake 6.

Transcription:

Understanding the WPA/WPA2 Break Joshua Wright josh@inguardians.com Office/Mobile: 401-524-2911 www.inguardians.com Understanding the WPA/WPA2 Break 2008, Joshua Wright 1

Your Speaker Joshua Wright, josh@inguardians.com Senior Security Analyst, InGuardians Author SANS Wireless Ethical Hacking course (SEC617) Senior SANS Instructor Wireless security enthusiast Wireless insecurity enthusiast Understanding the WPA/WPA2 Break 2008, Joshua Wright 2

Outline Attack Overview Attack Analysis Enterprise Defenses Summary, Question and Answer Understanding the WPA/WPA2 Break 2008, Joshua Wright 3

The Bad News Martin Beck from the Technical University of Dresden discovered a flaw in the TKIP protocol Assisted by Erik Tews from the Technical University of Darmstadt Allows an attacker to decrypt data to a wireless client, slowly Once a packet is decrypted, opportunity to transmit up to 7 forged packets of any content No authorization needed for success Understanding the WPA/WPA2 Break 2008, Joshua Wright 4

The Good News Not a key recovery attack Attacker can only decrypt one packet at a time; does not allow earlier/later frame decryption Does not affect AES-CCMP networks (required for FIPS 140-2) Workarounds will mitigate this flaw Not perfect, but will buy some time Some APs can be configured to mitigate this flaw (at some cost) Understanding the WPA/WPA2 Break 2008, Joshua Wright 5

Who Is Affected? All deployments of TKIP Regardless of WPA or WPA2 use Regardless of PSK or 802.1X/EAP authentication Current exploits target TKIP networks with QoS enabled QoS is required for much of 802.11n Understanding the WPA/WPA2 Break 2008, Joshua Wright 6

Attacker Opportunity Attacker can decrypt a plaintext packet from AP to station (not station to AP) Not more than 1 unknown byte per minute Any packet can be selected for partial data Targeting an ARP packet, between 14 and 17 unknown bytes 8 MIC, 4 ICV, 2-5 IP source and dest. Once plaintext is known, attacker can inject not more than 15 arbitrary packets ARP poisoning, DNS manipulation, TCP/SYN request Understanding the WPA/WPA2 Break 2008, Joshua Wright 7

Outline Attack Overview Attack Analysis Enterprise Defenses Summary, Question and Answer Understanding the WPA/WPA2 Break 2008, Joshua Wright 8

April 2003: TKIP Fixes WEP Flaw No replay protection with WEP Valid Packet Replay Time Replay Replay Valid packet, valid packet, valid packet, valid packet TKIP Sequence Counter (TSC) Time TSC 38 TSC 40 TSC 40 TSC 40 TSC 38, OK TSC 40 > 38,OK TSC 40 > 40? FAIL TSC 40 > 40? FAIL Sniff Understanding the WPA/WPA2 Break 2008, Joshua Wright 9

July 2005: QoS Complicates Matters QoS relies on the ability to reorder packets for delivery This requirement conflicts with TKIP sequence delivery Solution: Maintain multiple independent, unsynchronized sequence counters Data TSC 38 Voice TSC 39 Time Data TSC 40 Voice TSC 42 Data TSC 41 Data Queue TSC 38, OK TSC 40 > 38, OK TSC 41 > 40, OK Voice Queue TSC 39, OK TSC 42 > 39,OK Understanding the WPA/WPA2 Break 2008, Joshua Wright 10

Wait Really? They Did That? Yes, they really did. 802.11e displaced sequence enforcement across multiple queues (Wireless MultiMedia) This is a significant security failure The WMM author was informed and chose not to act to resolve Understanding the WPA/WPA2 Break 2008, Joshua Wright 11

802.11e Replay Attack 802.11e Queue Voice Video 3 Time 223 225 5 Sequence Counter Tracking #'s 225 223 BE BK 1 6 223 221 222 222 2 4 However, the sequence number became part of the per-packet hash (MIC). Changing the queue defeated sequence enforcement but made the packet invalid, DoS ing all stations on a target AP. Understanding the WPA/WPA2 Break 2008, Joshua Wright 12

WEP ICV Attack - ChopChop Integrity Check Value (ICV) WEP 32-bit CRC Vulnerable to modification and repeated guess until positive response observed (chopchop attack) Repeated to recover entire plaintext packet contents 1 WEP WLAN 200 byte packet 3 199 byte packet 3 FAIL, FAIL, FAIL, FAIL, PASS, FAIL, Sniff 199 byte guess 254 199 byte guess 199 byte guess 1 2 199 byte guess 0 198 byte guess 254 198 byte guess 198 byte guess 1 198 byte guess 0 4 Understanding the WPA/WPA2 Break 2008, Joshua Wright 13

Fixed(?) in TKIP TKIP adds a new per-packet hashing algorithm (MIC) known as Michael Weak algorithm, but best that could be accommodated on legacy WEP hardware Includes provision for countermeasures Two invalid MIC s within 60 seconds shuts down AP and STA s for 60 seconds Must pass ICV and TSC check first Understanding the WPA/WPA2 Break 2008, Joshua Wright 14

TKIP Encryption/Decryption Encryption Process Calculate MIC Calculate ICV Get Next TSC Encryption Key Calculation Encrypt P+MIC+ICV Plaintext Packet (P) P+MIC P+MIC+ICV TSC + Encrypted P+MIC+ICV Wireless Transmission TSC + Encrypted P+MIC+ICV Check TSC Valid Check ICV Valid Check MIC Valid Process Packet Drop Encryption Key Calculation Decrypt Data Drop Transmit Error Drop Decryption Process Understanding the WPA/WPA2 Break 2008, Joshua Wright 15

And This is Exploited How? ICV failure generates no network activity MIC failure causes the client to generate a notice the attacker can observe If MIC failure observed, ICV passed! Take a packet, chop last byte, guess fix and TX until MIC failure observed Wait 60 seconds to not trigger countermeasures Repeat for next-to-last byte Understanding the WPA/WPA2 Break 2008, Joshua Wright 16

TKIP Chopchop ICV Attack 68 bytes TKIP WLAN 4 MIC Failure 3 ICV Fail, DROP. ICV Fail, DROP. ICV Pass, MIC Fail, MIC Failure Report. 1 Sniff 67 byte guess 254 67 byte guess 67 byte guess 1 67 byte guess 0 2 1. Attacker captures TKIP encrypted packet that looks like ARP 2. Attacker removes last payload byte, invalidating ICV and MIC. Attempts to fix ICV with guess 0 and sends to station. 3. Client receives frame, most have ICV failures and are dropped. One passes ICV, but fails MIC. 4. A MIC failure message is sent to AP to coordinate Michael countermeasures. Though encrypted, attacker can observe this frame to identify valid ICV, revealing one byte of plaintext. Attacker waits 60 seconds to avoid MIC countermeasures, then repeats process with 66 byte packet. Continues until all packet plaintext is known. Understanding the WPA/WPA2 Break 2008, Joshua Wright 17

Attack Result Not more than 1 byte per minute decrypted ARP is mostly known plaintext Five bytes unknown assuming /24 (A.B.C.Y and A.B.C.Z) Also need to determine ICV and MIC values (12 bytes) Only 17 bytes to recover, 14 if network is known (RFC1918 guess?) Result: 68 bytes ARP, 8 bytes MIC, 4 bytes ICV known plaintext to the attacker in 14-17 minutes Understanding the WPA/WPA2 Break 2008, Joshua Wright 18

Another Michael Weakness Michael is invertible; you can determine the key from plaintext + MIC Attacker decrypts ARP, knows Michael key and can craft any packet up to 68 bytes Attacker can use other QoS queues where attacked TSC is lower to inject arbitrary packets into network (can target any destination or protocol) Injection is blind, attacker cannot decrypt responses Attacker can only inject up to 7 packets (3 other standard 802.11e queues and 4 non-standard) Potential for 15 injected packets, yet untested Understanding the WPA/WPA2 Break 2008, Joshua Wright 19

Practical TKIP Attack Example TKIP WLAN Internet 2. Attacker injects TCP SYN packets with source=4.1.1.2 testing common ports (443, 135, etc), up to 7 packets 4.1.1.2 3. Attacker s agent receives responses from victim, identifying open (SYN/ACK) and closed (FIN/ACK) ports. Opportunity for agent to complete 3-way handshake for further communication with the victim. 1. Attacker decrypts ARP packet, can inject up to 7 packets into network Other attack possibilities include: DNS manipulation Delivering UDP-based exploits ARP manipulation on LAN Understanding the WPA/WPA2 Break 2008, Joshua Wright 20

tkiptun-ng Attack tool in Aircrack-ng source repository Incomplete, doesn t work in current form Likely to implement attack described here, extracting plaintext, injecting new packets May be accompanied by TUN interface Attacker uses any tool to inject packets Understanding the WPA/WPA2 Break 2008, Joshua Wright 21

MIC DoS Attacks Easy Now Michael algorithm countermeasures AP must disconnect all stations and shutdown the network following two MIC failures within 60 seconds Very easy for an attacker to trigger, shutting down AP for 60 seconds DOT11-TKIP_MIC_FAILURE: TKIP Michael MIC failure was detected on a packet (TSC=0x0) received from [mac-address] Understanding the WPA/WPA2 Break 2008, Joshua Wright 22

Outline Attack Overview Attack Analysis Enterprise Defenses Summary, Question and Answer Understanding the WPA/WPA2 Break 2008, Joshua Wright 23

Defense Strategies (1) Best approach: migrate away from TKIP to AES-CCMP Will likely require moving to WPA2 Difficult to implement if you need to support any legacy devices Laptops and embedded devices (VoIP phones, handhelds, etc) Client re-configuration will be necessary, making this resource-intensive Active Directory simplifies deployment Understanding the WPA/WPA2 Break 2008, Joshua Wright 24

Defense Strategies (2) Forcing more frequent key rotation will limit how much plaintext can be derived Each minute of key life can be used to determine a byte of plaintext 4 minute key rotation = 4 bytes plaintext Consensus is to reduce key to 2 minutes Reducing key lifetime may burden AP This defense is the best immediate-term option, but requires testing to understand the impact to all devices. Understanding the WPA/WPA2 Break 2008, Joshua Wright 25

Product-Specific Steps Aruba Networks PTK and GTK rotation configure terminal aaa authentication dot1x <profilename> multicast-keyrotation unicast-keyrotation timer mkey-rotation-period 120 timer ukey-rotation-period 120 Trapeze Networks Disable QoS set radio-profile <name> qos-mode svp Motorola/Symbol wlan <WLAN> dot11i key-rotation enable wlan <WLAN> dot11i key-rotation-interval 120 Bluesocket Bluesocket plans to add a unicast key rotation mechanism to a future product release. Aerohive Networks Aerohive currently detects and logs Michael MIC failures and in the next maintenance release of HiveOS Aerohive is implementing a PTK rekey feature. Watch the Aerohive support page for more information. Cisco Autonomous 802.1X reauthenticate Warning: Significant negative impact dot1x timeout reauth-period 120 broadcast-key change 120 Cisco WLC 802.1X reauthenticate Warning: Significant negative impact config wlan session-timeout <wlanid> 120 devshell dot1xupdatebroadcastrekeytimer 120 Meru Networks Meru Networks did not respond to multiple requests for information. Understanding the WPA/WPA2 Break 2008, Joshua Wright 26

Defense Strategies (3) Disabling QoS support on an AP will defeat tools, does not solve issue Not an option for 802.11n High- Throughput (HT) networks Vendors may choose to fix TKIP with implementation hacks Keep an eye on your AP and client vendor software update pages Understanding the WPA/WPA2 Break 2008, Joshua Wright 27

Monitoring (1) WIDS technology can identify this attack You will need a software update to get new signature support Action: contact your WIDS vendor today: "When will you detect the TKIP ICV attack?" No signature in Kismet yet Log monitoring on AP s Cisco Autonomous APs DOT11-TKIP_MIC_FAILURE_REPORT: Received TKIP Michael MIC failure report from the station [mac-address] on the packet (TSC=0x0) encrypted and protected by [key] key Aruba Networks Received TKIP Micheal MIC Failure Report from the Station [mac addr] [bssid] [apnames] Understanding the WPA/WPA2 Break 2008, Joshua Wright 28

Monitoring (2) Aerohive APs AP detected Michael MIC failure in received frame from abb:ccdd:eeff(wifi0.1) for sta 1122:3344:5566(TKIP) Trapeze Networks Logging message not supplied before presentation deadline. Symbol/Motorola Station [MAC_ADDR] reported a TKIP message integrity check fail on wlan [WLAN_ID] Cisco Wireless LAN Controller Identifies DoS, not TKIP attack The AP '00:0b:85:67:6b:b0' received a WPA MIC error on protocol '1' from Station '00:13:02:8d:f6:41'. Counter measures have been activated and traffic has been suspended for 60 seconds. Bluesocket Michael MIC failure detected in received frame MLME- MichaelMICFailure. indication(00:12:cf:00:01:02) Meru Networks did not respond to multiple requests for information. Understanding the WPA/WPA2 Break 2008, Joshua Wright 29

Outline Attack Overview Attack Analysis Enterprise Defenses Summary, Question and Answer Understanding the WPA/WPA2 Break 2008, Joshua Wright 30

Summary This is a break in TKIP, affecting WPA and WPA2 regardless of authentication Immediate actions: Start planning transition to AES-CCMP Investigate and apply TKIP key rotation every 2 minutes Capture and analyze logging data on AP's Understanding the WPA/WPA2 Break 2008, Joshua Wright 31

Question and Answer Joshua Wright, josh@inguardians.com 401-524-2911 Office/Mobile SANS Ethical Hacking Wireless course 12/11/08: Washington DC (Luallen) 3/2/09: Orlando, FL (Wright) InGuardians, Inc. Services for research, vulnerability assessment, penetration testing, incident response and more www.inguardians.com Wireless tools and information (Josh's site) www.willhackforsushi.com Understanding the WPA/WPA2 Break 2008, Joshua Wright 32

More Resources Tkiptun-ng documentation www.aircrack-ng.org/doku.php?id=tkiptun-ng Tews/Beck paper on TKIP and WEP http://dl.aircrack-ng.org/breakingwepandwpa.pdf Raul Siles attack analysis information http://radajo.blogspot.com/2008/11/wpatkipchopchop-attack.html Article: "Battered, but not broken: understanding the WPA crack" http://arstechnica.com/articles/paedia/wpacracked.ars/ Understanding the WPA/WPA2 Break 2008, Joshua Wright 33