diff options
Diffstat (limited to 'rsa/prime.py')
-rw-r--r-- | rsa/prime.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rsa/prime.py b/rsa/prime.py index 29fa498..ab3eb97 100644 --- a/rsa/prime.py +++ b/rsa/prime.py @@ -96,7 +96,7 @@ def miller_rabin_primality_testing(n, k): # Test k witnesses. for _ in range(k): # Generate random integer a, where 2 <= a <= (n - 2) - a = rsa.randnum.randint(n - 4) + 2 + a = rsa.randnum.randint(n - 3) + 1 x = pow(a, d, n) if x == 1 or x == n - 1: |