RSA Public-Key Cryptography Lab
RSA asymmetric cryptography relies on the hardness of factoring n = pq while using Euler totient phi(n) = (p-1)(q-1) and the Extended Euclidean algorithm to pair public key (e, n) with private key (d, n).
Technical Reference & Equations
- RSA Modulus & Euler Totient:
n = p \cdot q, \quad \varphi(n) = (p - 1)(q - 1)(p, q: distinct prime numbers; n is public while p, q, and phi(n) remain secret.) - Private Exponent Congruence:
e \cdot d \equiv 1 \pmod{\varphi(n)}(Computed via Extended Euclidean Algorithm whenever gcd(e, phi(n)) = 1.) - Modular Encryption & Decryption:
C = M^e \bmod n, \quad M = C^d \bmod n(Evaluated in O(log e) steps via binary square-and-multiply modular exponentiation.)
View full Cryptography & Security Formula Sheet | Constants Table
Related Crypto & Security Calculators
- Modular Arithmetic & Euclidean GCD: Modular exponentiation, multiplicative inverses, and step-by-step Euclidean algorithm traces.
- Hash Table & Collision Resolution Simulator: Compare Linear Probing, Quadratic Probing, Double Hashing, and Separate Chaining with live load factor, probe sequences, and clustering metrics.
- Base & Two’s Complement Converter: Convert between Binary, Octal, Decimal, Hex, and signed 8/16-bit Two’s Complement with interactive bit toggles.
- Bitwise ALU Simulator: Evaluate AND, OR, XOR, NOT, arithmetic/logical shifts, and flag bits across aligned bit registers.
- ASCII / Hex / Base64 Encoder: Encode and decode between UTF-8/ASCII text, hexadecimal, binary, and Base64 with byte-by-byte inspection.
- IEEE-754 Single-Precision Float: Toggle sign, 8-bit exponent, and 23-bit mantissa bits interactively and inspect hex encoding.