Codes, Ciphers, and Cryptography-RSA Encryption

Slides:



Advertisements
Similar presentations
RSA COSC 201 ST. MARY’S COLLEGE OF MARYLAND FALL 2012 RSA.
Advertisements

IS 302: Information Security and Trust Week 4: Asymmetric Encryption
CS 483 – SD SECTION BY DR. DANIYAL ALGHAZZAWI (4) Information Security.
Asymmetric-Key Cryptography
CSE331: Introduction to Networks and Security Lecture 19 Fall 2002.
22C:19 Discrete Structures Integers and Modular Arithmetic
BY : Darshana Chaturvedi.  INTRODUCTION  RSA ALGORITHM  EXAMPLES  RSA IS EFFECTIVE  FERMAT’S LITTLE THEOREM  EUCLID’S ALGORITHM  REFERENCES.
Public Key Encryption Algorithm
Primality Testing By Ho, Ching Hei Cheung, Wai Kwok.
22C:19 Discrete Math Integers and Modular Arithmetic Fall 2010 Sukumar Ghosh.
OOP/Java1 Public Key Crytography From: Introduction to Algorithms Cormen, Leiserson and Rivest.
Cryptography 101 How is data actually secured. RSA Public Key Encryption RSA – names after the inventors –Rivest, Shamir, and Adleman Basic Idea: Your.
RSA ( Rivest, Shamir, Adleman) Public Key Cryptosystem
Public Key Crytography1 From: Introduction to Algorithms Cormen, Leiserson and Rivest.
ITIS 3200: Introduction to Information Security and Privacy Dr. Weichao Wang.
1 Lecture #10 Public Key Algorithms HAIT Summer 2005 Shimrit Tzur-David.
Public Key Cryptography
Public Encryption: RSA
RSA Exponentiation cipher
8: Network Security8-1 Symmetric key cryptography symmetric key crypto: Bob and Alice share know same (symmetric) key: K r e.g., key is knowing substitution.
CSCI 172/283 Fall 2010 Public Key Cryptography. New paradigm introduced by Diffie and Hellman The mailbox analogy: Bob has a locked mailbox Alice can.
Lecture 5 Overview Does DES Work? Differential Cryptanalysis Idea – Use two plaintext that barely differ – Study the difference in the corresponding.
 Introduction  Requirements for RSA  Ingredients for RSA  RSA Algorithm  RSA Example  Problems on RSA.
1 Introduction to Codes, Ciphers, and Cryptography Michael A. Karls Ball State University.
Introduction to Modular Arithmetic and Public Key Cryptography.
RSA Public Key Algorithm. RSA Algorithm history  Invented in 1977 at MIT  Named for Ron Rivest, Adi Shamir, and Len Adleman  Based on 2 keys, 1 public.
RSA and its Mathematics Behind
RSA Implementation. What is Encryption ? Encryption is the transformation of data into a form that is as close to impossible as possible to read without.
Cryptography: RSA & DES Marcia Noel Ken Roe Jaime Buccheri.
10/1/2015 9:38:06 AM1AIIS. OUTLINE Introduction Goals In Cryptography Secrete Key Cryptography Public Key Cryptograpgy Digital Signatures 2 10/1/2015.
1 Lecture 9 Public Key Cryptography Public Key Algorithms CIS CIS 5357 Network Security.
Public-Key Cryptography CS110 Fall Conventional Encryption.
BASIC CRYPTOGRAPHIC CONCEPTS. Public Key Cryptography  Uses two keys for every simplex logical communication link.  Public key  Private key  The use.
Implementing RSA Encryption in Java
Introduction to Algorithms Second Edition by Cormen, Leiserson, Rivest & Stein Chapter 31.
Day 37 8: Network Security8-1. 8: Network Security8-2 Symmetric key cryptography symmetric key crypto: Bob and Alice share know same (symmetric) key:
Modular Arithmetic with Applications to Cryptography Lecture 47 Section 10.4 Wed, Apr 13, 2005.
Section 4.4: The RSA Cryptosystem Practice HW Handwritten and Maple Exercises p at end of class notes.
Darci Miyashiro Math 480 April 29, 2013
Elements of Coding and Encryption Continuation 1.
RSA Public Key Crypto System. About RSA Announced in 1977 by Ronald Rivest, Adi Shamir, and Leonard Adleman Relies on the relative ease of finding large.
1 Public-Key Cryptography and Message Authentication.
Public Key (RSA) Day 27. Objective Students will be able to… …understand how RSA is used for encryption and decryption. …understand some of the challenges.
RSA Prepared by: SITI ZAINAH ADNAN
Algebra of RSA codes Yinduo Ma Tong Li. Ron Rivest, Adi Shamir and Leonard Adleman.
The RSA Algorithm. Content Review of Encryption RSA An RSA example.
RSA and its Mathematics Behind July Topics  Modular Arithmetic  Greatest Common Divisor  Euler’s Identity  RSA algorithm  Security in RSA.
Network Security Lecture 18 Presented by: Dr. Munam Ali Shah.
Lecture 6.1: Misc. Topics: Number Theory CS 250, Discrete Structures, Fall 2011 Nitesh Saxena.
POON TENG HIN.  RSA  Shamir’s Three-Pass Protocol  Other issues.
David Kauchak CS52 – Spring 2015
Encryption CS110: Computer Science and the Internet.
CS Modular Division and RSA1 RSA Public Key Encryption To do RSA we need fast Modular Exponentiation and Primality generation which we have shown.
Public Key Cryptosystem Introduced in 1976 by Diffie and Hellman [2] In PKC different keys are used for encryption and decryption 1978: First Two Implementations.
CS 4803 Fall 04 Public Key Algorithms. Modular Arithmetic n Public key algorithms are based on modular arithmetic. n Modular addition. n Modular multiplication.
Introduction to Cryptography Lecture 9. Public – Key Cryptosystems Each participant has a public key and a private key. It should be infeasible to determine.
Primality Testing. Introduction The primality test provides the probability of whether or not a large number is prime. Several theorems including Fermat’s.
RSA Cryptosystem Great Theoretical Ideas In Computer Science S. Rudich V. Adamchik CS Spring 2006 Lecture 8Feb. 09, 2006Carnegie Mellon University.
CS/COE 1501 Recitation RSA Encryption/Decryption Extended Euclidean Algorithm Digital Signatures.
Information and Computer Security CPIS 312 Lab 8 1 Asymmetric Key Algorithms RSA Algorithm TRIGUI Mohamed Salim.
Cryptography RSA Algorithm BY : Wesam Fadheel Computer science department - WMU CS-6800 Advanced Theory of Computation Instructor: Dr. Elise De Doncker.
Intro to Cryptography ICS 6D Sandy Irani. Cryptography Intro Alice wants to send a message to Bob so that even if Eve can see the transmitted information,
week 8Complexity of Algorithms1 Elementary Number Theory Given positive integers a and b, we use the notation a¦b to indicated that a divides b, i.e.,
CPIS 312 Chapter Four: PUBLIC KEY CRYPTO. Index 2 A.Introduction A.1 Asymmetric Key Cryptography- Introduction A.2 General ideas about the Public Key.
RSA cryptosystem with large key length
Public Key Cryptosystem
Number Theory and Euclidean Algorithm
Rivest, Shamir and Adleman
CSE 321 Discrete Structures
Introduction to Algorithms Second Edition by
Presentation transcript:

