RSA Modulus & Euler Totient
n = p \cdot q, \quad \varphi(n) = (p - 1)(q - 1)
p, q: distinct secret primes; factoring n back into p and q is computationally hard.
Foundational public-key cryptography identities covering RSA modulus and Euler totient generation, Extended Euclidean modular inverses, Euler theorem proof of decryption, and fast modular exponentiation.
n = p \cdot q, \quad \varphi(n) = (p - 1)(q - 1)
p, q: distinct secret primes; factoring n back into p and q is computationally hard.
e \cdot d \equiv 1 \pmod{\varphi(n)}, \quad \gcd(e, \varphi(n)) = 1
Solved in O(log phi(n)) time via the Extended Euclidean Algorithm.
C \equiv M^e \pmod{n}, \quad M \equiv C^d \pmod{n}
Requires 0 <= M < n; production systems add OAEP padding before exponentiation.
T(M^e \bmod n) = O(\log_2 e) \text{ modular multiplications}
Evaluates huge cryptographic exponents in milliseconds without computing M^e directly.
A modular multiplicative inverse d satisfying e*d = 1 mod phi(n) exists if and only if gcd(e, phi(n)) = 1.
65537 = 2^16 + 1 is prime and has only two 1-bits in binary, making public encryption and signature verification extremely fast (only 16 squarings and 1 multiply) while avoiding small-exponent attacks.
Textbook RSA is deterministic and multiplicatively homomorphic, making it vulnerable to chosen-ciphertext attacks; real protocols wrap messages with randomized OAEP or PSS padding.