0% found this document useful (0 votes)
32 views

Experiment No.1: Chaitanya Koparkar Roll No: 10-130 Te-Inft 1

The document summarizes an experiment conducted to study the RSA encryption algorithm. It provides the theory behind RSA, which is based on the difficulty of factoring large integers. It then outlines the key steps of the RSA algorithm: (1) selecting two large prime numbers, (2) computing the product and Euler totient, (3) choosing a public key that has no common factors with the totient, (4) computing a private key using the totient and public key. The experiment output shows encrypting and decrypting a sample number using the RSA keys. The conclusion confirms RSA can be used for encryption and decryption.

Uploaded by

ckoparkar123
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
32 views

Experiment No.1: Chaitanya Koparkar Roll No: 10-130 Te-Inft 1

The document summarizes an experiment conducted to study the RSA encryption algorithm. It provides the theory behind RSA, which is based on the difficulty of factoring large integers. It then outlines the key steps of the RSA algorithm: (1) selecting two large prime numbers, (2) computing the product and Euler totient, (3) choosing a public key that has no common factors with the totient, (4) computing a private key using the totient and public key. The experiment output shows encrypting and decrypting a sample number using the RSA keys. The conclusion confirms RSA can be used for encryption and decryption.

Uploaded by

ckoparkar123
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 1

Experiment no.

1
Chaitanya Koparkar Roll No : 10-130 TE-INFT 1

Title : To study RSA algorithm. Theory : RSA is an algorithm for public-key cryptography that is based on the presumed difficulty of factoring large integers, the factoring problem. RSA stands for Ron Rivest, Adi Shamir and Leonard Adleman, who first publicly described the algorithm in 1977. Clifford Cocks, an English mathematician, had developed an equivalent system in 1973, but it was classified until 1997. A user of RSA creates and then publishes the product of two large prime numbers, along with an auxiliary value, as their public key. The prime factors must be kept secret. Anyone can use the public key to encrypt a message, but with currently published methods, if the public key is large enough, only someone with knowledge of the prime factors can feasibly decode the message. Whether breaking RSA encryption is as hard as factoring is an open question known as the RSA problem Algorithm : Step 1: Use a random process to select two large prime numbers P and Q. (each roughly the same size). Step 2: Compute the product M = P*Q. This number is called the modulus, and is made publicly available. Note: RSA currently recommends a modulus thats at least 768 bits long. Step 3: Also compute the Euler totient T = (P-1)*(Q-1). Keep this number (as well as P and Q) secret. Step 4: Randomly choose a public key E that has no factors in common with T = (P-1)*(Q-1). 1< E < T, such that gcd (T, E) = 1. Step 5: Compute a private key D so that E*D leaves a remainder of 1 when divided by T. Ie. (D*E) mod T = 1 Note: that D is easy to compute only if one knows the value of T. This is essentially the same as knowing the values of P and Q. Output :

G:\sem 6\INS>javac rsa.java G:\sem 6\INS>java rsa Enter a number 12 Public key (encryption) : 11 Encrypted text : 46 Private key(decryption) : 275 Decrypted text : 12
Conclusion : RSA algorithm can be used for encryption and decryption.

You might also like