Network Security. HIT Shimrit Tzur-David



Similar documents
Chapter 8 Security. IC322 Fall Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

SECURITY IN NETWORKS

Network Security. Abusayeed Saifullah. CS 5600 Computer Networks. These slides are adapted from Kurose and Ross 8-1

Chapter 7: Network security

Network Security (2) CPSC 441 Department of Computer Science University of Calgary

What is network security?

Principles of Network Security

Network Security. Abusayeed Saifullah. CS 5600 Computer Networks. These slides are adapted from Kurose and Ross 8-1

Network Security #10. Overview. Encryption Authentication Message integrity Key distribution & Certificates Secure Socket Layer (SSL) IPsec

Chapter 8 Network Security

TELE 301 Network Management. Lecture 18: Network Security

Computer Networks. Network Security 1. Professor Richard Harris School of Engineering and Advanced Technology

Application Layer (1)

Overview of Network Security

Security. Friends and Enemies. Overview Plaintext Cryptography functions. Secret Key (DES) Symmetric Key

Network Security. Computer Networking Lecture 08. March 19, HKU SPACE Community College. HKU SPACE CC CN Lecture 08 1/23

Dr. Jinyuan (Stella) Sun Dept. of Electrical Engineering and Computer Science University of Tennessee Fall 2010

Network Security. Security Attacks. Normal flow: Interruption: 孫 宏 民 Phone: 國 立 清 華 大 學 資 訊 工 程 系 資 訊 安 全 實 驗 室

What is network security?

CSCE 465 Computer & Network Security

Application Layer (1)

Security in Computer Networks

Network Security CS 5490/6490 Fall 2015 Lecture Notes 8/26/2015

CIS 6930 Emerging Topics in Network Security. Topic 2. Network Security Primitives

Lukasz Pater CMMS Administrator and Developer

Common security requirements Basic security tools. Example. Secret-key cryptography Public-key cryptography. Online shopping with Amazon

Chapter 8 Network Security. Slides adapted from the book and Tomas Olovsson

Security: Focus of Control. Authentication

Telematics Chapter 11: Network Security Beispielbild User watching video clip

Overview of Cryptographic Tools for Data Security. Murat Kantarcioglu

Security. Contents. S Wireless Personal, Local, Metropolitan, and Wide Area Networks 1

Network Security Technology Network Management

Symmetric Key cryptosystem

Security & Privacy on the WWW. Topic Outline. Information Security. Briefing for CS4173

Chapter 8. Cryptography Symmetric-Key Algorithms. Digital Signatures Management of Public Keys Communication Security Authentication Protocols

Client Server Registration Protocol

Cryptography: Motivation. Data Structures and Algorithms Cryptography. Secret Writing Methods. Many areas have sensitive information, e.g.

Module 8. Network Security. Version 2 CSE IIT, Kharagpur

CSE/EE 461 Lecture 23

NETWORK SECURITY. Farooq Ashraf. Department of Computer Engineering King Fahd University of Petroleum and Minerals Dhahran 31261, Saudi Arabia

Network Security. Network Security. Security in Computer Networks

Network Security. Gaurav Naik Gus Anderson. College of Engineering. Drexel University, Philadelphia, PA. Drexel University. College of Engineering

Getting the most from Apple Mail

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur

Security in Computer Networks

Compter Networks Chapter 9: Network Security

CSC474/574 - Information Systems Security: Homework1 Solutions Sketch

Cryptosystems. Bob wants to send a message M to Alice. Symmetric ciphers: Bob and Alice both share a secret key, K.

Chapter 10. Network Security

Content Teaching Academy at James Madison University

Security in Distributed Systems. Network Security

Cryptography and Network Security

Lecture 9: Application of Cryptography

Computer Networks - CS132/EECS148 - Spring

Part 2 D(E(M, K),K ) E(M, K) E(M, K) Plaintext M. Plaintext M. Decrypt with private key. Encrypt with public key. Ciphertext

