Number Theory Algorithms and Cryptography Algorithms Prepared by John Reif, Ph.D. Analysis of Algorithms.

Slides:



Advertisements
Similar presentations
Public Key Cryptography The RSA Cryptosystem. by William M. Faucette Department of Mathematics State University of West Georgia.
Advertisements

1 Lect. 12: Number Theory. Contents Prime and Relative Prime Numbers Modular Arithmetic Fermat’s and Euler’s Theorem Extended Euclid’s Algorithm.
COMP 170 L2 Page 1 L06: The RSA Algorithm l Objective: n Present the RSA Cryptosystem n Prove its correctness n Discuss related issues.
CSE331: Introduction to Networks and Security Lecture 19 Fall 2002.
Cryptography and Network Security
Chapter 8 – Introduction to Number Theory. Prime Numbers prime numbers only have divisors of 1 and self –they cannot be written as a product of other.
Computability and Complexity
Primality Testing Patrick Lee 12 July 2003 (updated on 13 July 2003)
Week 3 - Friday.  What did we talk about last time?  AES  Public key cryptography.
22C:19 Discrete Math Integers and Modular Arithmetic Fall 2010 Sukumar Ghosh.
Notation Intro. Number Theory Online Cryptography Course Dan Boneh
Great Theoretical Ideas in Computer Science.
and Factoring Integers (I)
CSC2110 Discrete Mathematics Tutorial 5 GCD and Modular Arithmetic
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Spring, 2009 Tuesday, 28 April Number-Theoretic Algorithms Chapter 31.
RSA ( Rivest, Shamir, Adleman) Public Key Cryptosystem
COMP 170 L2 Page 1 Part 2 of Course Chapter 2 of Textbook.
The RSA Cryptosystem and Factoring Integers (II) Rong-Jaye Chen.
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2002 Tuesday, 26 November Number-Theoretic Algorithms Chapter 31.
6/20/2015 5:05 AMNumerical Algorithms1 x x1x
CS470, A.SelcukPublic Key Cryptography1 CS 470 Introduction to Applied Cryptography Instructor: Ali Aydin Selcuk.
and Factoring Integers
CSE 321 Discrete Structures Winter 2008 Lecture 8 Number Theory: Modular Arithmetic.
Chapter 8 – Introduction to Number Theory Prime Numbers
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2001 Lecture 7 Tuesday, 11/6/01 Number-Theoretic Algorithms Chapter.
Cryptography and Network Security Chapter 8. Chapter 8 – Introduction to Number Theory The Devil said to Daniel Webster: "Set me a task I can't carry.
Dan Boneh Intro. Number Theory Modular e’th roots Online Cryptography Course Dan Boneh.
CSE 321 Discrete Structures Winter 2008 Lecture 10 Number Theory: Primality.
CSE 311 Foundations of Computing I Lecture 12 Primes, GCD, Modular Inverse Spring
Software Security Seminar - 1 Chapter 11. Mathematical Background 발표자 : 안병희 Applied Cryptography.
1 Network Security Lecture 6 Public Key Algorithms Waleed Ejaz
Module :MA3036NI Cryptography and Number Theory Lecture Week 7
Information Security and Management 4. Finite Fields 8
Great Theoretical Ideas in Computer Science.
RSA Ramki Thurimella.
The Complexity of Primality Testing. What is Primality Testing? Testing whether an integer is prime or not. – An integer p is prime if the only integers.
Cryptography Dec 29. This Lecture In this last lecture for number theory, we will see probably the most important application of number theory in computer.
Lecture 2 Basic Number Theory and Algebra. In modern cryptographic systems,the messages are represented by numerical values prior to being encrypted and.
Introduction to Algorithms Second Edition by Cormen, Leiserson, Rivest & Stein Chapter 31.
Advanced Algebraic Algorithms on Integers and Polynomials Prepared by John Reif, Ph.D. Analysis of Algorithms.
YSLInformation Security -- Public-Key Cryptography1 Prime and Relatively Prime Numbers Divisors: We say that b  0 divides a if a = mb for some m, where.
Fall 2002CS 395: Computer Security1 Chapters 4 and 8: The Mathematics Required for Public Key Cryptography In case you’re beginning to worry that this.
1 Network and Computer Security (CS 475) Modular Arithmetic and the RSA Public Key Cryptosystem Jeremy R. Johnson.
Scott CH Huang COM 5336 Cryptography Lecture 6 Public Key Cryptography & RSA Scott CH Huang COM 5336 Cryptography Lecture 6.
Lecture 6.1: Misc. Topics: Number Theory CS 250, Discrete Structures, Fall 2011 Nitesh Saxena.
MA/CSSE 473 Day 08 Extended Euclid's Algorithm Modular Division Fermat's little theorem.
Ch1 - Algorithms with numbers Basic arithmetic Basic arithmetic Addition Addition Multiplication Multiplication Division Division Modular arithmetic Modular.
Great Theoretical Ideas in Computer Science for Some.
Modular Arithmetic and the RSA Cryptosystem Great Theoretical Ideas In Computer Science John LaffertyCS Fall 2005 Lecture 9Sept 27, 2005Carnegie.
Week 4 - Wednesday.  What did we talk about last time?  Finished DES  AES.
Primality Testing. Introduction The primality test provides the probability of whether or not a large number is prime. Several theorems including Fermat’s.
9.1 Primes and Related Congruence Equations 23 Sep 2013.
Lecture 2-3 Basic Number Theory and Algebra. In modern cryptographic systems, the messages are represented by numerical values prior to being encrypted.
RSA Cryptosystem Great Theoretical Ideas In Computer Science S. Rudich V. Adamchik CS Spring 2006 Lecture 8Feb. 09, 2006Carnegie Mellon University.
The Fundamentals: Algorithms, Integers, and Matrices CSC-2259 Discrete Structures Konstantin Busch - LSU1.
CS480 Cryptography and Information Security
Copyright © Zeph Grunschlag, RSA Encryption Zeph Grunschlag.
Number-Theoretic Algorithms
PUBLIC-KEY ENCRYPTION Focusing on RSA
ALGORITHM NUMBER THEORY
Number Theory (Chapter 7)
RSA Cryptosystem Bits PCs Memory MB ,000 4GB 1,020
Prime and Relatively Prime Numbers
Discrete Math for CS CMPSC 360 LECTURE 12 Last time: Stable matching
Introduction to Cryptography
Analysis of the RSA Encryption Algorithm
Tuesday, 27 April Number-Theoretic Algorithms Chapter 31
CSE 321 Discrete Structures
Patrick Lee 12 July 2003 (updated on 13 July 2003)
Lecture 2-3 Basic Number Theory and Algebra
Presentation transcript:

