Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from numbthy import *
- file = 'flag.enc'
- f = open(file, 'r').read()
- c = int(f.encode('hex'), 16)
- n =
- p =
- q =
- fi = (p-1)*(q-1)
- d = invmod(e,fi)
- m = powmod(c,d,n)
- print hex(m)[2:-1].decode('hex')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement