Sécurité des réseaux

Documents pareils
Sécurité des réseaux sans fil

SSL ET IPSEC. Licence Pro ATC Amel Guetat

Sécurité des réseaux wifi. CREIX Kevin GIOVARESCO Julien

Tunnels. Plan. Pourquoi? Comment? Qu est-ce? Quelles solutions? Tunnels applicatifs ESIL INFO 2005/2006. Sophie Nicoud

Sécurité des réseaux wi fi

Le protocole RADIUS Remote Authentication Dial-In User Service

Tunnels et VPN. 22/01/2009 Formation Permanente Paris6 86

Les Réseaux Privés Virtuels (VPN) Définition d'un VPN

Introduction au Wi-Fi sécurisé

1. Présentation de WPA et 802.1X

HAUTE DISPONIBILITÉ DE MACHINE VIRTUELLE AVEC HYPER-V 2012 R2 PARTIE CONFIGURATION OPENVPN SUR PFSENSE

WiFI Sécurité et nouvelles normes

Les Protocoles de sécurité dans les réseaux WiFi. Ihsane MOUTAIB & Lamia ELOFIR FM05

CRYPTOGRAPHIE. Chiffrement par flot. E. Bresson. SGDN/DCSSI Laboratoire de cryptographie

Protocoles utilisant des mécanismes d'authentification: TACACS+, RADIUS et Kerberos

Instructions Mozilla Thunderbird Page 1

WIFI (WIreless FIdelity)

CONVENTION d adhésion au service. EDUROAM de Belnet

La citadelle électronique séminaire du 14 mars 2002

Pare-feu VPN sans fil N Cisco RV120W

Devoir Surveillé de Sécurité des Réseaux

Groupe Eyrolles, 2004, ISBN :

Outils d'analyse de la sécurité des réseaux. HADJALI Anis VESA Vlad

Windows Server 2008 Sécurité ADMINISTRATION ET CONFIGURATION DE LA SECURITE OLIVIER D.

1 PfSense 1. Qu est-ce que c est

SÉCURITÉ RÉSEAUX/INTERNET, SYNTHÈSE

La Technologie Carte à Puce EAP TLS v2.0

Présenté par : Ould Mohamed Lamine Ousmane Diouf

IV. La sécurité du sans-fil

LP ASUR - Sécurité. Introduction à la Sécurité des Systèmes d'information. Florent Autréau - florent@mataru.com 28 Avril 2013

>#? " $: $A; 4% 6 $7 -/8 $+.,.,$9:$ ;,<=</.2,0+5;,/ ! " # $%!& *$$ $%!& *! # +$

