Announcements: HW3 updated. Due next Thursday HW3 updated. Due next Thursday Written quiz tomorrow on chapters 1-2 (next slide) Written quiz tomorrow on.

Slides:



Advertisements
Similar presentations
Cryptography and Network Security Chapter 9
Advertisements

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.
Section 4.1: Primes, Factorization, and the Euclidean Algorithm Practice HW (not to hand in) From Barr Text p. 160 # 6, 7, 8, 11, 12, 13.
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 numbers.
Announcements: 1. Congrats on reaching the halfway point once again! 2. DES graded soon 3. Short “pop” quiz on Ch 3. (Thursday at earliest) 4. Reminder:
Public Key Cryptosystems - RSA Receiver Sender Eavesdroppe r p q p q p q p and q prime.
Data encryption with big prime numbers
Everyday Math 5th Grade: Unit One.
22C:19 Discrete Math Integers and Modular Arithmetic Fall 2010 Sukumar Ghosh.
Announcements: Please use pencil on quizzes if possible Please use pencil on quizzes if possible Knuth quotes, part 1 Knuth quotes, part 1Questions?Today:
Announcements: See schedule for weeks 8 and 9 See schedule for weeks 8 and 9 Project workdays, due dates, exam Project workdays, due dates, exam Projects:
Announcements: 1. Term project groups and topics due tomorrow midnight Waiting for posts from most of you. Questions? This week: Primality testing, factoring.
Announcements: 1. Pass in Homework 5 now. 2. Term project groups and topics due by Friday 1.Can use discussion forum to find teammates 3. HW6 posted, due.
1 Chapter 7– Introduction to Number Theory Instructor: 孫宏民 Room: EECS 6402, Tel: , Fax :
Announcements: Homework 1 returned. Comments from Kevin? Homework 1 returned. Comments from Kevin? Matlab: tutorial available at
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2002 Tuesday, 26 November Number-Theoretic Algorithms Chapter 31.
Announcements: 1. Short “pop” quiz on Ch 3 (today?) 2. Term project groups and topics due midnight 3. HW6 due Tuesday. Questions? This week: Primality.
Cryptography Lecture 11: Oct 12. Cryptography AliceBob Cryptography is the study of methods for sending and receiving secret messages. adversary Goal:
Announcements: 1. Congrats on reaching the halfway point once again! 2. Reminder: HW5 due tomorrow, HW6 due Tuesday after break 3. Term project groups.
Announcements: HW3 updated. Due next Thursday HW3 updated. Due next Thursday Written quiz today Written quiz today Computer quiz next Friday on breaking.
Announcements: 1. Pass in worksheet on using RSA now. 2. DES graded soon 3. Short “pop” quiz on Ch 3 (Thursday at earliest) 4. Term project groups and.
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 numbers.
Lecture 3.2: Public Key Cryptography II CS 436/636/736 Spring 2012 Nitesh Saxena.
Chapter 8 – Introduction to Number Theory Prime Numbers
DTTF/NB479: Dszquphsbqiz Day 9 Announcements: Homework 2 due now Homework 2 due now Computer quiz Thursday on chapter 2 Computer quiz Thursday on 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.
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 numbers.
Announcements: Homework 2 due now Homework 2 due now Quiz this Friday on concepts from chapter 2 Quiz this Friday on concepts from chapter 2 Practical.
CSE 321 Discrete Structures Winter 2008 Lecture 10 Number Theory: Primality.
Cryptography A little number theory Public/private key cryptography –Based on slides of William Stallings and Lawrie Brown.