Network Security [2] Plain text Encryption algorithm Public and private key pair Cipher text Decryption algorithm. See next slide

7! Cryptographic Techniques! A Brief Introduction

First Semester Examinations 2011/12 INTERNET PRINCIPLES

CS 758: Cryptography / Network Security

Chapter 6 CDMA/802.11i

Chapter 11 Security+ Guide to Network Security Fundamentals, Third Edition Basic Cryptography

The science of encryption: prime numbers and mod n arithmetic

Chapter 8. Network Security

Authentication Types. Password-based Authentication. Off-Line Password Guessing

Cryptography and Network Security Department of Computer Science and Engineering Indian Institute of Technology Kharagpur

Outline. Digital signature. Symmetric-key Cryptography. Caesar cipher. Cryptography basics Digital signature

Overview/Questions. What is Cryptography? The Caesar Shift Cipher. CS101 Lecture 21: Overview of Cryptography

SAMPLE EXAM QUESTIONS MODULE EE5552 NETWORK SECURITY AND ENCRYPTION ECE, SCHOOL OF ENGINEERING AND DESIGN BRUNEL UNIVERSITY UXBRIDGE MIDDLESEX, UK

Chapter 8 Network Security

An Introduction to Cryptography and Digital Signatures

Information Security

COSC 472 Network Security

Computer Networks. Network Security and Ethics. Week 14. College of Information Science and Engineering Ritsumeikan University

2.4: Authentication Authentication types Authentication schemes: RSA, Lamport s Hash Mutual Authentication Session Keys Trusted Intermediaries

Public Key Cryptography. c Eli Biham - March 30, Public Key Cryptography

Fundamentals of Computer Security

Module 7 Security CS655! 7-1!

CRYPTOGRAPHY IN NETWORK SECURITY

Public Key (asymmetric) Cryptography

Cryptography & Network Security

Network Security. Outline of the Tutorial

Chapter 8. Computer Networking: A Top Down Approach, 5 th edition. Jim Kurose, Keith Ross Addison-Wesley, sl April Thanks and enjoy!

Final Exam. IT 4823 Information Security Administration. Rescheduling Final Exams. Kerberos. Idea. Ticket

ECE 428 Network Security

Part I. Universität Klagenfurt - IWAS Multimedia Kommunikation (VK) M. Euchner; Mai Siemens AG 2001, ICN M NT

Cryptography & Digital Signatures

Insight Guide. Encryption: A Guide

Outline. CSc 466/566. Computer Security. 8 : Cryptography Digital Signatures. Digital Signatures. Digital Signatures... Christian Collberg

Public Key Cryptography Overview

IT Networks & Security CERT Luncheon Series: Cryptography

Cryptography Exercises

Network Security. Omer Rana

Introduction to Computer Security

Properties of Secure Network Communication

Chapter 23. Database Security. Security Issues. Database Security

Cyber Security Workshop Encryption Reference Manual

Transcription:

Network Security HIT Shimrit Tzur-David 1

Goals: 2 Network Security Understand principles of network security: cryptography and its many uses beyond confidentiality authentication message integrity key distribution Security in practice: firewalls security in application, transport, network, link layers

What is Network Security? Confidentiality: only sender, intended receiver should understand message contents sender encrypts message receiver decrypts message Authentication: sender, receiver want to confirm identity of each other Message Integrity: sender, receiver want to ensure message not altered (in transit, or afterwards) without detection Access and Availability: services must be accessible and 3 available to users

Friends and Enemies: Alice, Bob, Trudy Well-known in network security world Bob, Alice (lovers!) want to communicate securely Trudy (intruder) may intercept, delete, add messages Alice channel data, control messages Bob data secure sender secure receiver data Trudy 4

Who might Bob, Alice be? Web browser/server for electronic transactions (e.g., on-line purchases) On-line banking client/server DNS servers Routers exchanging routing table updates 5

There are Bad Guys Out There! Q: What can a bad guy do? A: a lot! eavesdrop: intercept messages actively insert messages into connection impersonation: can fake (spoof) source address in packet (or any field in packet) hijacking: take over ongoing connection by removing sender or receiver, inserting himself in place denial of service: prevent service from being used by others (e.g., by overloading resources) 6

7 Notations cryptography - the principles and methods of transforming an intelligible message into one that is unintelligible, and then retransforming that message back to its original form. plaintext - the original intelligible message ciphertext - the transformed message cipher - an algorithm for transforming an intelligible message into one that is unintelligible by transposition and/or substitution methods key - some critical information used by the cipher, known only to the sender & receiver

8 Notations Cont. encipher (encode) - the process of converting plaintext to ciphertext using a cipher and a key decipher (decode) - the process of converting ciphertext back into plaintext using a cipher and a key cryptanalysis - the study of principles and methods of transforming an unintelligible message back into an intelligible message without knowledge of the key. Also called code-breaking cryptology - both cryptography and cryptanalysis code - an algorithm for transforming an intelligible message into an unintelligible one using a code-book

Notations Cont. C = E K (P) - the encryption of the plaintext P using key K gives the ciphertext C. P = D K (C) - the decryption of C to get the plaintext D K (E K (P)) = P E and D are mathematical functions of two parameters: the key and the message. 9

The Language of Cryptography K A Alice s encryption key Bob s decryption K B key plaintext encryption algorithm ciphertext decryption algorithm plaintext 10 symmetric key crypto: sender, receiver keys identical public-key crypto: encryption key public, decryption key secret (private)

Symmetric Key Cryptography K A-B K A-B plaintext message, m encryption algorithm ciphertext K (m) A-B decryption algorithm plaintext K (m) A-B m = K ( ) A-B symmetric key crypto: Bob and Alice share know same (symmetric) key: KA-B e.g., key is knowing substitution pattern in mono alphabetic substitution cipher 11

Symmetric Key Cryptography substitution cipher: substituting one thing for another monoalphabetic cipher: substitute one letter for another plaintext: abcdefghijklmnopqrstuvwxyz ciphertext: mnbvcxzasdfghjklpoiuytrewq E.g.: Plaintext: bob. i love you. alice ciphertext: nkn. s gktc wky. mgsbc Q: How hard to break this simple cipher?: brute force (how hard?) other? 12

Monoalphabetic Substitution There are 26! possible keys is in use. A computer would take ~10 10 years to try all the keys. Nevertheless, given a surprisingly small amount of ciphertext, the cipher can be broken easily. The basic attack takes advantage of the statistical properties of natural languages. In English, e is the most common letter, followed by t, o, a, n, i, etc. The most common two-letter combinations are th, in, er, re, and an. The most common three-letter combinations are the, ing, and, and ion. 13

Transposition Ciphers Substitution ciphers preserve the order of the plaintext symbols. Transposition ciphers, in contrast, reorder the letters but do not disguise them. The columnar transposition: 14

The Columnar Transposition The cipher is keyed by a word or phrase not containing any repeated letters. In the example, MEGABUCK is the key. The purpose of the key is to number the columns, column 1 being under the key letter closest to the start of the alphabet, and so on. The plaintext is written horizontally, in rows, padded to fill the matrix if need be. The ciphertext is read out by columns, starting with the column whose key letter is the lowest. 15

Breaking Transposition Cipher Step 1: The cryptanalyst must be aware that he is dealing with a transposition cipher. By looking at the frequency of E, T, A, O, I, N, etc., it is easy to see if they fit the normal pattern for plaintext. Step 2: Make a guess at the number of columns the plaintext phrase milliondollars occurs somewhere in the message Step 3: Order the columns 16 By frequency

One-Time Pads Unbreakable cipher Choose a random bit string as the key. Convert the plaintext into a bit string Compute the XOR of these two strings, bit by bit. The resulting ciphertext cannot be broken. The reason derives from information theory: there is simply no information in the message because all possible plaintexts of the given length are equally likely. 17

Public Key Cryptography symmetric key crypto requires sender, receiver know shared secret key Q: how to agree on key in first place (particularly if never met )? 18 public key cryptography radically different approach [Diffie- Hellman76, RSA78] sender, receiver do not share secret key public encryption key known to all private decryption key known only to receiver

Public Key Cryptography K B + K B - Bob s public key Bob s private key plaintext message, m encryption algorithm ciphertext + K (m) B decryption algorithm plaintext message - + m = K (K (m)) B B 19

Public Key Encryption Algorithms Requirements: 20 1 2 + B - + need K and K such that given public key K B, it should be impossible to compute - private key K RSA: Rivest, Shamir, Adelson algorithm - B K (K (m)) = m B B B +

RSA: Choosing keys 21 1. Choose two large prime numbers p, q. (e.g., 1024 bits each) 2. Compute n = pq, z = (p-1)(q-1) 3. Choose e (with e<n) that has no common factors with z. (e, z are relatively prime ). 4. Choose d such that ed-1 is exactly divisible by z. (in other words: ed mod z = 1 ). 5. Public key is (n,e). Private key is (n,d). K B + K B -

RSA: Encryption, Decryption 0. Given (n,e) and (n,d) as computed above 1. To encrypt bit pattern, m, compute c = m e e mod n (i.e., remainder when m is divided by n) 2. To decrypt received bit pattern, c, compute m = c d mod n (i.e., remainder when c d is divided by n) Magic happens! m = (m e d mod n) mod n c 22

RSA Example: Bob chooses p=5, q=7. Then n=35, z=24. e=5 (so e, z relatively prime). d=29 (so ed-1 exactly divisible by z). encrypt: letter m m e c = m e mod n l 12 248832 17 decrypt: c c d m = c d mod n 17 481968572106750915091411825223071697 12 letter l 23

RSA: Why is that Useful number theory result: If p,q prime and n = pq, then: y ymod (p-1)(q-1) x mod n = x mod n e (m mod n) d mod n = m ed mod n ed mod (p-1)(q-1) = m mod n (using number theory result above) 1 = m mod n (since we chose ed to be divisible by (p-1)(q-1) with remainder 1 ) 24 = m

RSA: Another Important Property The following property will be very useful later: - + K (K (m)) = m B B use public key first, followed by private key = + - B B K (K (m)) use private key first, followed by public key Result is the same! 25

Authentication Goal: Bob wants Alice to prove her identity to him Protocol ap1.0: Alice says I am Alice I am Alice Failure scenario?? 26

Authentication Goal: Bob wants Alice to prove her identity to him Protocol ap1.0: Alice says I am Alice I am Alice in a network, Bob can not see Alice, so Trudy simply declares herself to be Alice 27

Authentication: Another Try Protocol ap2.0: Alice says I am Alice in an IP packet containing her source IP address Alice s IP address I am Alice Failure scenario?? 28

Authentication: another try Protocol ap2.0: Alice says I am Alice in an IP packet containing her source IP address Alice s IP address I am Alice Trudy can create a packet spoofing Alice s address 29

Authentication: another try Protocol ap3.0: Alice says I am Alice and sends her secret password to prove it. Alice s IP addr Alice s password I m Alice Alice s IP addr OK Failure scenario?? 30

Authentication: another try Protocol ap3.0: Alice says I am Alice and sends her secret password to prove it. Alice s IP addr Alice s password I m Alice Alice s IP addr OK playback attack: Trudy records Alice s packet and later plays it back to Bob Alice s IP addr Alice s password I m Alice 31

Authentication: yet another try Protocol ap3.1: Alice says I am Alice and sends her encrypted secret password to prove it. Alice s IP addr encrypted password I m Alice Alice s IP addr OK Failure scenario?? 32

Authentication: another try Protocol ap3.1: Alice says I am Alice and sends her encrypted secret password to prove it. Alice s IP addr encrypted password I m Alice Alice s IP addr OK record and playback still works! Alice s IP addr encrypted password I m Alice 33

