0% found this document useful (0 votes)
7 views2 pages

Crypt Assignment 4

This document provides questions from cryptography assignments related to factoring numbers and the Diffie-Hellman key exchange algorithm. Students are asked to factor numbers using methods like Fermat's factorization test, the quadratic sieve algorithm, and Pollard's rho method. Other questions involve finding discrete logarithms, determining primitive roots, and implementing and analyzing the security of Diffie-Hellman key exchange over the group Z/nZ of integers modulo n.

Uploaded by

Lewis Evans
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views2 pages

Crypt Assignment 4

This document provides questions from cryptography assignments related to factoring numbers and the Diffie-Hellman key exchange algorithm. Students are asked to factor numbers using methods like Fermat's factorization test, the quadratic sieve algorithm, and Pollard's rho method. Other questions involve finding discrete logarithms, determining primitive roots, and implementing and analyzing the security of Diffie-Hellman key exchange over the group Z/nZ of integers modulo n.

Uploaded by

Lewis Evans
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Cryptography Assignment 4: Factoring & Diffie-Hellman

Please answer questions 4 and 9.


If you would like a challenge, also try question 11.
Please hand your solutions in by 2pm Monday 13th March (Week 10)

1. I proudly announce my RSA number N = 1, 689, 786, 806, 723 is far too hard to
factor on your calculator. I tell you it is made from a twin prime pair, in other words
N = p(p + 2). Prove me wrong by factoring this number using only a calculator.

2. Let N = pq with p and q distinct primes. Show that if q > 9p then √ Fermat’s
factorisation test is quicker than the variant (where you search for T > 2 N such
that T 2 − 4N is also a square.)

3. Knowing 1632 ≡ 502 (mod 8023) factor N = 8023.

4. (Exam question from 2013/14)


(a) Use Fermat’s factorisation method to factor N = 7387.
(b) Show that if N = pq with p and q distinct odd primes, then Fermat’s factori-
sation method will always eventually lead to a factor of N. If p < q how many
steps will the algorithm take before it finds a factor?
(c) The output of an application of the quadratic sieve for N = 23213 yields the
following equations
2242 ≡ 2 × 3 × 54 (mod N)
2 3 3
341 ≡ 2 × 3 (mod N)
Using this, find a factor of N.
(d) Use Pollard’s rho method with the function f (x) = x2 +1 (mod N) and starting
with x0 = 2 and y0 = 2 to factor N = 319. (HINT: It will terminate after the
second step).

5. (Exam question from 2014/15)


(a) Briefly describe Fermat’s factorisation test.
(b) Using Fermat’s factorisation test on N = 13447, show that N = 113 × 119.
(c) By calculating 8118 (mod 119) conclude that 119 is not a prime.
(d) Using the facts that
112 ≡ 2 (mod 119)

and

132 ≡ 50 (mod 119)


factorise 119.

1
Cryptography Assignment 4

(e) One of the key reasons why the quadratic sieve works is that for an integer N,
if there exists integers x and y such that

x2 ≡ y2 (mod N)

but
x . ±y (mod N)
then N is composite. Prove this fact.

6. By explicitly calculating 3n (mod 7) for all 1 ≤ n ≤ 6, show that 3 is a primitive


root modulo 7. By raising 3 to a suitable power, find the other possible generator of
(Z/7Z)∗ .

7. By calculating 3n (mod 41) and 6n (mod 41) for a few (well-chosen) n, show one
of them is a primitive root mod 41 and one of them is not. How many primitive
roots are there mod 41?

8. Knowing that the prime 101 has a primitive root 2, and knowing that

269 ≡ 3 (mod 101) and 224 ≡ 5 (mod 101)

find dlog101,2 (45).


(Hint: 45 = 3 × 3 × 5).

9. The prime 101 has a primitive root 3. Knowing that dlog101,3 (2) = 29 find the
discrete log of 4, 8 and 16 with respect to 3 modulo 101. Find the multiplicative
inverse of 3 modulo 101. Hence find dlog101,3 (68).

10. Alice and Bob wish to share a secret key using Diffie-Hellman. They choose the
prime p = 83 and the primitive root g = 5. Alice chooses her secret exponent to be
a = 9 and Bob chooses his secret exponent to be b = 10. What does Alice send to
Bob? What does Bob send to Alice? What is their secret key?

11. The Diffie-Hellman algorithm works on any cyclic group. Describe the analogous
algorithm on the group Z/nZ (that is the integers mod n, with the group operation
of addition mod n). Explain how this form of the algorithm is completely insecure,
and anybody could find the shared “secret”.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy