3,305 views
0 votes
0 votes

Alice chooses 5 and 11 as P and Q respectively and e is a random number 13. Public key for Alice 35. Private key for Bob 17. What is the value of Cipher text for Alice,Plain text for Bob, Private key for Alice, Public key for Bob?

------------------------------------------------------------------------------------------------------------------------------

Now I got confuse with formula and logic

Can someone tell me which logic used where?

2 Answers

Best answer
1 votes
1 votes
let me first define something that i know,
n = p*q                                                   n=5*11 =55
z = p-1* q-1                                             z= 4*10=40
public key = (e, n)          where e should be relative prime to z
private key = (d, n),        where d is chooses such that this equation is satisfy: ed =1 ( mod z)               d= 37
cipher text= (Message) ^e mod n                      
plain text = (cipher text) ^d mod n
hope this will help !
selected by
1 votes
1 votes

It's RSA Algorithm

A great explanation with example here 

https://en.wikipedia.org/wiki/RSA_(cryptosystem)

There are phases in RSA.

The prime numbers P and Q is used in Key Generation phase. These numbers are used to generate the Public and Private keys for the sender and receiver.

Computing n,e and d is a part of algorithm. It's a standard process.

In public key cryptography, when A wants to send message to B. A requests B to send it's public key. A then encrypts message using public key of B and sends to B. Now, any intruder cannot decrypt it as it can only be decrypted using B's private key. 

Public key is a combination of (n,e) and when A gets this combination from B, it encrypts message using formula

c (cipher) = memod n

The cipher generated can only be decrypted by B's private key. Now, private key is combination of (d,n). Note that value of d is never shared as it's a part of private key for the receiver. Now B decrypts cipher using

m = cdmod n

Hope this helps :)

Related questions

2 votes
2 votes
2 answers
1
dragonball asked Jan 4, 2018
1,909 views
Plz tell me how to solve this .I am feeling problem o calculate 10 = p^5 mod 35 . How to solve this type of question quickly.
2 votes
2 votes
2 answers
2
piya asked Jul 23, 2018
11,946 views
In an RSA system, the public key of given user is e = 31 and n = 3599. The private key of user will be ________