/***** * demo of the RSA algorithm. * * I'm *not* try to be secure or realistic here, * but just to show the general method. * ****/ // hit long overflow in encode with p-617, q=503 #include #include long P = 131; // these are both prime. See bigint/low_primes.h long Q = 89; long N; long B; long E; long D; // ---------------------------- void init() { long i; N = P*Q; B = (P-1)*(Q-1); // find E for (i=3; i