Authentication: Yet Another Try Goal: avoid playback attack Nonce: number (R) used only once in-a-lifetime ap4.0: to prove Alice live, Bob sends Alice nonce, R. Alice must return R, encrypted with shared secret key I am Alice R 34 Failures, drawbacks? K (R) A-B Alice is live, and only Alice knows key to encrypt nonce, so it must be Alice!

Authentication: ap5.0 ap4.0 requires shared symmetric key Can we authenticate using public key techniques? ap5.0: use nonce, public key cryptography R I am Alice - K A (R) send me your public key + K A Bob computes + - K A(K (R)) = R A and knows only Alice could have the private key, that encrypted R such that + - K A (K (R)) = R A 35

ap5.0: Security Hole Man (woman) in the middle attack: Trudy poses as Alice (to Bob) and as Bob (to Alice) - + m = K (K (m)) A A 36 I am Alice R - K (R) A + K A Send me your public key + K (m) A Trudy gets - + m = K (K (m)) sends T m to T Alice encrypted with Alice s public key I am Alice R - K (R) T Send me your public key + K (m) T + K T

ap5.0: Security Hole Man (woman) in the middle attack: Trudy poses as Alice (to Bob) and as Bob (to Alice) Difficult to detect: Bob receives everything that Alice sends, and vice versa. (e.g., so Bob, Alice can meet one week later and recall conversation) problem is that Trudy receives all messages as well! 37

Message Integrity: Digital Signatures Cryptographic technique analogous to handwritten signatures. Sender (Bob) digitally signs document, establishing he is the document s owner/creator. verifiable, non-forgeable: recipient (Alice) can prove to someone that Bob, and no one else (including Alice), must have signed document 38

Digital Signatures Simple digital signature for message m: Bob signs m by encrypting with his private key - - K B, creating signed message, K B (m) Bob s message, m Dear Alice Oh, how I have missed you. I think of you all the time! (blah blah blah), Bob K B - Public key encryption algorithm Bob s private key K B - (m) Bob s message, m, signed (encrypted) with his private key 39

40 Digital Signatures Cont. Suppose Alice receives msg m, digital signature K- B (m) Alice verifies m signed by Bob by applying Bob s + - + - public key K B to K B (m) then checks K B (K B (m) ) = m. + - If K B (K B (m) ) = m, whoever signed m must have used Bob s private key. Alice thus verifies that: Bob signed m. No one else signed m. Bob signed m and not m. Non-repudiation: Alice can take m, and signature K B (m) to court and prove that Bob signed m. -

Message Digests Computationally expensive to public-key-encrypt long messages Goal: fixed-length, easyto-compute digital fingerprint Apply hash function H to m, get fixed size message digest, H(m). 41 large message m H: Hash Function H(m) Hash function properties: many-to-1 produces fixed-size msg digest (fingerprint) given message digest x, computationally infeasible to find m such that x = H(m)

Internet Checksum: Poor Crypto Hash Function Internet checksum has some properties of hash function: produces fixed length digest (16-bit sum) of message is many-to-one But given message with given hash value, it is easy to find another message with same hash value: message ASCII format message ASCII format I O U 1 0 0. 9 9 B O B 49 4F 55 31 30 30 2E 39 39 42 D2 42 I O U 9 0 0. 1 9 B O B 49 4F 55 39 30 30 2E 31 39 42 D2 42 42 B2 C1 D2 AC different messages but identical checksums! B2 C1 D2 AC

Digital Signature = Signed Msg Digest Bob sends digitally signed message: 43 large message m H: Hash function Bob s private key K B - H(m) digital signature (encrypt) encrypted msg digest - + K B (H(m)) Alice verifies signature and integrity of digitally signed message: large message m H: Hash function H(m) Bob s public key K B + equal? encrypted msg digest - K B (H(m)) digital signature (decrypt) H(m)