Implement the extended euclidean algorithm

Assignment Help JAVA Programming
Reference no: EM131468296

Practical

Objective: Understand Coding, RSA and related issues.

1. Implement the Extended Euclidean Algorithm using C/C++ or Java. The objective is to find the inverse modular for a number. The input is two numbers (a n) and the output is a number b satisfying

ab modn =1

if this number exists. Otherwise present an error information. (Hint: first implement the algorithm of finding the greatest common divisor for two numbers).

2. A smudge has obscured one of the digits of the ISBN code

0-8018-x 073-1.

Determine the unknown digit x.

3. Implement the following prime number test algorithm (Called Lehmann Algorithm) in C/C++ or Java. To test whether a number p is a prime number

Choose a random number a being less than p

- Calculate r = ap-1/2 mod p

- If r is not 1 or -1 then p is definitely not a prime.

- If r=1 or -1 the likelihood that p is not prime is at most than 50 percent.

Repeat this algorithm t times, if the calculation equals to 1 or -1 but does not always equal to 1, then p is probably prime with an error rate of 1 in 1/2t

4. The following is the description of RSA

Public Key

N=pq ( p q are prime numbers but keep secret), e is relative prime to (p-1)(q-1)

Private Key d = e-1mod (p-1)(q-1)

Given message m <n

Encryption c = memod N

Decryption m= Cd mod N

If message m>n, we usually split m into several small blocks with each block less being than n.

In this algorithm, if we given p=47, q=71, e=79, m=682534127893. Solve d using question 1 in this practical and do encryption and decryption for m.

Reference no: EM131468296

Questions Cloud

What form of intrusion-detection software do they use : Visit the IT department of a company and ascertain what hardware they use in their computer system's defense. Do they use a hardware firewall in addition.
Human resource manager of a small firm : Imagine that you are the human resource manager of a small firm. You learn that the monthly premiums for the company's existing health insurance policy.
Employers provide employee beneifts : Why do employers provide employee beneifts, rather than providing all compersation in the from of pay and letting employees buy the services they want?
Research paper on the treatment of osteoporosis : Write and Evidenced based practice research paper on the treatment of osteoporosis.
Implement the extended euclidean algorithm : Implement the Extended Euclidean Algorithm using C/C++ or Java. The objective is to find the inverse modular for a number.
Discuss the decision-making style of a current : The first part of your paper will be to analyze and discuss the decision-making style of a current or former "boss".
What additional steps would you recommend to runa : Runa Singh is the network administrator in charge of network security for a medium-sized company. The firm already has a firewall, its network is divided.
Improve promotion satisfaction : What steps can organizations take to improve promotion satisfaction, supervision satisfaction, and coworker satisfaction?
How expensive are those strategies : Describe other ways that organizations can improve affective, continuance, and normative commitment, other than the strategies suggested in this chapter.

Reviews

len1468296

4/20/2017 2:38:53 AM

Implement only question 3. It has to do power function, but this power function has to be very large. Assume you are doing 7874^(15253763). Better to implement using binary modular representation.

Write a Review

JAVA Programming Questions & Answers

  Implement the client and server components

The basic requirements of this assignment are to implement the client and server components as discussed above. The basic protocol of the system is described below: The operations of the client are: SEND_SERVER_MESG: send a basic text message to th..

  Implementation of the finger protocol

Server programs are rarely implemented as non-threaded applications, even though that is how you implemented your previous server application.

  How both the time and space complexity change

Write the java code that implements the methods and Discuss how both the time and space complexity change for each of the methods above if the underlying structure of your SmartULS is an array or a linked list?

  Swing gui java application running with eclipse on windows x

To test the program just start MoneyMain to see if you click the icons for the detail screens and click Report to view the two reports.

  Implement a class person with two fields name and age

Implement a class Person with two fields name and age, and a class Car with three fields

  Explain the concept of dma with cpu overhead

Explain the concept of DMA with CPU overhead

  How to add a static data member

Create one project for each problem; add comments to your code -  write a program which Add a static data member to count the number of objects will be created.

  Develop java application to add a contact into contact table

Develop a Java application to add a contact into the contact table, and display all contacts in the contact table. The contact table contains two columns, FullName, and PhoneNumber.

  Assessment taskyour task is to develop a java application

assessment taskyour task is to develop a java application that allows the user to read travel booking data from a text

  Write a program that allows a user to enter a line of text

Write a program that allows a user to enter a line of text, counts number of words and number of vowels in the sentence, and gives the average number of vowels per word in the message

  How to get how to get the output

how to get the output of the java program.  Please explain in steps on how to get the output.

  Create a uml class diagram for your class

Create a UML class diagram for your class. Your class should have at least 3 attributes (instance variables). Attributes should be appropriately typed and scoped to incorporate data hiding.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd