How Secure Is RSA Algorithm?

This section discusses the security of RSA public key encryption algorithm. RSA private key is not 100% secure. But if the private key uses larger value of n = p*q, it will take a very long time to crack the private key.

The security of RSA public key encryption algorithm is mainly based on the integer factorization problem, which can be described as:

Given integer n as the product of 2 distinct prime numbers p and q, 
find p and q.

If the above problem could be solved, the RSA encryption is not secure at all. This is because the public key {n,e} is known to the public. Any one can use the public key {n,e} to figure out the private key {n,d} using these steps:

If n is small, the integer factorization problem is easy to solve by testing all possible prime numbers in the range of (1, n).

For example, given 35 as n, we can list all prime numbers in the range of (1, 35): 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, and 31, and try all combinations of them to find 5 and 7 are factors of 35.

As the value of n gets larger, the integer factorization problem gets harder to solve. But it is still solvable with the use of computers. For example, the RSA-100 number with 100 decimal digits, or 330 bits, has been factored by Arjen K. Lenstra in 1991:

RSA-100 = 15226050279225333605356183781326374297180681149613
    p*q = 37975227936943673922808872755445627854565536638199
        * 40094690950920881030683735292761468389214899724061

If you are using the above RSA-100 number as n, your private key is not private any more.

As of today, the highest value of n that has been factored is RSA-678 number with 232 decimal digits, or 768 bits, factored by Thorsten Kleinjung et al. in 2009:

RSA-768 = 12301866845301177551304949583849627207728535695953

    p*q = 33478071698956898786044169848212690817704794983713
        × 36746043666799590428244633799627952632279158164343

As our computers are getting more powerful, factoring n of 1024 bits will soon become reality. This is why experts are recommending us:

Last update: 2013.

Table of Contents

 About This Book

 Cryptography Terminology

 Cryptography Basic Concepts

 Introduction to AES (Advanced Encryption Standard)

 Introduction to DES Algorithm

 DES Algorithm - Illustrated with Java Programs

 DES Algorithm Java Implementation

 DES Algorithm - Java Implementation in JDK JCE

 DES Encryption Operation Modes

 DES in Stream Cipher Modes

 PHP Implementation of DES - mcrypt

 Blowfish - 8-Byte Block Cipher

 Secret Key Generation and Management

 Cipher - Secret Key Encryption and Decryption

Introduction of RSA Algorithm

 What Is Public Key Encryption?

 RSA Public Key Encryption Algorithm

 Illustration of RSA Algorithm: p,q=5,7

 Illustration of RSA Algorithm: p,q=7,19

 Proof of RSA Public Key Encryption

How Secure Is RSA Algorithm?

 How to Calculate "M**e mod n"

 Efficient RSA Encryption and Decryption Operations

 Proof of RSA Encryption Operation Algorithm

 Finding Large Prime Numbers

 RSA Implementation using java.math.BigInteger Class

 Introduction of DSA (Digital Signature Algorithm)

 Java Default Implementation of DSA

 Private key and Public Key Pair Generation

 PKCS#8/X.509 Private/Public Encoding Standards

 Cipher - Public Key Encryption and Decryption

 MD5 Mesasge Digest Algorithm

 SHA1 Mesasge Digest Algorithm

 OpenSSL Introduction and Installation

 OpenSSL Generating and Managing RSA Keys

 OpenSSL Managing Certificates

 OpenSSL Generating and Signing CSR

 OpenSSL Validating Certificate Path

 "keytool" and "keystore" from JDK

 "OpenSSL" Signing CSR Generated by "keytool"

 Migrating Keys from "keystore" to "OpenSSL" Key Files

 Certificate X.509 Standard and DER/PEM Formats

 Migrating Keys from "OpenSSL" Key Files to "keystore"

 Using Certificates in IE (Internet Explorer)

 Using Certificates in Firefox

 Using Certificates in Google Chrome

 Outdated Tutorials


 PDF Printing Version