0,3YDQGLWVVHFXULW\ FKDOOHQJHV 0$,1²0RELOLW\IRU$OO,31HWZRUNV²0RELOH,3 (XUHVFRP:RUNVKRS %HUOLQ$SULO

IPv6. IPv6 et la sécurité: IPsec Objectif: Sécuriser... v.1a IPv6 Théorie et Pratique & Microsoft IPsec 1

Kerberos en environnement ISP UNIX/Win2K/Cisco

Sécurité des Web Services (SOAP vs REST)

La sécurité dans un réseau Wi-Fi

Protocole industriels de sécurité. S. Natkin Décembre 2000

Sécurité en milieu Wifi.

2. MAQUETTAGE DES SOLUTIONS CONSTRUCTIVES. 2.2 Architecture fonctionnelle d un système communicant.

Sécurité GNU/Linux. Virtual Private Network

Action Spécifique Sécurité du CNRS 15 mai 2002

Skype (v2.5) Protocol Data Structures (French) Author : Ouanilo MEDEGAN

Réseaux. Moyens de sécurisation. Plan. Evolutions topologiques des réseaux locaux

2. DIFFÉRENTS TYPES DE RÉSEAUX

OWASP Open Web Application Security Project. Jean-Marc Robert Génie logiciel et des TI

Cours 14. Crypto. 2004, Marc-André Léger

Sécurité des systèmes d exploitation

MONNIER Marie /2009 WPA

Description des UE s du M2

Attaques Wi-Fi WPA. Séparer le bon grain de l ivraie dans le buzz ambiant. Cédric Blancher. sid@rstack.org Rstack Team

Le protocole sécurisé SSL

Contrôle d accès Centralisé Multi-sites

RESEAUX TCP/IP: NOTIONS AVANCEES. Preparé par Alberto EscuderoPascual


Pare-feu VPN sans fil N Cisco RV110W

VPN TLS avec OpenVPN. Matthieu Herrb. 14 Mars 2005

WiFi Security Camera Quick Start Guide. Guide de départ rapide Caméra de surveillance Wi-Fi (P5)

Administration du WG302 en SSH par Magicsam

SSL/TLS: Secure Socket Layer/Transport Layer Secure Quelques éléments d analyse. GRES 2006 Bordeaux 12 Mai Ahmed Serhrouchni ENST-PARIS CNRS

Parcours en deuxième année

Les algorithmes de cryptographie dans les réseaux Wi-Fi

Les techniques de la télémaintenance

Fiche Technique. Cisco Security Agent

PACK SKeeper Multi = 1 SKeeper et des SKubes

Sécurité de la ToIP Mercredi 16 Décembre CONIX Telecom

Gestion des identités Christian-Pierre Belin

Configuration de l'accès distant

La Latecion protection anti-intrusion Web Web Le concept «Zero effort Security» La protection des applications Extranet

Routeur VPN Wireless-N Cisco RV215W

Note technique. Recommandations de sécurité relatives à IPsec 1 pour la protection des flux réseau

Réseaux AirPort Apple

Supervision et infrastructure - Accès aux applications JAVA. Document FAQ. Page: 1 / 9 Dernière mise à jour: 15/04/12 16:14

! "# Exposé de «Nouvelles Technologies Réseaux»

S28 - La mise en œuvre de SSO (Single Sign On) avec EIM (Enterprise Identity Mapping)

Table des matières 1 Accès distant sur Windows 2008 Server Introduction...2

Authentification sur réseau sans-fil Utilisation d un serveur radius Expérience du CENBG

TUNIS LE : 20, 21, 22 JUIN 2006

Introduction. Adresses

Cisco RV220W Network Security Firewall

Cryptologie. Algorithmes à clé publique. Jean-Marc Robert. Génie logiciel et des TI

Programmation Réseau. ! UFR Informatique ! Jean-Baptiste.Yunes@univ-paris-diderot.fr

Protocole SSH-2.0. Tuan-Tu, TRAN. Janvier 2009

KX ROUTER M2M SILVER 3G

Annexe C : Numéros de port couramment utilisés

How to Login to Career Page

CAS IT-Interceptor. Formation «Certificate of Advanced Studies»

Eric DENIZOT José PEREIRA Anthony BERGER

Les RPV (Réseaux Privés Virtuels) ou VPN (Virtual Private Networks)

Cisco RV220W Network Security Firewall

Sécurité des réseaux IPSec

Services Réseaux - Couche Application. TODARO Cédric

FTPS AVEC UNE APPLIANCE FAST360 EN COUPURE. Table des matières

Université de Reims Champagne Ardenne. HTTPS, SSL, SSH, IPSEC et SOCKS. Présenté par : BOUAMAMA Mohamed Nadjib AZIZ Xerin

Réseaux et protocoles Damien Nouvel

OneAccess 16xx EAD Ethernet Access Device / 1.0 / AH / Public

Transcription:

4MMSR 2010-2011 Grenoble INP Ensimag Sécurité des réseaux Lecturers: Fabien Duchene, Dominique Vicard Chapters: 4. Intranet 5. protocols, access Plan (nouveau, sujet à de légères modifications) o o o o 0. Introduction o Le réseau o Parano: mode d emploi 1. Menaces, vuln., attaques o o Définitions Attaques 2. Qqes algorithmes o o o Stéganographie Partage de secret P2P: l algo. Eigentrust 3. Poste client o o o o o Certifications Principes de la sécurité Principaux méchanismes NT4+ Unix 4. Intranet Authentification Active Directory, Kerberos Conformance (IDS/IPS, Antimalware, NAC) 5. Protocoles IPSec RFID RAS: PPTP, L2F, L2TP SSL/TLS VPN EAP & RADIUS 802.11 GSM 6. Internet Pare-feu (Firewall) Proxy, Socks PKI 7. Navigateur Privacy mode Javascript, XSS Flash, ActiveX, Java Sandbox HTLM5 2 4MMSR - Network Security - 2010-2011 0.1. Introduction

4. Intranet Authentication Active Directory NT5+: quelques protocoles Kerberos IDS & IPS Conformance Antimalware Network Access Control 3 4MMSR - Network Security - 2010-2011 4.1.1. Active Directory Active Directory Directory Services: service d annuaire: Ouverture de session unique Accès universel aux ressources Administration centralisée ou déléguée Service d authentification et de fourniture de données d authentification Fonctionnalités: Kerberos authentication LDAP directory (contains Security Principals & other objects) DNS resolution Versions: 2000 native, 2000 mixed ; 2003, 2003 R2 ; 2008, 2008 R2 5 4MMSR - Network Security - 2010-2011

4.1.1. Rôle de machines Windows Autonome (Workgroup) Non membre d un domaine Base de comptes SAM (Security Account Manager) locale Client membre (d un domaine) Base SAM locale Authentification: o domaine o SAM locale Contrôleur de domaine (DC) Copie des objets du domaine Assure le rôle KDC dans Kerberos o Authentifie les machines et utilisateurs 6 4MMSR - Network Security - 2010-2011 4.1.1. ADDS Domaines, Forêts Domaine (domain): 1 FQDN DNS, 1 annuaire (security principals, politiques de sécurité), authentification Arbre (tree): hiérarchie de domaines DNS Forêt (forest): plusieurs hiérarchies DNS (cf slide suivante) Tree corp.ensimag.fr Root domain jpn usa Child domain Domain 7 4MMSR - Network Security - 2010-2011

4.1.1. ADDS relations d approbations Trust relationships one-way trust A<-B: one way (transitive or not) relation meaning a domain A considers the identities provided by B as valid two-way trust A<->B = (A<-B) AND (B<-A) Within a tree: implicit transitive 2- way trust between child and parent domains Example of one-way forest trust: corp.nintendo.com trusts ms.google.biz tree corp.ensimag.fr domaine.phelma.fr jpn usa peru TRUSTING domain 8 4MMSR - Network Security - 2010-2011 TRUSTED domain 4.1.2. Windows NT5+ : quelques protocoles NT5: Windows 2000 Protocoles: clé partagés o Authentification NTLM (domaines hétérogènes) o Authentification Kerberos V5 clé publique o Secure Sockets Layer (SSL) / transport Layer Security (TLS) o IPSec Active Directory peut gérer différents types de credentials (SSP) Rôles de machine Windows 11 4MMSR - Network Security - 2010-2011

4.1.3. Kerberos Kerberos & Herakles (Cerbère & Hercules) Protocole authentification, autorisation, développé par le MIT (Projet ATHENA), ~ Single-Sign-On Version actuelle: v5 RFC4120 Hypothèse: le réseau peut être non sûr Basé sur l existence d un tiers de confiance, le KDC («Key Distribution Center» Cryptographie principlament symétrique éventuellement assymétrique (eg: auth. par carte à puce) Déclinaisons: MIT Kerberos Microsoft Kerberos, Windows NT (>=2000) Heimdal Kerberos, Suède 12 4MMSR - Network Security - 2010-2011 4.1.3. Kerberos: authentication & service access Identity provider, Authentication Server Key Distribution Center (KDC) GC I am Mossen. I need a Ticket to Get Tickets (TGT) 2 Here is a TGT you will only 1 be able to decrypt if you know the shared secret (user/comp. pwd) 3 I want to access the Issuing CA service. Here is a proof I decrypted the TGT Ticket Grantig Service TGS 4 Here is a Service Ticket containing your information for accessing the Issuing CA service User / computer 5 Service Ticket UserSID ------------------------- GroupMembershipsSIDs 6 Service communication Service Server (eg: issuing CA) 13 4MMSR - Network Security - 2010-2011 Introduction to the Microsoft PKI ADCS 2008 R2 (2011), Fabien Duchene, Sogeti-ESEC

4.1.3. Kerberos: authentification du client (1,2) Client_ID: Security Principal Name (username, computername ) [msg]key: chiffrement de msg avec la clé key K_client: hash du mot de passe du client (user/ comp.) K_client-TGS: session key generated by the AS Knows: K_client User / computer 1 1: Client_ID 14 4MMSR - Network Security - 2010-2011 2 Knows: K_client K_TGS K_cli-TGS Identity provider, Authentication Server 2.1: [Client-TGS_Session_key], K_client 2.2: Ticket-to-Get-Ticket [client_id, client_fqdn, TGT_validity_period, K_client-TGS]K_TGS KDC 4.1.3. Kerberos: autorisation d accès au service (3,4) TGT= [client_id, client_fqdn, TGT_validity_period, K_client-TGS]K_TGS Req_svc_ID: ID of the service the client requests access to K_client-SS: session key for the client and the requested service 3 3.1: TGT, Req_svc_ID 3.2: Authenticator [Client_ID,timestamp]K_client-TGS Knows: K_client K_client-TGS (K_client-SS) 4 User / computer 15 4MMSR - Network Security - 2010-2011 KDC Knows: K_TGS (K_client-TGS) K_req_svc (K_client-SS) Ticket Grantig Service TGS 4.1: Client-to-Server ticket : [client_id,client_fqdn,tcs_validity_period,k_client-svc] K_req_svc 4.2: [K_client-SS] K_client-TGS

4.1.3. Kerberos: accès au service (5,6) Client-to-Server ticket: [client_id,client_fqdn,tcs_validity_period,k_client-svc] K_req_svc K_client-SS: session key between the client and the SS Knows: K_client K_client-SS 5 5.1: Client-to-Server ticket 5.2: Authenticator-2 [Client_ID,timestamp]K_client-SS 6 6:[timestamp_in_5.2 + 1]K_client-SS : OK, I can serve you Service Server (eg: issuing CA) User / computer 16 4MMSR - Network Security - 2010-2011 7 Is timestamp=timestamp_5.2+1? If so, I can trust that service 4.1.3. Kerberos Accès inter-domaine Une relation de confiance est établie par le biais d une clé partagée entre domaines, grâce à laquelle des referals tickets (TGT inter-domaine) sont envoyés TRUSTING domain contains ressources/ss TRUSTED domain contains identities Service Server (eg: issuing CA) corp.ensimag.fr 20 4MMSR - Network Security - 2010-2011 K_AS(google)-TGS(nintendo) AS domaine..phelma.fr TGS 1 5 3 6 TGT inter-domaine 4 2 User / comput er

4.1.3. Kerberos: Smart Card authentication Client_ID: Security Principal Name (username, computername ) [msg]key: chiffrement de msg avec la clé key K_client_pub,K_client_priv: paire de clé assymétrique K_client-TGS: session key generated by the AS Knows: K_client_PUB K_client_PRIV 1: [Client_ID]K_client_PRIV 2 1 KDC Knows: K_client_PUB K_TGS K_cli-TGS Identity provider, Authentication Server User / computer 2.1: [Client-TGS_Session_key], K_client_PUB 2.2: Ticket-to-Get-Ticket [client_id, client_fqdn, TGT_validity_period, K_client-TGS]K_TGS 21 4MMSR - Network Security - 2010-2011 4.1.3. Kerberos et Windows: API et appels 23 4MMSR - Network Security - 2010-2011

4.1.3. Kerberos: optimisations Optimisations Les tickets et le clés de sessions sont en cache sur le client Un mécanisme permet d obtenir des tickets sans avoir à redonner son mot de passe o Ticket-Granting-Ticket (TGT) a faible durée de vie o Le KDC donne des tickets sur présentation du TGT Paramètres par défaut Validité TGT=10H Validité TGS= 10H Différence de 5 minutes MAX entre client, AS, TGS, SS synchronisation NTP 24 4MMSR - Network Security - 2010-2011 4.1.3. Kerberos some threats and attacks Threats single-point of failure: if only one KDC impersonation: if at least one KDC compromised. Any user could be impersonated Attacks KDC spoofing: old PAM_KRB5 implementation (no authorization) Replay attack: sniff and resend 5. KRB_AP_REP o KRB_AP_REP: validity duration (generally 5 minutes), source IP o Service Server stores a cache of requests. Multiple identitical KRP_AP_REP are ignored Cipher: DES (weak) initially used. Negotiation not authenticated o Windows 7: DES disabled for Kerberos authentication Ticket cache attack ( file on the client system) Pass the Ticket: ability to authenticate on the client. Only Microsoft implementation is vulnerable and not yet corrected. Taming the Beast Assess Kerberos-Protected networks, Emmanuel Bouillon, Black-Hat 2009 25 4MMSR - Network Security - 2010-2011

4.2. Virtualisation (virtualization) Mise en place d une version virtuelle Types: de matériel (Hyperviseur: Hyper-V ) de stockage, RAM, d OS de bureau, d application Vulnérabilités: Rajout d une couche supplémentaire => vulnérabilité additionnelles potentielles o Hyperviseur possède des droits système, sa compromission => compromission de l ensemble des machines virtualisées sur le serveur 31 4MMSR - Network Security - 2010-2011 HW virtualization logical view 4.3. Conformité (conformance) Définition de modèles en fonction Du type de poste (client, serveur) Des besoins métiers (équipe) De la politique de sécurité Mise en pratique des modèles agents installés sur les postes clients et serveurs Alerte en cas de non-conformité (monitoring/audit) 32 4MMSR - Network Security - 2010-2011

4.3.1. IDS / IPS Intrusion Detection System: passif (enregistre, notifie) o Composant qui monitore le réseau et/ou le système o Reporte les comportements suspects ou violations de politiques Intrusion Prevention System: detects and reacts Détection o Actions automatiques ou semi-automatiques o Comportement statistiquement anormal (métriques?) o Signature (attack patterns) Problèmes Faux positifs: fausses alertes Faux négatifs: intrusions non détectées Position NIDS, NIPS: Network HIDS, HIPS: Host (server, client) 33 4MMSR - Network Security - 2010-2011 4.3.2. Antimalware Détection Classique: hash du binaire Heuristiques (intelligence artificielle) o Signature générique: Variations légères dans le code/binaire o Comportement (exécution en sandbox ou environnement virtualisé) Opérations (accès fichiers, configuration du système) Différences en environnement virtualisé ou non!! Détection non parfaite!! Cf théorie de Gödel sur l incomplétude et l incohérence. Problème INDECIDABLE Configuration Centralisée Selon des modèles de poste (KDC, serveur web ) o Exclusions (que scanner? Processus, dossiers, ) o Actions (autoriser, quarantaine, supprimer, demander) o Mises à jour de définitions o Scans complets du système Menaces: les antimalwares disposent de privilèges SYSTEM (iawacs 2010) 34 4MMSR - Network Security - 2010-2011

4.3.2. Antimalware - screenshots Exclusions Monitoring 35 4MMSR - Network Security - 2010-2011 4.3.3. Network Acces Control Poste client: Accès à certaines zones (capacité de communication avec certaines machines) en fonction: NON de la topologie du réseau Mais d un ensemble de métriques du poste client o Pare-feu activé? o Mises à jours installées? (antimalware, OS, applications ) o Chiffrement de la partition système? o Méthodes d isolation DHCP, 802.1X, VPN, IPSec Produits Cisco NAC Microsoft NAP (Protection) 36 4MMSR - Network Security - 2010-2011

4. Intranet summary Active Directory Kerberos Conformance Features LDAP DNS Kerberos Authentication ACL on objects Symetric cryptography Single-Sign-On Client wants to access a Service Trusted 3 rd party (KDC) Asymetriccrypto for Smart Card authenticaion Models for computers (server, client, team, use ) Intrusion Detection/Prevention Sys Attack models Undecidable problem Antimalware Undecidable problem Heuristics Network Access Control workstation metrics Different from topology segregation DHCP, 802.1X, IPSec 37 4MMSR - Network Security - 2010-2011 XKCD interlude: voting machines & antimalware http://xkcd.com/462/ 38 4MMSR - Network Security - 2010-2011

5. Accès - Protocoles Introduction IP, IPSec RFID RAS: PPP, PPTP, L2F, L2TP SSL/TLS VPN EAP, RADIUS 802.11/Wifi GSM 40 4MMSR - Network Security - 2010-2011 5.1. Introduction Les protocoles réseaux offrent dans leur implémentations natives de nombreuses vulnérabilités Tous les protocoles classiques disposent d une version endurcie (hardened version) 41 4MMSR - Network Security - 2010-2011

5.1. Quelques protocoles Application HTTP FTP Telnet DNS NFS Ping TCP UDP Transport IP ICMP Réseau Trames Physique 42 4MMSR - Network Security - 2010-2011 5.1. Protocoles : IP, UDP et TCP (rappels) IP : Internet Protocol (v4, v6) UDP : User Datagram Protocol Sans garantie d ordre d arrivée Pas de retransmission TCP : Transport Control Protocol Connexion garantie (circuits virtuels) Correction d erreurs Cf vos Cours de réseaux! 43 4MMSR - Network Security - 2010-2011

5.2. IPv4 paquet (rappel) IP Header Payload Un paquet IP comprend Une charge (data) Un Header comprenant : o L adresse source IP o L adresse destination IP 44 4MMSR - Network Security - 2010-2011 5.2. IPSec extension de IPv4 Sécurisation de IPv4: RFC 2401 : IP Security Architecture RFC 2402 : IP Authentication Header (AH) RFC 2406 : IP Encapsulating Security Payload (ESP) RFC 2408 : Internet Security Associations and Key Management Protocol (ISAKMP) IPv6 inclus IPsec! Cf vos Cours de réseaux! 45 4MMSR - Network Security - 2010-2011

5.2. IPSec integrity, authentication, encryption AH (51 st IP protocol) Authentication, integrity, anti-replay NO CONFIDENTIALITY integrity on PAYLOAD and IP header o problems with Network Address Translation (Network lectures) ESP (50 th IP protocol) Authentication, integrity, anti-replay PAYLOAD CONFIDENTIALITY IP header unchanged only in tunnel mode NAT-Transversal Usages: AH, ESP or AH+ESP 47 4MMSR - Network Security - 2010-2011 Formation DirectAccess, Youssef Zizi & Cyril Voisin, Microsoft (2010) 5.2. IPSec Authentication Header (AH) Transport mode Original IP Header IP payload Tunnel mode New IP Header Integrity: hash covering the whole datagram, except TypeOfService, Fragment Offset, Flags, TTL, IP header checksum 48 4MMSR - Network Security - 2010-2011 Original IP Header AH header AH header authenticated / integrity Original IP Header authenticated / integrity IP payload IP payload Formation DirectAccess, Youssef Zizi & Cyril Voisin, Microsoft (2010)

5.2. IPSec Encapsulating Security Payload (ESP) Transport mode Original IP Header ESP header IP payload ESP Trailer ESP Auth encrypted Tunnel mode Authenticated / integrity New IP Header ESP header Original IP Header IP payload ESP Trailer ESP Auth IP header NOT protected encrypted Authenticated / integrity 49 4MMSR - Network Security - 2010-2011 Formation DirectAccess, Youssef Zizi & Cyril Voisin, Microsoft (2010) 5.2. IPSec SA & IKE SA : Security Association Décrit comment seront utilisés les services de sécurité lors d un échange o L algorithme de chiffrement utilisé o L algorithme d authentification utilisé o Une clé de session partagée (donc symétrique, pour raison de performance) unidirectionnel lie des adresses IP IKE : Internet Key Exchange Distribution des clés 52 4MMSR - Network Security - 2010-2011 Vue des SA dans le pare-feu Windows (NT6+, Vista et ultérieur)

5.2. IPSec en entreprise 53 4MMSR - Network Security - 2010-2011 5.3. Radio Frequency IDentification RFID Reader + tag(s) tag ; two main types: only replies its ID (cleartext, without reader authentication nor data encryption) can perform cryptographic operations Applications: Tracking (Passport, goods), Access control Security issues: Privacy (eg: chip inside hand, contactless) Vulnerabilities: o Replay attacks (if no cryptoprocessor) o Wireless, thus antenna range (amplification..) => privacy o The ID is generally used within a web application (thus classic web attacks (SQL injection, XSS )) => check your Conceiving Web-App lectures 54 4MMSR - Network Security - 2010-2011

5.4. Remote Access Server «RAS» Permits a remote access to IP and IPX networks May eventually require a Call-Back 1 PPP connection initialization RAS server Access Point 2 the AP requests a PAP, CHAP or EAP authentication Network 3 the user authenticates User / computer 4 the RAS server connects to the network (eg: PPTP,L2F,L2TP) 4 connects to itself only 4 rejects the connection (authorization or authentication fails) 4 requests a call-back 55 4MMSR - Network Security - 2010-2011 5.4.1. Point-to-Point Protocol PPP Data link protocol for a communication between two nodes Point-to-Point connection Authentication, encryption, compression Connection to a Remote Access Server Application FTP SMTP HTTP DNS; PPP: dialup ; PPPoE & PPPoA : DSL RFC: http://tools.ietf.org/html/rfc1661 Transport TCP UDP Internet Network access PPPoE Ethernet IP; IPv6 PPP PPPoA ATM PPP packet: PPP header L2 (eg: IP) header PPP payload L3 (eg: TCP) header L3 payload 56 4MMSR - Network Security - 2010-2011

5.4.2. RAS Authentication methods PAP (Password Authentication Protocol) unencrypted ASCII password! CHAP (Challenge Handshake AP) Shared secret key (eg: user password) Periodically a challenge is sent to the client Response: hash(challenge,secret_key) EAP (Extensible AP) several authentication methods o EAP-TLS 58 4MMSR - Network Security - 2010-2011 5.4.3. Tunnel protocols: PPTP PPTP : Point-to-Point Tunelling Protocol Microsoft (& Alcatel-Lucent, 3Com) PPP link over IP ONLY o GRE Generic Routine Encryption tunnel encapsulating PPP packets o Control channel over TCP 1723 permits confidentiality, integrity and authentication PPTP packet PPP packet IP Header GRE Header PPP header PPP payload (IP / IPX datagram) encrypted 59 4MMSR - Network Security - 2010-2011

5.4.3. PPTP data flow 60 4MMSR - Network Security - 2010-2011 5.4.3. Tunnel protocols: L2F, L2TP These ones have no encryption capabilities Necessary to use an additional protocol (eg: IPSec) L2F : Layer 2 Forwarding protocol Cisco, 1998 RFC2341 UDP 1701 IP UDP L2F PPP Packet L2TP : Layer 2 Tunelling Protocol 1999, Cisco & Microsoft RFC2661, L2TPv3 2005 RFC3931 Not necessarily over an IP network ; does support RADIUS Transport (UDP, ATM ) 61 4MMSR - Network Security - 2010-2011 L2TP data channel (unreliable) L2TP control channel (reliable) L2TP data msg L2TP control msg PPP Packet

5.5. Secure Socket Layer SSL / TLS SSL 1.0: Netscape, 1995 ; TLS = Transport Security Layer Current version: TLS 1.2 (aka SSL 3.3), RFC5248 aug 2008 Security properties o Communication: Integrity (MAC) Confidentiality (symmetric cryptography) o Server: authentication (asymetric crypto) o Key exchange (RSA, Diffie-Hellman ) o Eventually client authentication Sub-protocols o Handshake: version, algorithm, authentication o Record: data fragmentation (app. layer), integrity, confidentiality o Alert: errors, end of session o ChangeCipherSpec: messages will be authenticated (and eventually encrypted) o Application: application data 63 4MMSR - Network Security - 2010-2011 Application HTTP, FTP, SIP, IMAP, POP SSL/TLS TCP 5.5. SSL handshake (unauthenticated client) MAC = Message Authentication Code ; hash_function(key, message) 1.1 ClientHello (ciphers and compression it supports, ClientNonce) Cipher and compression choice 1.3.1. ServerHello (chosen TLS version, cipher, compression, and a ServerNonce) 1.3.2. Certificate 1.3.3. ServerHelloDone 1.3 1.2 1.4 ServerCertificate validation (integrity, validity time, revocation) Client 1.5 1.7 1.8 ClientKeyExchange (PreMasterSecret encrypted using K_server_pub) Eventually sends the servernonce encrypted with K_client_priv Decryption of the PreMasterSecret (using K_Server_priv) Session_keys = function(premasterkey,clientnonce,servernonce) 1.7 1.8.1. ChangeCipherSec (next messages will be authenticated and encrypted) 1.8.2. Finished = hash(prev_msgs) ; MAC(session_key, prev_msgs) Server 1.6 1.9.1. ChangeCipherSec 1.9.2. Finished = hash(prev_msgs) ; MAC(session_key, prev_msgs) 1.9 65 4MMSR - Network Security - 2010-2011

5.6. Virtual Private Network (VPN) Réseau Privé Virtuel Private (confidential) tunnel over a public network Interconnecting with remote office Connecting to the corporate network when outside Protocols PPTP, L2TP/IPSec HTTPS Risks the Internet can access inside the corporate network o strong authentication (at least 2 factors) o operational network teams, security teams 68 4MMSR - Network Security - 2010-2011 5.7. 802.1X, EAP, RADIUS EAP, authentication framework RFC5247 Used in 802.1X, PPP ; could use RADIUS for authorization 802.1X supplicant EAP Peer EAPOL-start EAP-request/identity 802.1 X authenticator RADIUS client 802.1 X authentication server RADIUS server shared secret key EAP-response/identity EAP-request EAP-response (credentials) EAP-success RADIUS-access-request (EAP) RADIUS-access-challenge (EAP) RADIUS-access-request (EAP) RADIUS-access-accept (EAP) modem PPP 802.3 EAPOL 802.11 802.1X EAP TLS PSK IKEv2 IP controlled port If authentication or authorization error: RADIUS-access-reject (EAP) RADIUS EAP Corporate ressources IP 73 4MMSR - Network Security - 2010-2011

5.8. 802.11 - Wifi 802.11 security 802.11 RC4 WEP SKA WPA 802.11i WPA2 802.11 security in corporations 75 4MMSR - Network Security - 2010-2011 5.8.1. 802.11 802.11: a (1999), b(1999), g(2003), n (2009) Review your network courses Security (1999): Data encryption: Wireless Equivalent Privacy WEP Authentication: o Shared Key Authentication SKA (WEP is used during authentication) o Open System Authentication (no authentication occurs) 76 4MMSR - Network Security - 2010-2011

5.8.1. Reminder: RC4 stream cipher IV: Initialisation Vector Key (shared between the parties) Flaws: if the same IV is used, same as one-time pad! if number generator weak, ability to gain some knowledge about the key 78 4MMSR - Network Security - 2010-2011 Wikipedia-WEP Weaknesses in the Key Scheduling Algorithm of RC4, Scott Fluhrer, Itsik Mantin, Adi Shamir 5.8.1. Wireless Equivalent Privacy "WEP" Chiffre = RC4 56 bits IV : 24 bits 802.11 does not prevent reusing the same IV!! Key = WEP password 40 bits (40+24= 64 bits WEP security ) 104 bits ( 128 bits WEP security ) ICV : Integrity Check Value : CRC-32 clear-text frame: 802.11 header 802.11 payload WEP-encrypted frame: 802.11 header IV Encrypted data ICV Chiffré 79 4MMSR - Network Security - 2010-2011

5.8.1. Shared Key Authentication SKA Four Way Handshake using the WEP password (secret key) Client station 1 Authentication-request Access Point clear-text challenge 2 shared secret key (WEP password) 3 RAC4(challenge, WEP key) Challenge decryption and comparison Positive / negative response --- 4 shared secret key (WEP password) 80 4MMSR - Network Security - 2010-2011 5.8.1. RC4 problem Vernam cipher if real randomness, then one-time pad Secret Key K E Unencrypted data d Pseudo Random Number Generator XOR Random number r Encrypted data e = d XOR r What if r is not so random?... 82 4MMSR - Network Security - 2010-2011

5.8.1. Stream cipher: basic cryptanalysis What if the same encryption key is used at least two times? e1=d1 XOR r e2=d2 XOR r Then: e1 XOR e2 = d1 XOR d2 From that we can deduce: reusing r is a VERY bad idea d1 and d2 are not random (thus sensible to patterns attacks. See aircrack (ARP attacks)) 802.11 o ICV (CRC) could confirm we did find the value! o r is IV+wep_password 83 4MMSR - Network Security - 2010-2011 5.8.1. the Birthday paradox with 802.11 IVs Pn: probability that 2 packets among n do use the same IV IV: 24 bits ; thus number of IV = 2^24 P2 = 1/(2^24) Pn = Pn 1 + (n 1)(1 Pn 1)/(2^24) (n>2) Pn >= 50% Starting from only n=4823 packets! 84 4MMSR - Network Security - 2010-2011

5.8.1. WEP security? Attacking WEP only takes ~ 3 minutes aircrack-ng (original work, Christophe Devine) Consequences Ability to modify the packets (integrity loss) Ability to authenticate Solutions increasing the size of the WEP key (and/or the possible space of the IV) is not enough (B day paradox) authentication, we could use EAP (see 802.11 WPA2) we should rely on another kind of cipher (eg: block cipher, see WPA) 87 4MMSR - Network Security - 2010-2011 5.8.2. Wifi Protected Access WPA Intermediate measures to protect Wifi networks while waiting for full 802.11i specs (aka WPA2) 2002 without changing the hardware! (only require a ram flash) Authentication and integrity Temporary Key Integrity Protocol (TKIP) o still RC4 but: 128 bits key/packet o rekeying mechanism (frequently change, avoiding collisions) o the ICV field is replaced by a MICHAEL integrity check (64 bits) sequence number for each packet (replay protection) AES (block cipher), optionnal o Mandatory in WPA2 90 4MMSR - Network Security - 2010-2011

5.8.2. WPA (with TKIP) attacks En novembre 2008 deux chercheurs allemands en sécurité, Éric Tews et Martin Beck, ont annoncé avoir découvert une faille de sécurité dans le protocole WPA. La faille, située au niveau de l'algorithme TKIP (Temporal Key Integrity Protocol), exploite l'architecture du protocole WPA. TKIP se met en place après le protocole WEP, or le code MAC est contenu dans un paquet WEP, ce qui permet à un pirate informatique de l'intercepter. Une fois intercepté le paquet peut être utilisé pour récupérer le code MAC et se faire passer pour le point d'accès. Cette méthode est encore plus efficace en interceptant les paquets ARP puisque leur contenu est connu. (attaques par pattern).cette faille concerne exclusivement le protocole WPA utilisant TKIP. Les protocoles utilisant AES restent sécurisés. Les détails concernant cette faille ont été exposés de façon détaillée durant la conférence PacSec les 12 et 13 novembre 2008 à Tokyo[2]. Martin Beck a intégré l'outil pour exploiter cette faille dans son outil de piratage des liaisons sans fil, nommé aircrack-ng (createur originel d aircrack: Christophe Devine). Contre-mesure: Il est toutefois assez facile de contrevenir à cette faille en forçant la négociation des clés toutes les deux minutes ce qui ne laisse pas assez de temps pour que l'attaque réussisse. 91 4MMSR - Network Security - 2010-2011 5.8.3. 802.11i IEEE standard: 802.11-2007 (draft in 2004, amended in 2007) WPA2 CCMP (Counter-Mode/CipherBlockChaining-Mac Protocol) o AES/FIPS-197 o 128-bit key, 128 bits cipher block o 10 rounds of encoding 802.1x support in 802.11 Key distribution 92 4MMSR - Network Security - 2010-2011

5.8.4. 802.11 in corporations WPA-enterprise WPA2-enterprise EAP for authentication and encryption. Mostly used EAP-TLS (with certificates, thus a PKI is needed) EAP-TTLS PEAP (Microsoft) 93 4MMSR - Network Security - 2010-2011 5.9. GSM 5 billion users For the basics, review your 1 st year GSM course Main security services Subscriber authentication Data and signalization confidentiality Subcriber identity confidentiality / (privacy) 94 4MMSR - Network Security - 2010-2011

5.9. GSM security global view Subscriber - Le triplet (RAND,SRES,K c ) est passé d un réseau à l autre - A5, algorithme de chiffrement, n est toujours pas officiellement public (A5/1, A5/3) - A3 + A8 est connu sous le nom de A38 96 4MMSR - Network Security - 2010-2011 5.9. GSM security subscriber authentication - Le réseau envoit un challenge RAND - L abonné possède une clé secrète Ki - Stockée dans la carte SIM et dans l AUC (Centre d authentification) - L authentification sert à générer une clé Kc de chiffrement des données et de la signalisation - A3: one-way hash paramétré par clé 98 4MMSR - Network Security - 2010-2011

5.9. GSM security data and signalization confidentiality - A8 - Le réseau et le mobile - Kc=A8(Ki,RAND) - One-way hash paramétrée par clé - A5=symetric stream cipher (specs secrètes) - chiffre les données et la signalisation - A5/1 (initially USA+Europe) - A5/2 (initially others) - A5/3 (should be used everywhere ) 100 4MMSR - Network Security - 2010-2011 5.9. GSM security protecting the subscriber identity Identification de l abonné (MS): seul le numéro est connu IMSI : Identité invariante de l abonné : est gardée secrète à l intérieur du réseau TMSI : Identité temporaire, attribuée après une authentification réussie MSISDN : Numéro de l abonné : c est le seul identifiant de l abonné mobile connu à l extérieur du réseau GSM MSRN : Numéro attribué lors d un appel, pour l acheminement des données 101 4MMSR - Network Security - 2010-2011

5.9. GSM security protecting the subscriber identity Note : VLR : Visitor Location Register : registre de la cellule ou se trouve le mobile HLR : Home Location Register : registre de l opérateur du mobile VMSC : Visitor Mobile Service Switching Center : établissement, hand-over et SMS GSMC : Gateway SMC 102 4MMSR - Network Security - 2010-2011 5.9. GSM security subscriber privacy Frequency-Hopping Speard Spectrum (FHSS) Rapidly switching of carrier among many channels Using a pseudorandomness function Usage Mainly for QoS.. But could and SHOULD be used for user privacy! 103 4MMSR - Network Security - 2010-2011

5.9 attacking the wideband GSM network Cryptosystem A5/1 could be cracked in seconds GSM SRLSY? Karsten Nohl, 26C3 (2010) o 2To rainbow tables ( available on Bittorrent) o for less than $1.000 H/W! Wideband GSM Sniffing, Karsten Nohl, Sylvain Munaut, 27C3 (2011) A5/3 o o o A practical-time attack on the A5/3 Cryptosystem Used in 3G telephony, Orr Dunkelman, Nathan Keller et Adi Shamir (2010) 75% probability with 1Go of data. ~ 2H communication. (seems unpractical) However, since multimedia usage do proliferate And in practise: Unfrequent TMSI changes Unfrequent Hopping No systematic rekeying before each call or SMS Predictable padding => confidentiality threatened!! 105 4MMSR - Network Security - 2010-2011 5.9. GSM security in 2011 106 4MMSR - Network Security - 2010-2011 Wideband GSM Sniffing, Karsten Nohl, Sylvain Munaut, 27C3 (2011)

5. Protocols, access summary IPSec Useful for VPN and for internal network Modes: transport, tunnel AH, ESP, IKE, SA EAP Authentication framework 802.1X, RADIUS, WPA(2)-enterprise VPN Encrypted tunnel over a public network IPSec, L2TP/IPSec, L2F, HTTPS SSL/TLS Btwn transport and application layer Certificate (server, eventually client) handshake 802.11 WEP: RC4 stream cipher WPA: adds TKIP, not enough WPA2: AES block cipher Corporations: WPA(2)-enterprise ; mostly EAP-TLS GSM TMSI: temporary identity Hopping: mainly for QoS(could be for privacy) Rekeying each time the user authenticate A5/1, A5/2: should not be used (real-time attacks) 107 4MMSR - Network Security - 2010-2011 Interlude 108 4MMSR - Network Security - 2010-2011