Codes, Ciphers, and Cryptography-RSA Encryption Michael A. Karls Ball State University

The RSA Encryption Scheme We now look at the public key cryptography scheme developed by Rivest, Shamir, and Adleman (RSA) in 1977. In order to understand this scheme, we need some definitions!

Definition of Divisor Let a and b be integers, with b  0. We say that b divides a or b is a divisor of a if a = b x c for some integer c. Notation: b|a Example 1: 3|24 since 24 = 3 x 8. Divisors of 12 are: -12, -6, -4, -3, -2, -1, 1, 2, 3, 4, 6, 12

Definition of Greatest Common Divisor (GCD) Let a and b be integers, not both zero. The greatest common divisor (GCD) of a and b is the largest integer that divides both a and b. Notation: (a,b) Example 2: Divisors of 6: -6, -3, -2, -1, 1, 2, 3, 6 Divisors of 8: -8, -4, -2, -1, 1, 2, 4, 8 Thus, (6,8) = 2 Since the divisors of 7 are -7, -1, 1, 7, (7,8) = 1.

Definition of Relatively Prime Two integers whose GCD is 1 are said to be relatively prime. Example 3: Since (7,8) = 1, 7 and 8 are relatively prime.

Definition of Prime Number A positive integer p is said to be prime if p>1 and the only positive divisors of p are 1 and p. Example 4: 2, 3, and 7 are prime. 6, 8, 10, 100 are not prime (composite).

RSA Scheme (with Alice and Bob!) Step 1: Alice chooses two huge prime numbers p and q. Note: Alice keeps p and q secret! Example 5: p = 47 and q = 59.

RSA Scheme (with Alice and Bob!) (cont.) Step 2: Alice computes N = p x q. Then she computes k = (p-1)(q-1). Finally, she chooses an integer e such that 1<e<N and (e,k) =1. Example 5 (cont.): N = 47 x 59 = 2773. k = 46 x 58 = 2668. e = 17. Choice of e is o.k., since 1<17<2773 and (17,2668)= 1.

RSA Scheme (with Alice and Bob!) (cont.) Step 3: Alice computes d = e-1 mod k. Alice publishes her public key: N, e. Alice keeps secret her private key: p, q, d, k. Example 5 (cont.): d = 17-1 mod 2668 = 157. Alice’s public key: N = 2773; e = 17. Alice’s private key: p = 47; q = 59; d = 157; k = 2668.

RSA Scheme (with Alice and Bob!) (cont.) Step 4: Suppose Bob wants to send a message to Alice. To do so, he looks up Alice’s public key, converts the message into numbers M<N. Example 5 (cont.): Plaintext is HELLO HELLO  HE LL O_ Assign 00space; 01A; 02B, … , 26Z (or use ASCII). ¨Plaintext Plain # HE 0805 LL 1212 0_ 1500

RSA Scheme (with Alice and Bob!) (cont.) Step 4 (cont.): Next Bob computes: C = Me mod N (1) for each plaintext number M to get ciphertext number C. Example 5 (cont.): 080517 mod 2773 = 542. 121217 mod 2773 = 2345. 150017 mod 2773 = 2417. Encrypted message is 0542 2345 2417.

RSA Scheme (with Alice and Bob!) (cont.) Step 5: Bob emails Alice the encrypted message. To decrypt, Alice uses her private key and computes: M = Cd mod N (2) Example 5 (cont.): 0542157 mod 2773 = 805. 2345157 mod 2773 = 1212. 2417157 mod 2773 = 1500. Decrypted message is HE LL 0_.