Number Theory Algorithms and Cryptography Algorithms Prepared by John Reif, Ph.D. Analysis of Algorithms

Number Theory Algorithms a)GCD b)Multiplicative Inverse c)Fermat & Euler ’ s Theorems d)Public Key Cryptographic Systems e)Primality Testing

Number Theory Algorithms (cont ’ d) Main Reading Selections: CLR, Chapter 33

Euclid ’ s Algorithm Greatest Common Divisor Euclid ’ s Algorithm

Euclid ’ s Algorithm (cont ’ d) Inductive proof of correctness:

Euclid ’ s Algorithm (cont ’ d) Time Analysis of Euclid ’ s Algorithm for n bit numbers u,v

Euclid ’ s Algorithm (cont ’ d) Fibonacci worst case:

Euclid ’ s Algorithm (cont ’ d) Improved Algorithm

Extended GCD Algorithm

Extended GCD Algorithm (cont ’ d) Theorem Proof

Extended GCD Algorithm (cont ’ d) Corollary If gcd(x,y) = 1 then x' is the modular inverse of x modulo y Proof

Modular Laws Gives Algorithm for Modular Laws

Modular Laws (cont ’ d)

Fermat ’ s Little Theorem If n prime then a n = a mod n Proof by Euler

Fermat ’ s Little Theorem (cont ’ d)

Euler ’ s Theorem Φ(n) = number of integers in {1,…, n-1} relatively prime to n Euler ’ s Theorem Proof

Euler ’ s Theorem (cont ’ d) Lemma Proof

Euler ’ s Theorem (cont ’ d) By Law A and Lemma By Law B

Taking Powers mod n by “ Repeated Squaring ” Problem: Compute a e mod b

Taking Powers mod n by “ Repeated Squaring ” (cont ’ d) Time Cost

Rivest, Sharmir, Adelman (RSA) Encryption Algorithm M = integer message e = “ encryption integer ” for user A Cryptogram

Rivest, Sharmir, Adelman (RSA) Encryption Algorithm (cont ’ d) Method

Rivest, Sharmir, Adelman (RSA) Encryption Algorithm (cont ’ d) Theorem

Rivest, Sharmir, Adelman (RSA) Encryption Algorithm (cont ’ d) Proof

Rivest, Sharmir, Adelman (RSA) Encryption Algorithm (cont ’ d) By Euler ’ s Theorem

Security of RSA Cryptosystem Theorem If can compute d in polynomial time, then can factor n in polynomial time Proof e· d-1 is a multiple of φ(n) But Miller has shown can factor n from any multiple of φ(n)

Security of RSA Cryptosystem (cont ’ d)

Rabin ’ s Public Key Crypto System Use private large primes p, q public key n=q p message M cryptogram M 2 mod n Theorem If cryptosystem can be broken, then can factor key n

Rabin ’ s Public Key Crypto System (cont ’ d) Proof In either case, two independent solutions for M give factorization of n, i.e., a factor of n is gcd (n, γ -β).

Rabin ’ s Public Key Crypto System (cont ’ d) Rabin ’ s Algorithm for factoring n, given a way to break his cryptosystem.

Quadratic Residues

Jacobi Function

Jacobi Function (cont ’ d) Gauss ’ s Quadratic Reciprocity Law Rivest Algorithm

Jacobi Function (cont ’ d) Theorem (Fermat)

Theorem: Primes are in NP Proof

Theorem & Primes NP (cont ’ d) Note

Primality Testing Testing Goal of Randomized Primality Testing

Primality Testing (cont ’ d) Solovey & Strassen Primality Test quadratic reciprocal law

Definitions

Theorem of Solovey & Strassen Theorem Proof

Theorem of Solovey & Strassen (cont ’ d)

Then by Chinese Remainder Theorem, Since a is relatively prime to n,

Theorem of Solovey & Strassen (cont ’ d)

Miller Miller ’ s Primality Test

Theorem (Miller) Assuming the extended RH, if n is composite, then W n (a) holds for some a ∈ {1,2,…, c log 2 n} Miller ’ s Test assumes extended RH (not proved) Miller (cont ’ d)

Miller – Rabin Randomized Primality Test Theorem

Number Theory Algorithms and Cryptography Algorithms Prepared by John Reif, Ph.D. Analysis of Algorithms