1 Cryptography and Network Security Third Edition by William Stallings Lecture slides by Lawrie Brown Chapter 4 – Finite Fields.
Section 4.3: Fermat’s Little Theorem Practice HW (not to hand in) From Barr Text p. 284 # 1, 2.
CS 312: Algorithm Analysis Lecture #3: Algorithms for Modular Arithmetic, Modular Exponentiation This work is licensed under a Creative Commons Attribution-Share.
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.
Announcements: HW4 – DES due Thursday HW4 – DES due Thursday I have installed, or will install: Java, C (gcc), Python. What other languages? Please make.
Cryptography Lecture 7: RSA Primality Testing Piotr Faliszewski.
CS 312: Algorithm Analysis Lecture #4: Primality Testing, GCD This work is licensed under a Creative Commons Attribution-Share Alike 3.0 Unported License.Creative.
Chinese Remainder Theorem Dec 29 Picture from ………………………
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.
Lecture 6.1: Misc. Topics: Number Theory CS 250, Discrete Structures, Fall 2011 Nitesh Saxena.
What use are prime numbers? ?. o All the primes, apart from 2, are odd numbers. o 1 is not a prime number. Why? o There are infinitely many prime numbers!
9/22/15UB Fall 2015 CSE565: S. Upadhyaya Lec 7.1 CSE565: Computer Security Lecture 7 Number Theory Concepts Shambhu Upadhyaya Computer Science & Eng. University.
The Euler-Fermat Theorem Our text calls this “Euler’s Formula”, but I prefer the above name, giving due credit to Fermat. Obvious question: Can Fermat’s.
Announcements: Homework 2 returned Homework 2 returned Monday: Written (concept and small calculations) exam on breaking ch 2 ciphers Monday: Written (concept.
Ch1 - Algorithms with numbers Basic arithmetic Basic arithmetic Addition Addition Multiplication Multiplication Division Division Modular arithmetic Modular.
Week 4 - Wednesday.  What did we talk about last time?  Finished DES  AES.
9.1 Primes and Related Congruence Equations 23 Sep 2013.
CS 312: Algorithm Analysis Lecture #4: Primality Testing, GCD This work is licensed under a Creative Commons Attribution-Share Alike 3.0 Unported License.Creative.
Lecture 2-3 Basic Number Theory and Algebra. In modern cryptographic systems, the messages are represented by numerical values prior to being encrypted.
Data encryption with big prime numbers DANIEL FREEMAN, SLU.
Chapter 1 Algorithms with Numbers. Bases and Logs How many digits does it take to represent the number N >= 0 in base 2? With k digits the largest number.
MA/CSSE 473 Day 09 Modular Division Revisited Fermat's Little Theorem Primality Testing.
CS480 Cryptography and Information Security
L131 Exponential Inverses Finding modular inverses is good enough for decoding simple modular cryptography. However, in RSA encryption consists of exponentiating.
Lecture 6. RSA Use in Encryption to encrypt a message M the sender: – obtains public key of recipient PU={e,n} – computes: C = M e mod n, where 0≤M
Copyright © Zeph Grunschlag, RSA Encryption Zeph Grunschlag.
Public Key Encryption Major topics The RSA scheme was devised in 1978
CSE565: Computer Security Lecture 7 Number Theory Concepts
DTTF/NB479: Dszquphsbqiz Day 22
Cryptography and Network Security
Introduction to Number Theory
Public Key Cryptosystems - RSA
Number Theory (Chapter 7)
Cryptography and Network Security
Copyright © Zeph Grunschlag,
Lecture 2-3 Basic Number Theory and Algebra
Presentation transcript:

Announcements: HW3 updated. Due next Thursday HW3 updated. Due next Thursday Written quiz tomorrow on chapters 1-2 (next slide) Written quiz tomorrow on chapters 1-2 (next slide) Computer quiz next week on breaking codes from chapter 2 Computer quiz next week on breaking codes from chapter 2Questions?Today: Finish Modular Exponents example Finish Modular Exponents example Fermat’s little theorem Fermat’s little theorem Euler’s theorem Euler’s theorem DTTF/NB479: DszquphsbqizDay 11

Tomorrow’s Quiz Rules: Written problems Written problems Closed book and computer Closed book and computer You may bring a note sheet: 1 handwritten sheet of 8.5 x 11 paper, one side only. You may bring a note sheet: 1 handwritten sheet of 8.5 x 11 paper, one side only.Content: Concepts of the algorithms we discussed, how they work, how you can break them using various attacks Concepts of the algorithms we discussed, how they work, how you can break them using various attacks Inverses of integers and matrices (mod n) Inverses of integers and matrices (mod n) Working out some examples by hand, like 5 -1 mod (7) Working out some examples by hand, like 5 -1 mod (7) Anything else from ch 1-2, but nothing that will require a computer. Anything else from ch 1-2, but nothing that will require a computer.

Modular Exponentiation Compute 3^2000 (mod 152) Technique: Repeatedly square 3, but take mod at each step. Repeatedly square 3, but take mod at each step. Then multiply the terms you need to get the desired power. Then multiply the terms you need to get the desired power. Matlab’s powermod() (All congruences are mod 152)

Is there an easier way to compute (mod 152)? Consider first a similar example, (mod 17) (chosen so p is prime). Today’s theorems will be really important when dealing with RSA encryption – pay careful attention!

Fermat’s Little Theorem if p is prime and doesn’t divide a. Examples: 2 2 (mod 3), 4 4 (mod ???) So what’s ( )(mod 17)?

Converse when a=2 If p is prime and doesn’t divide a, Converse: If, p is prime and doesn’t divide a. This is almost always true when a = 2. Rare counterexamples: n = 561 =3*11*17, but n = 561 =3*11*17, but n = 1729 = 7*13*19 n = 1729 = 7*13*19 Can do first one by hand if use Fermat and combine results with Chinese Remainder Theorem Can do first one by hand if use Fermat and combine results with Chinese Remainder Theorem

Using Fermat within a primality testing scheme Even? div by other small primes? Prime by Factoring/ advanced techn.? n no yes prime

Using Fermat within a primality testing scheme (ch 6) Use Fermat as a filter since it’s faster than factoring (if calculated using the powermod method). Odd? div by other small primes? Prime by Factoring/ advanced techn.? n no yes prime Fermat: p prime  2 p-1 = 1 (mod p) Contrapositive? Why can’t we just compute 2 n-1 (mod n) Using Fermat if it’s so much faster?

Euler’s Theorem Analog to Fermat for composite modulus What’s  (n)?  (n) = the number of integers a, s.t., 1<= a <= n where gcd(a,n) = 1. Ex:  (10) = 4. What’s  (p) for p prime? What about  (n), where n =pq (a product of 2 primes)

Euler’s  -function Notes: The p are taken from the set of distinct primes that divide n Eg, for n=60, use p = 2 (only once), 3, and 5. Answer:  Answer:  When we compute the ratios, what about mutual exclusion? Consider the intuition: Crossing out every number divisible by 3 leaves 2/3 of them. Crossing out every number divisible by 3 leaves 2/3 of them. If I crossed out the even numbers first, then crossing out every odd number divisible by 3 still leaves 2/3 of those left! If I crossed out the even numbers first, then crossing out every odd number divisible by 3 still leaves 2/3 of those left! *Thanks to Bill Waite for this good insight

Back to Euler’s Theorem As long as gcd(a,n,) = 1 Examples: Find last 3 digits of Find last 3 digits of Find (mod 12) Find (mod 12) Find (mod 101) Find (mod 101) Basic Principle: when working mod n, view the exponents mod  (n).