1 / 104

Redes Inalámbricas – Tema 6 . Seguridad

Redes Inalámbricas – Tema 6 . Seguridad. La tecnología 802.11: WEP y el estándar 802.11i Seguridad en MANET. WEP y IEEE802.11i. Wireless LAN Security Issues. Issue Wireless sniffer can view all WLAN data packets Anyone in AP coverage area can get on WLAN. 802.11 WEP Solution

lanza
Télécharger la présentation

Redes Inalámbricas – Tema 6 . Seguridad

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Redes Inalámbricas – Tema 6. Seguridad La tecnología 802.11: WEP y el estándar 802.11i Seguridad en MANET

  2. WEP y IEEE802.11i Wireless LAN Security Issues Issue • Wireless sniffer can view all WLAN data packets • Anyone in AP coverage area can get on WLAN 802.11 WEP Solution • Encrypt all data transmitted between client and AP • Without encryption key, user cannot transmit or receive data Wireless LAN (WLAN) Wired LAN client access point (AP) Goal: Make WLAN security equivalent to that of wired LANs (Wired Equivalent Privacy)

  3. WEP y IEEE802.11i WEP – Protection for 802.11b • Wired Equivalent Privacy • No worse than what you get with wire-based systems. • Criteria: • “Reasonably strong” • Self-synchronizing – stations often go in and out of coverage • Computationally efficient – in HW or SW since low MIPS CPUs might be used • Exportable – US export codes (relaxed in Jan 2000 / “Wassenaar Arrangement”) • Optional – not required to used it • Objectives: • confidentiality • integrity • authentication

  4. WEP y IEEE802.11i 1 byte Init Vector(3 bytes) Pad6 bits Key ID2 bits WEP – How It Works • Secret key (40 bits or 104 bits) • can use up to 4 different keys • Initialization vector (24 bits, by IEEE std.) • total of 64 or 128 bits “of protection.” • RC4-based pseudo random number generator (PRNG) • Integrity Check Value (ICV): CRC 32 Frame header IV(4 bytes) Data (PDU)( 1 byte) ICV(4 bytes) FCS

  5. WEP y IEEE802.11i WEP Encryption Process • Compute ICV using CRC-32 over plaintext msg. • Concatenate ICV to plaintext message. • Choose random IV and concat it to secret key and input it to RC4 to produce pseudo random key sequence. • Encrypt plaintext + ICV by doing bitwise XOR with key sequence to produce ciphertext. • Put IV in front of cipertext. IV InitializationVector (IV) Key Sequence Seed Message WEP PRNG Secret Key Ciphertext Plaintext Integrity Algorithm Integrity Check Value (ICV)

  6. WEP y IEEE802.11i WEP Decryption Process • IV of message used to generate key sequence, k. • Ciphertext XOR k  original plaintext + ICV. • Verify by computing integrity check on plaintext (ICV’) and comparing to recovered ICV. • If ICV  ICV’ then message is in error; send error to MAC management and back to sending station. Secret Key Key Sequence Plaintext WEP PRNG IV Seed Ciphertext Message ICV’ ICV’ - ICV Integrity Algorithm ICV

  7. WEP y IEEE802.11i WS AP Auth. Req. Shared WEP Key Challenge Text AP Authentication Request Challenge Response Challenge ENC SharedKey {Challenge} Success/Failure Access Point Client Ack WEP Station Authentication • Wireless Station (WS) sends Authentication Request to Access Point (AP). • AP sends (random) challenge text T. • WS sends challenge response (encrypted T). • AP sends ACK/NACK.

  8. WEP y IEEE802.11i WEP Weaknesses • Forgery Attack • Packet headers are unprotected, can fake src and dest addresses. • AP will then decrypt data to send to other destinations. • Can fake CRC-32 by flipping bits. • Replay • Can eavesdrop and record a session and play it back later. • Collision (24 bit IV; how/when does it change?) • Sequential: roll-over in < ½ day on a busy net • Random: After 5000 packets, > 50% of reuse. • Weak Key • If ciphertext and plaintext are known, attacker can determine key. • Certain RC4 weak keys reveal too many bits. Can then determine RC4 base key. • Well known attack described in Fluhrer/Mantin/Shamir paper • “Weaknesses in the Key Scheduling Algorithm of RC4”, Scott Fluhrer, Itsik Mantin, and Adi Shamir • using AirSnort: http://airsnort.shmoo.com/ • Also: WEPCrack • http://wepcrack.sourceforge.net/

  9. WEP y IEEE802.11i Ways to Improve Security with WEP • Use WEP(!) • Change wireless network name from default • any, 101, tsunami • Turn on closed group feature, if available in AP • Turns off beacons, so you must know name of the wireless network • MAC access control table in AP • Use Media Access Control address of wireless LAN cards to control access • Use Radius support if available in AP • Define user profiles based on user name and password • War Driving in New Orleans (back in December 2001) • Equipment • Laptop, wireless card, software • GPS, booster antenna (optional) • Results • 64 Wireless LAN’s • Only 8 had WEP Enabled (12%) • 62 AP’s & 2 Peer to Peer Networks • 25 Default (out of the box) Settings (39%) • 29 Used The Company Name For ESSID (45%)

  10. Locating wireless access points while in motion http://www.wardrive.net/ Adversarial Tools Laptop with wireless adapter External omni-directional antenna Net Stumbler or variants http://www.netstumbler.com/ GPS War Driving With GPS Support Send constant probe requests

  11. WEP y IEEE802.11i War Driving in New Orleans (back in December 2001)

  12. Quick and dirty 802.11 Security Methods • SSID Closed mode • MAC layer security

  13. Quick and dirty Security Methods: Closed Mode of Operation • Hide SSID • All devices in a WLAN have to have same SSID to communicate • SSID is not released • Beacon messages are removed • Client has to know exact SSID to connect • Make active scanning, send probe request

  14. Client Connection Disassociate AP Client Impersonate AP Client sends Probe Request which includes SSID in clear Capture Probe Request Packets for SSID information Attacking to 802.11 Closed Mode

  15. Application Server Wired Network AP Access Point Client Impersonate Client to the AP Impersonate AP to the client Man-in-the-middle Attack

  16. Quick and dirty 802.11 Security Methods • SSID Closed mode • MAC layer security

  17. Wired Network ? MAC: 00:05:30:AA:AA:AA MAC: 00:05:30:BB:CC:EE Quick and dirty security Methods: MAC Layer Security • Based on MAC addresses • MAC filters • Allow associate of a MAC • Deny associate of a MAC

  18. Wired Network AP Application Server Access Point Legitimate Client Probe Request Probe Respond 802.11 Authentication Request Authentication Respond 1 Association Request Association Response Access to Network Disassociate Monitor Set MAC address of Legitimate Client by using SMAC or variants 2 Association Request 3 Association Response 4 Access to Network 5 Bypass MAC Filters: MAC Spoofing

  19. Application Server: i.e. Web Server Wired Network AP Rouge AP • Install fake AP and web server software • Convince wireless client to: • Disassociate from legitimate AP • Associate to fake AP • Bring similar web application to user to collect passwords • Adversarial tools: • Any web server running on Unix or MS environments • Fake AP (http://www.blackalchemy.to/project/fakeap/) Reconnect to louder AP • Run fake • AP software • Web Server

  20. IEEE 802.11i: Introducción • Las redes inalámbricas 802.11 siguen teniendo la fama de inseguras • Desde el año 2004 se cuenta con el estándar 802.11i, que proporciona una alta seguridad a este tipo de redes • no hay descrito ningún ataque efectivo sobre WPA2 en modo infraestructura (correctamente configurado) • WEP dejó de ser una opción a partir del año 2001 • ¡pero seguimos burlándonos de él! • ya no forma parte del estándar 802.11 (su uso está desaprobado por el añadido 802.11i • La tecnología actual permite redes Wi-Fi seguras

  21. Cronología de la seguridad en 802.11 802.11a 802.11g 802.11i 802.11 802.11b 2001 2003 2004 1997 1999 Wi-Fi WPA WPA2 WEP

  22. ¿En qué falló WEP? • utiliza una única clave secreta para todo: autenticación, confidencialidad • y se usa en todos los dispositivos y durante todo el tiempo • la gestión de las claves es manual • la autenticación es sólo para el dispositivo cliente • no se autentica al usuario, ni se autentica la red • el IV es demasiado pequeño y la forma de usarlo debilita el protocolo • la integridad no funciona (CRC no es un buen código) • y no incluye las direcciones fuente y destino

  23. ¿Qué podemos hacer? • No intentar resolverlo todo de una • Buscar los protocolos adecuados para cada funcionalidad • Permitir la gestión automática de las claves de cifrado • Cambiar frecuentemente las claves, obteniéndolas automáticamente • Autenticar al usuario, no al dispositivo • Autenticar a la red (también hay redes ‘malas’) • Utilizar protocolos robustos de autenticación, integridad y confidencialidad

  24. Primera aproximación: 802.1X • Control de acceso basado en el puerto de red: • una vez autenticada y asociada una estación, no se le da acceso a la red hasta que no se autentique correctamente el usuario • Componentes: suplicante, autenticadory servidor de autenticación • Utiliza EAP como marco de autenticación • EAP permite el uso de distintos protocolosde autenticación: MD5, MS-CHAPv2, … • La utilización de un método criptográfico en la autenticación permite generar claves secretas • también se pueden distribuir de manera segura

  25. Métodos EAP (1) • Los métodos EAP en redes Wi-Fi han de cumplir: • protección de las credenciales de usuario • autenticación mutua usuario  red • derivación de claves • Solución: emplear un túnel TLS • el servidor se autentica con certificado digital • las credenciales viajan protegidas • TLS genera una clave maestra • ¿Qué servidor autentica? RADIUS • trabaja con distintas Bases de Datos de usuario • permite la escalabilidad mediante una jerarquía de servidores (en árbol)

  26. Métodos EAP (2) • Los más habituales en Wi-Fi: • EAP-TLSse utilizan certificados digitales en ambos extremos • EAP-TTLS (Tunneled TLS)en una primera fase se establece un túnel TLS a partir del certificado digital del servidoren la segunda fase se utiliza cualquier otro método de autenticación (protegido por el túnel). Ej.: PAP, MD5, … • EAP-PEAP (Protected EAP)equivalente a TTLS, pero sólo emplea métodos EAP para la segunda fase: TLS, MS-CHAP-V2, … • Si se emplean dos fases: • identidad anónima en la autenticación externa (dominio) • identidad real en la autenticación interna

  27. El servicio RADIUS • Permite autenticar a los usuarios que establecen conexiones remotas u 802.1X • Es capaz de trabajar con distintos repositorios de cuentas de usuario • el Directorio Activo de Windows, LDAP, ficheros, … • Si el usuario no pertenece a su dominio lanza la petición a su ‘padre’ en la jerarquía RADIUS • en los métodos que utilizan dos fases se emplea la identidad externa para redirigir la petición • Los canales cifrados (túneles TLS) se establecen entre el suplicante y el RADIUS final que atiende la petición

  28. Jerarquía RADIUS

  29. Primera solución: WPA • Mientras en el IEEE se trabaja en el nuevo estándar 802.11i, las debilidades de WEP exigen protocolos de cifrado en niveles superiores a la capa de enlace • La industria es reacia a adoptar las redes 802.11 • El consorcio Wi-Fi Alliance decide sacar el estándar comercial WPA (Wi-Fi Protected Access) • Se basa en un borrador del estándar 802.11i y es un subconjunto del mismo • compatible hacia delante • Soluciona todos los problemas que plantea WEP con medidas válidas a medio plazo

  30. La confidencialidad en WPA: TKIP • TKIP (Temporal Key Integrity Protocol) es el protocolo de cifrado diseñado para sustituir a WEP reutilizando el hardware existente • Forma parte del estándar 802.11i • aunque se considera un protocolo ‘a desaprobar’ • Entre sus características: • utiliza claves maestras de las que se derivan las claves • el IV se incrementa considerablemente (de 24 a 48 bits) • cada trama tiene su propia clave RC4 • impide las retransmisiones de tramas antiguas • comprueba la integridad con el algoritmo Michael • no ofrece la máxima seguridad, pero incorpora contramedidas ante los ataques (desconexión 60 s y generación de claves)

  31. ¿Cómo se configura WPA? • Autenticación 802.11 abierta • Autenticación 802.1X (en modo infraestructura) • Métodos EAP con túnel TLS • identidad externa anónima, si es posible • Restricción de los servidores RADIUS aceptados • Cifrado: TKIP • ¿Y si estamos en un entorno SOHO? • no hay servidores RADIUS • no podemos autenticar al usuario como hasta ahora • no podemos generar la clave maestra •  utilizamos una clave pre-compartida entre todos ¡!

  32. La solución definitiva: 802.11i = WPA2 • El protocolo CCMP ofrece el cifrado (mediante AES) y la protección de integridad • se considera el algoritmo de cifrado más seguro hoy en día (no se ha ideado ningún ataque contra el mismo) • necesita soporte hardware para no penalizar • aunque se han incorporado mejoras en el diseño para hacerlo más eficiente • Se establece el concepto RSN: Robust Security Networks • aquellas en las que todas las asociaciones entre dos dispositivos son de tipo RSNA intercambio de claves con un 4-Way Handshake

  33. Asociaciones de tipo RSNA • Una vez que el usuario se ha autenticado ante el RADIUS, ambos han generado una clave maestra • El RADIUS le proporciona esta clave al AP • El punto de acceso y el cliente realizan un diálogo (con 4 mensajes) en el que: • comprueban que el otro tiene en su poder la clave maestra • sincronizan la instalación de claves temporales • confirman la selección de los protocolos criptográficos • Las claves temporales son de dos tipos: • para el tráfico unicast (estación  AP) • para el tráfico multicast y broadcast (AP  estaciones)

  34. ¿Cómo se configura WPA2? • Autenticación 802.11 abierta • Autenticación 802.1X (en modo infraestructura) • Métodos EAP con túnel TLS • identidad externa anónima, si es posible • Restricción de los servidores RADIUS aceptados • Cifrado: AES • ¿Y si estamos en un entorno SOHO? • utilizamos una clave pre-compartida entre todos • esta clave sirve de autenticación • esta es la clave maestra a partir de la que generar el resto LA PALABRA DE PASO HA DE TENER MÁS DE 20 CARACTERES

  35. WPA y WPA2 • WPA puede ejecutarse con todo el hardware que soportase WEP (sólo necesita una actualización de firmware) • WPA2 necesita hardware reciente (2004 ) • WPA acabará siendo comprometido a medio plazo y sólo se recomienda como transición a WPA2 • Algunos AP permiten emplear un modo mixto que acepta tanto clientes WPA como clientes WPA2 en la misma celda • hay una pequeña degradación en las claves de grupo (este modo nos ha dado problemas con algunas PDA)

  36. Pre-autenticación 802.1X • El proceso de establecer la asociación y generar las claves es costoso y puede afectar a la movilidad • La pre-autenticación consiste en establecer el contexto de seguridad con un AP mientras se está asociado a otro • El tráfico entre la estación y el nuevo AP viaja por la red cableada • Cuando, finalmente, se produce el roaming, el cliente indica que ya está hecha la asociación inicial • Sólo disponible en WPA2 (excluido en WPA)

  37. Soporte 802.11i en los S. Operativos • Windows Mobile • ¡Cada PDA es un mundo! • Incluye el suplicante 802.1X • Soporta sólo WPA (cifrado TKIP) • métodos EAP: EAP-TLS y EAP-PEAP/MS-CHAP-V2 • Windows XP SP2 • Incluye el suplicante 802.1X • Soporta WPA (de fábrica). Se puede aplicar la actualización a WPA2 (si la tarjeta lo soporta) • esta actualización no se aplica a través de Windows Update • métodos EAP: EAP-TLS y EAP-PEAP/MS-CHAP-V2 • permite restringir los servidores RADIUS aceptados • almacena en caché las credenciales del usuario ¡siempre!

  38. Soporte 802.11i en los S. Operativos • Windows Vista • Incluye el suplicante 802.1X • Soporta WPA y WPA2 • métodos EAP: EAP-TLS y EAP-PEAP/MS-CHAP-V2 • incorpora una API (EAPHost) que permite desarrollar nuevos suplicantes y nuevos métodos EAP • permite restringir los servidores RADIUS aceptados • permite elegir si se almacenan o no, en caché, las credenciales del usuario • Permite definir perfiles de conexión para configurar las redes inalámbricas sin la intervención del usuario • incluso con opciones que no podrá modificar • Informa de la seguridad de las redes disponibles

  39. Soporte 802.11i en los S. Operativos • Linux • Dependiendo de la distribución puede incluir o no el suplicante 802.1X • Se recomienda utilizar wpa-supplicant y Network Manager para la configuración • Soporta WPA y WPA2 • admite la mayoría de métodos EAP: EAP-TLS, EAP-TTLS/PAP, EAP-PEAP/MS-CHAP-V2, … • permite restringir los servidores RADIUS aceptados • permite elegir si se almacenan o no, en caché, las credenciales del usuario • la configuración puede ser a través de ficheros o mediante la interfaz gráfica

  40. eduroam • Es una iniciativa a nivel internacional que permite la movilidad de sus miembros de manera ‘transparente’ • con la misma configuración de la red inalámbrica se puede conectar un usuario en cualquier institución adherida a eduroam • la autenticación del usuario la hace siempre la institución de origen (con seguridad en el tránsito de credenciales) • es sencillo detectar si tenemos soporte para eduroam: el SSID es eduroam • Más información: • http://www.eduroam.es, http://eduroam.upv.es • Atención: el cifrado puede ser distinto en cada red

  41. eduroam en Europa

  42. La red inalámbrica en la UPV http://wifi.upv.es

  43. Redes Inalámbricas – Tema 6. Seguridad La tecnología 802.11: WEP y el estándar 802.11i Seguridad en MANET

  44. Routing security vulnerabilities • Wireless medium is easy to snoop on • Due to ad hoc connectivity and mobility, it is hard to guarantee access to any particular node (for instance, to obtain a secret key) • Easier for trouble-makers to insert themselves into a mobile ad hoc network (as compared to a wired network) • Open medium • Dynamic topology • Distributed cooperation(absence of central authorities) • Constrained capability(energy)

  45. Securing Ad Hoc Networks • Definition of “Attack” RFC 2828 — Internet Security Glossary : • “ An assault on system security that derives from an intelligent threat, i.e., an intelligent act that is a deliberate attempt (especially in the sense of a method or technique) to evade security services and violate the security policy of the system.” • Goals • Availability: ensure survivability of the network despite denial of service attacks. The DoS can be targeted at any layer • Confidentiality: ensures that certain information is not disclosed to unauthorized entities. Eg Routing information information should not be leaked out because it can help to identify and locate the targets • Integrity: guarantee that a message being transferred is never corrupted. • Authentication: enables a node to ensure the identity of the nodes communicating. • Non-Repudiation: ensures that the origin of the message cannot deny having sent the message

  46. Routing attacks Classification: • External attack vs. Internal attack • External: Intruder nodes can pose to be a part of the network injecting erroneous routes, replaying old information or introduce excessive traffic to partition the network • Internal: The nodes themselves could be compromised. Detection of such nodes is difficult since compromised nodes can generate valid signatures. • Passive attack vs. Active attack • Passive attack: “Attempts to learn or make use of information from the system but does not affect system resources” (RFC 2828) • Active attack: “Attempts to alter system resources or affect their operation” (RFC 2828)

  47. Normal Flow Information source Information destination

  48. Passive Attacks Sniffer Passive attacks Interception (confidentiality) Release of message contents Traffic analysis

  49. Sniffers • All machines on a network can “hear” ongoing traffic • A machine will respond only to data addressed specifically to it • Network interface: “promiscuous mode” – able to capture all frames transmitted on the local area network segment • Risks of Sniffers: • Serious security threat • Capture confidential information • Authentication information • Private data • Capture network traffic information

  50. Interception Information source Information destination Unauthorized party gains access to the asset – Confidentiality Example: wiretapping, unauthorized copying of files

More Related