Esempio n. 1
0
        private BigInteger CalculateE(BigInteger phi)
        {
            var e = BigInteger.ProbablePrime(BitLength / 2, _rnd);

            while (phi.Gcd(e).CompareTo(BigInteger.One) > 0 && e.CompareTo(phi) < 0)
            {
                e.Add(BigInteger.One);
            }

            return(e);
        }