BASIC CRYPTOGRAPHIC CONCEPTS. Public Key Cryptography  Uses two keys for every simplex logical communication link.  Public key  Private key  The use.

Slides:



Advertisements
Similar presentations
Chapter 3 Public Key Cryptography and Message authentication.
Advertisements

Public Key Cryptography & Message Authentication By Tahaei Fall 2012.
Public Key Algorithms …….. RAIT M. Chatterjee.
Dr. Lo’ai Tawalbeh Summer 2007 Chapter 9 – Public Key Cryptography and RSA Dr. Lo’ai Tawalbeh New York Institute of Technology (NYIT) Jordan’s Campus INCS.
Dr Alejandra Flores-Mosri Message Authentication Internet Management & Security 06 Learning outcomes At the end of this session, you should be able to:
Henric Johnson1 Chapter3 Public-Key Cryptography and Message Authentication Henric Johnson Blekinge Institute of Technology, Sweden
Cryptography1 CPSC 3730 Cryptography Chapter 9 Public Key Cryptography and RSA.
Private-Key Cryptography traditional private/secret/single key cryptography uses one key shared by both sender and receiver if this key is disclosed communications.
Chapter3 Public-Key Cryptography and Message Authentication.
Fall 2010/Lecture 311 CS 426 (Fall 2010) Public Key Encryption and Digital Signatures.
Dr.Saleem Al_Zoubi1 Cryptography and Network Security Third Edition by William Stallings Public Key Cryptography and RSA.
1 Pertemuan 08 Public Key Cryptography Matakuliah: H0242 / Keamanan Jaringan Tahun: 2006 Versi: 1.
Chapter 9 – Public Key Cryptography and RSA Private-Key Cryptography  traditional private/secret/single key cryptography uses one key  shared by both.
Public Key Cryptography RSA Diffie Hellman Key Management Based on slides by Dr. Lawrie Brown of the Australian Defence Force Academy, University College,
Computer Science CSC 474Dr. Peng Ning1 CSC 474 Information Systems Security Topic 2.5 Public Key Algorithms.
PULIC –KEY CRYPTOGRAPHY AND MESSAGE AUTHENTICATION.
“RSA”. RSA  by Rivest, Shamir & Adleman of MIT in 1977  best known & widely used public-key scheme  RSA is a block cipher, plain & cipher text are.
Introduction to Public Key Cryptography
Public Key Model 8. Cryptography part 2.
Public Key Encryption and the RSA Public Key Algorithm CSCI 5857: Encoding and Encryption.
 Introduction  Requirements for RSA  Ingredients for RSA  RSA Algorithm  RSA Example  Problems on RSA.
