RSA Algorithm Team-4 (1)
RSA Algorithm Team-4 (1)
Project
(RSA Algorithm)
Academic Year : 2024-25
Submitted By :
Jatin Sharma BT22GCS066 B. Tech CSE
1. Abstract.......................................................................................................................... 4
2. Introduction ....................................................................................................................4
3. Literature Review ...........................................................................................................5
4. Algorithm Keywords ..................................................................................................... 7
5. Algorithm Overview.......................................................................................................9
5.1 RSA Pseudocode ....................................................................................................9
5.2 Mathematical Basis............................................................................................... 11
5.3 Core Components of RSA ................................................................................... 13
5.3.1 Key Generation (Public and Private Keys) .............................................. 15
5.3.2 Encryption Process ................................................................................ 17
5.3.3 Decryption Process ................................................................................ 17
5.4 Mathematical Core ................................................................................16
5.5 Core Structural Elements in RSA Security ............................................ 16
6. Conclusion ................................................................................................................ 17
7. References ................................................................................................................... 18
Contribution by Team members
BASIC RESEARCH -
Kanwar Jiten Singh BT22GCS111 INTRODUCTION
BASIC RESEARCH -
Kartik Mudgal BT22GCS240 ALGORITHM
List of Figures
Figure
Name Page Number
Number
6
Fig 1 RSA Structure
10
Fig 2 RSA Encryption and Decryption
Abstract
In today's digital age, where data security is paramount, RSA (Rivest-Shamir- Adleman)
stands as a cornerstone of modern cryptography. Our project explores this fascinating
public-key cryptosystem that revolutionized secure communications [1][2]. Unlike traditional
encryption methods that rely on shared secret keys, RSA's brilliance lies in its use of two different
keys - one public and one private. Through our research and implementation, we've
discovered how RSA's mathematical foundation, based on the challenging task of factoring
large prime numbers, provides robust security for everyday applications like secure emails,
digital signatures, and SSL/TLS certificates that protect our online banking and shopping.
This project breaks down RSA's components, explores its implementation challenges, and
demonstrates why it remains crucial in cybersecurity despite being developed over 45 years ago.
Introduction
When we first encountered RSA in our cryptography studies, what struck us most
was its elegant solution to the key distribution problem that plagued earlier
encryption systems. Developed in 1977 by Ron Rivest, Adi Shamir, and Leonard
Adleman at MIT, RSA doesn't just encrypt data - it revolutionized how we think
about encryption itself.
Think of RSA like a special padlock where anyone can lock something (using the
public key), but only the owner has the unique key (private key) to unlock it. This
simple yet powerful concept enables:
4
The beauty of RSA lies in its practical application of complex mathematical
concepts we've studied in number theory, making it a perfect example of how
theoretical mathematics finds real-world applications in computer science.
Back in 1978, three brilliant mathematicians – Rivest, Shamir, and Adleman – did
something pretty amazing. They created RSA, a groundbreaking way of keeping digital
communication secret that would change how we think about online security forever.
Imagine trying to send a super-secret message that only the right person could read -
that's essentially what they invented.
But computer science never stands still. With quantum computing on the horizon,
researchers started getting worried. They began developing clever strategies to protect
RSA from potential future quantum attacks. It's like preparing a fortress before the
enemy even arrives.
The really cool part about RSA is how researchers keep finding ways to make it work
better. They've developed techniques to generate encryption keys faster and more
efficiently. For smaller devices with limited processing power - think tiny sensors or
smart home gadgets - they've figured out how to make RSA work smoothly without
consuming too much memory.
5
Fig 1. RSA STRUCTURE
6
Algorithm Keywords
Public Key The publicly shared key (n, e) used for encryption. Like sharing your email
1.
(PU) address - everyone can use it to send you messages.
2. Private Key
(PR) The secret key (n, d) for decryption. Similar to your email password - kept
strictly private.
Prime
Large prime numbers (typically 1024 bits or larger) whose product forms
3. Numbers (p,
the modulus. Must be kept secret.
q)
Euler's
4. Calculated as (p-1)(q-1). Critical for key generation.
Totient φ(n)
Encryption
5. Usually a small number like 65537 (2¹⁶ + 1), must be coprime with φ(n).
Exponent (e)
6. Modulus (n) Product of chosen primes (n = p × q). Part of both public and private keys.
7. Decryption
Exponent (d)
Calculated as e⁻¹ mod φ(n). The heart of the private key.
7
8. Message
Blocks
9. Modular
Arithmetic
The mathematical operations that make RSA possible.
10. Coprime
Numbers
Numbers whose greatest common divisor (GCD) is 1.
8
5. Algorithm Overview
RSA works based on the principles of number theory, particularly the difficulty of
factoring large numbers into their prime components. Here’s a breakdown of how it
works:
9
10
5.2. Mathematical Basis
1. Number Theory Principles
11
2. Core Mathematical Operations
12
5.4 Key Expansion (Key Schedule)
MATHEMATICAL CORE
STRENGTHS
LIMITATIONS
● Computationally expensive
● Vulnerable to advanced quantum computing
13
● Requires careful implementation
PRACTICAL APPLICATIONS
1. MATHEMATICAL FOUNDATION
Fundamental Mathematical Pillars:
● Number Theory
● Modular Arithmetic
● Prime Number Theory
● Computational Complexity
● Criteria:
○ Large prime numbers (2048-4096 bits)
○ Cryptographically secure generation
○ Minimal predictability
○ Statistically random distribution
b) Modulus Construction
● n=p×q
● Characteristics:
○ Product of two distinct primes
○ Determines key space
○ Defines encryption/decryption domain
c) Totient Function
14
● Significance:
○ Counts coprime integers
○ Determines key relationship
○ Enables multiplicative inverse computation
1. Prime Selection
2. Modulus Calculation
3. Totient Computation
4. Public Exponent Selection
5. Private Exponent Derivation
4. CRYPTOGRAPHIC PARAMETERS
Key Structural Parameters:
● Prime Size
● Public Exponent (e)
● Private Exponent (d)
● Modulus (n)
2. SECURITY DIMENSIONS
a) Computational Security
● Factorization Resistance
● Discrete Logarithm Complexity
● Polynomial-Time Intractability
15
b) Algebraic Security
c) Cryptographic Principles
● One-Way Function
● Trapdoor Mechanism
● Asymmetric Encryption
1. Mathematical Attacks
○ Factorization Techniques
○ Mathematical Weakness Exploitation
○ Number Theoretical Approaches
2. Implementation Attacks
○ Side-Channel Analysis
○ Timing Attacks
○ Power Analysis
○ Fault Injection
3. Cryptanalytic Approaches
○ Chosen Ciphertext Attacks
○ Differential Cryptanalysis
○ Statistical Weakness Exploration
16
5.6. RSA Encryption and Decryption Process
6. Conclusion
Through our study and implementation of RSA, we've gained deep appreciation
for its elegant mathematical foundation and practical significance in modern
cryptography. While newer quantum-resistant algorithms are being developed,
RSA's fundamental principles continue to secure countless digital transactions
daily. Our project demonstrates that understanding RSA is crucial for any serious
computer science student, as it combines number theory, algorithm design, and
practical security considerations.
17
7. References
1. Rivest, R. L., Shamir, A., & Adleman, L. (1978). "A Method for Obtaining
Digital Signatures and Public-Key Cryptosystems." Communications of the
ACM, 21(2), 120-126.
2. Menezes, A. J., Van Oorschot, P. C., & Vanstone, S. A. (2018).
"Handbook of Applied Cryptography." CRC Press
3. NIST Special Publication 800-57 Part 1 Revision 5: "Recommendation for
Key Management."
4. Boneh, D. (1999). "Twenty Years of Attacks on the RSA Cryptosystem."
Notices of the American Mathematical Society, 46(2), 203-213.
5. Ferguson, N., & Schneier, B. (2003). "Practical Cryptography." Wiley Publishing
18