deedy5 / rsa

RSA keys generation in Python

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Python >= 3.6

RSA

RSA key generations in Python

Time of rsa keys generation: 2048 bits ≈ 0.7 s. 3072 bits ≈ 2,1 s.

Made in accordance with: FIPS 186-4

The RSA Digital Signature Algorithm:

  1. Public and Private keys generation. FIPS 186-4: 5.1, APPENDIXes B.3, F.1, F.3.
    • Length of the modulus: 2048 and 3072 bits.
    • Primes generation: Miller-Rabin algorithm. FIPS 186-4 APPENDIXes B.3.3, C.3.1.
    • Number of rounds (witnesses) of Miller-Rabin testing k = 40 (error probability 2**-80). FIPS 186-4, F.1.

Usage:

Generate RSA keys, default bits = 3072:

python3 rsa.py

About

RSA keys generation in Python


Languages

Language:Python 100.0%