CS5204 – Fall Cryptographic Security Presenter: Hamid Al-Hamadi October 13, 2009.
1 Public-Key Cryptography and Message Authentication Ola Flygt Växjö University, Sweden
Behzad Akbari Spring In the Name of the Most High.
Network and Communications Network Security Department of Computer Science Virginia Commonwealth University.
Public key cryptography
Public Key Cryptography and the RSA Algorithm Cryptography and Network Security by William Stallings Lecture slides by Lawrie Brown Edited by Dick Steflik.
I-4 security.
Public-Key Cryptography CS110 Fall Conventional Encryption.
Midterm Review Cryptography & Network Security
CS526: Information Security Prof. Sam Wagstaff September 16, 2003 Cryptography Basics.
4 th lecture.  Message to be encrypted: HELLO  Key: XMCKL H E L L O message 7 (H) 4 (E) 11 (L) 11 (L) 14 (O) message + 23 (X) 12 (M) 2 (C) 10 (K) 11.
Improving Encryption Algorithms Betty Huang Computer Systems Lab
453 Network Security Section 3b: Message Authentication and Public-Key Cryptography Dr. E.C. Kulasekere Sri Lanka Institute of Information Technology -
Cryptography Wei Wu. Internet Threat Model Client Network Not trusted!!
Chapter 21 Public-Key Cryptography and Message Authentication.
Private-Key Cryptography  traditional private/secret/single key cryptography uses one key  shared by both sender and receiver  if this key is disclosed.
Public-Key Encryption
CSCE 715: Network Systems Security Chin-Tser Huang University of South Carolina.
Public Key Cryptography. symmetric key crypto requires sender, receiver know shared secret key Q: how to agree on key in first place (particularly if.
1 Public-Key Cryptography and Message Authentication.
Computer and Network Security Rabie A. Ramadan Lecture 6.
Cryptography and Network Security Chapter 9 - Public-Key Cryptography
The RSA Algorithm. Content Review of Encryption RSA An RSA example.
Computer Security: Principles and Practice First Edition by William Stallings and Lawrie Brown Lecture slides by Lawrie Brown Chapter 2 – Cryptographic.
PUBLIC-KEY CRYPTOGRAPH IT 352 : Lecture 2- part3 Najwa AlGhamdi, MSc – 2012 /1433.
PUBLIC KEY CRYPTOGRAPHY ALGORITHM Concept and Example 1IT352 | Network Security |Najwa AlGhamdi.
Cryptography 1 Crypto Cryptography 2 Crypto  Cryptology  The art and science of making and breaking “secret codes”  Cryptography  making “secret.
IT 221: Introduction to Information Security Principles Lecture 4: Public-Key Cryptography For Educational Purposes Only Revised: September 15, 2002.
Chapter 3 – Public Key Cryptography and RSA (A). Private-Key Cryptography traditional private/secret/single-key cryptography uses one key shared by both.
Chapter 9 Public Key Cryptography and RSA. Private-Key Cryptography traditional private/secret/single key cryptography uses one key shared by both sender.
Public Key Algorithms Lesson Introduction ●Modular arithmetic ●RSA ●Diffie-Hellman.
CS 4803 Fall 04 Public Key Algorithms. Modular Arithmetic n Public key algorithms are based on modular arithmetic. n Modular addition. n Modular multiplication.
1 ISA 562 Information Security Theory & Practice Public Key Cryptosystem Chapter 9 of Bishop ’ s Book.
Cryptography and Network Security Third Edition by William Stallings Lecture slides by Lawrie Brown.
Lecture 3 (Chapter 9) Public-Key Cryptography and RSA Prepared by Dr. Lamiaa M. Elshenawy 1.
RSA Pubic Key Encryption CSCI 5857: Encoding and Encryption.
Chapter 9 – Public Key Cryptography and RSA Every Egyptian received two names, which were known respectively as the true name and the good name, or the.
CSCE 715: Network Systems Security Chin-Tser Huang University of South Carolina.
1 Public Key Cryptography. 2 Public Key Cryptography Agenda: Message authentication – authentication codes and hash functions Public key encryption –
Public Key Cryptography. Asymmetric encryption is a form of cryptosystem in which Encryption and decryption are performed using the different keys—one.
Public Key Encryption ● Diffie and Hellman – 1976 Famous Paper: New Directions In Cryptography New Directions In Cryptography ● First revolutionary.
Asymmetric-Key Cryptography
Public-Key Cryptography and Message Authentication
Public Key Encryption and Digital Signatures
Asymmetric Cryptography
Public-Key Cryptography and Message Authentication
Chapter 3 - Public-Key Cryptography & Authentication
Introduction to Cryptography
Presentation transcript:

BASIC CRYPTOGRAPHIC CONCEPTS

Public Key Cryptography  Uses two keys for every simplex logical communication link.  Public key  Private key  The use of two keys has profound consequences in the areas of  Confidentiality  Key distribution  Authentication

 Basic ingredients of the scheme:  Plaintext (P) Message to be encrypted  Public Key (KU) and Private Key (KR) One with the sender and other with the receiver  Ciphertext (C) Message after encryption  Encryption algorithm (EA) Uses P and KU  Decryption algorithm (DA) Uses C and KR

Illustration :: Encryption EADA B’s public key KU B B’s private key KR B BA Plaintext P Plaintext P Ciphertext C

Key Usage for Encryption Private key of B KR B Public key of B KU B

Illustration :: Authentication EADA A’s private key KR A A’s public key KU A BA Plaintext P Plaintext P Ciphertext C

Key Usage for Authentication Private key of A KR A Public key of A KU A

Applications  Three categories:  Encryption/decryption: The sender encrypts a message with the recipient’s public key.  Digital signature / authentication: The sender signs a message with its private key.  Key exchange: Two sides cooperate to exchange a session key.

Requirements  Computationally easy for a party B to generate a key pair  Public key KU B  Private key KR B  Easy for sender to generate ciphertext C = E (M, KU B )  Easy for receiver to decrypt ciphertext using private key: M = D(C, KR B ) = D(E (M, KU B ), KR B )

 Computationally infeasible to determine KR B knowing KU B.  Computationally infeasible to recover message M, knowing KU B and ciphertext C.  Either of the two keys can be used for encryption, with the other used for decryption: M = D (E (M, KU B ), KR B )= D ( E (M, KR B ), KU B )

The RSA Public Key Algorithm  RSA Algorithm  Developed by Ron Rivest, Adi Shamir and Len Adleman at MIT, in  A block cipher. Not fixed size  The most widely implemented.

RSA : Key Generation 1. Select p,qp and q both prime 2. Calculate n = p × q 3. Calculate ɸ (n) = (p-1)(q-1) 4. Select integer e gcd( ɸ (n),e) =1 ; 1<e< ɸ (n) 5. Calculate d de=1 mod ɸ (n) 6. Public Key KU={e, n} 7. Private KeyKR={d, n} ɸ (n) is the number of positive number less than n and relatively prime to n (called Euler totient).

RSA : Encryption  PlaintextM < n  CiphertextC = M e (mod n)

RSA : Decryption  CiphertextC  PliantextM= C d (mod n)

Example  Select two prime numbers, p=7 and q=17.  Calculate n=pq= 7× 17 = 119.  Calculate ɸ (n) = (p-1)(q-1) =96.  Select e such that e is relatively prime to ɸ (n)=96, and less than ɸ (n).  In this case, e=5.  Determine d such that de = 1 mod 96 and d<96.  D=77, because 77 × 5 = 385 = 4 ×  Public key KU = {5, 119}  Private key KR={77, 119}

 Encryption process:  Say, plaintext M = 19.  CiphertextC= 19 5 mod 119 = mod 119 = 66  Decryption process:  M = mod 119 = 19.

The security of RSA  RSA is secure since  We use large number of bits in e and d.  The problem of factoring n into two prime factors is computationally very difficult. Knowing p and q will allow us to know ɸ (n). This will help an intruder to know the values of e and d.  Key sizes in the range of 1024 to 2048 bits seems safe

 Until recently, this was felt to be infeasible for numbers in the range of 100 decimal digits or so (approximately 300 bit).  A worldwide team cooperating over the internet and using 1600 computers recently cracked the code in eight months.  Currently, a 1024-bit key size (about 300 decimal digits) is considered strong enough for virtually all applications.

Diffie-Hellman Key Exchange  Proposed in  Allows group of users to agree on secret key over insecure channel.  Cannot be used to encrypt and decrypt messages.  Depends for its effectiveness on the difficulty of computing discrete logarithms.

D-H Algorithm  A and B want to agree on secret key.  They agree on two large numbers n and g, such that 1<g<n.  A choose random x, computes X=g x mod n, and sends X to B.  B chooses random y, computes Y=g y mod n, and sends Y to A.  A computes k 1 =Y x mod n.  B computes k 2 =X y mod n.  Note: k 1 =k 2 = g xy mod n.

AB Choose xChoose y Compute Y x mod nCompute X y mod n X = g x mod n Y = g y mod n

D-H Algorithm  Requires no prior communication between A and B.  Security depends on difficulty of computing x, given X = g x mod n.  Choices for g and n are critical.  Both n and (n-1)/2 should be prime.  n should be large.  Susceptible to intruder-in-the-middle (man-in-the- middle) attack.  Active intruder.

Man-in-the-Middle Attack Intruder BA

A Comparison  Symmetric encryption/decryption is much faster than asymmetric encryption/decryption: RSA: kilobits/second DES: megabits/second DES is about 100 times faster than RSA  Key size:  RSA: selected by user  DES: 56 bits

Message Authentication

Various Approaches  Authentication using conventional encryption.  Only the sender and receiver should share a key.  Message authentication without message encryption. An authentication tag is generated and appended to each message.  Message authentication code. Calculate the MAC as a function of the message and key: MAC = F(K,M)

MESSAGEMESSAGE MESSAGEMESSAGE MESSAGEMESSAGE MACMAC MAC Algorithm MAC Algorithm =? Transmit MACMAC K K

Commonly Used Schemes  The MD family  MD2, MD4 and MD5 (128-bit hash).  The SHA family  SHA-1 (160-bit), SHA-256 (256-bit), SHA-384 (384- bit) and SHA-512 (512-bit).  RIPEMD-128 (128-bit), RIPEMD-160 (160-bit).