When I run this code below, I get OverflowError, How can I fix this? keep this big prime
import random
import time
@interact
def _(a1=0,a2=0,a3=0,a4=0,a5=7,p1=('p',input_box(default=1461501637330902918203684832716283019655932584637)),auto_update=False):
p=p1
if (is_prime(p)==True):
print 'Elliptic Curve yang digunakan y^2 + a1*xy + a3*y = x^3 + a2*x^2 + a4*x + a5'
F = GF(p)
E = EllipticCurve(F,[a1,a2,a3,a4,a5])
G = E.gen(0)
random = randint(0,p)
P = random*G
if (is_prime(P.order())==True):
random1 = randint(0,7000)
Q = random1*P
print 'P = ',P
print 'Q = ',Q
print 's = ', random1
print '#Break ECC dengan Algoritma Pollard Rho (Q = k*P), k=?'
print 'Start searching....'
start = time.time()
k = discrete_log_rho(Q, P, ord = P.order(), operation='+')
print 'Key found!!!'
print 'Key = s = ',k
end = time.time()
print 'Waktu komputasi = ',end-start,'detik'
else:
print 'Gagal. Orde P tidak prime!!'
else:
print 'p harus bilangan prima!'