PhieuLang

crypto

Oct 9th, 2014
349
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.78 KB | None | 0 0
  1. import hashlib
  2. msg = 'yr6YCtcvW3QvzOAvWvc5XrupA1btFZb9jt=='
  3. try:
  4.     for i in xrange(0, len(res)):
  5.         token = hashlib.sha1(res[i+1]).digest()
  6.         n = ord(res[i])
  7.         n ^= 0xf2 ^ ord(token[0])
  8.         n ^= 0xd1 ^ ord(token[1])
  9.         n ^= 0x20 ^ ord(token[2])
  10.         n ^= 0x3c ^ ord(token[3])
  11.         n ^= 0xca ^ ord(token[4])
  12.         n ^= 0x54 ^ ord(token[5])
  13.         n ^= 0x11 ^ ord(token[6])
  14.         n ^= 0xf0 ^ ord(token[7])
  15.         n ^= 0xa3 ^ ord(token[6])
  16.         n ^= 0xfe ^ ord(token[5])
  17.         n ^= 0x21 ^ ord(token[4])
  18.         n ^= 0x4c ^ ord(token[3])
  19.         n ^= 0x27 ^ ord(token[2])
  20.         n ^= 0xf3 ^ ord(token[1])
  21.         n ^= 0xc2 ^ ord(token[0])
  22.         c = n ^ 0xfe ^ 0xc3 ^ 0x42 ^ 0x21
  23.         msg += chr(c)
  24. except:
  25.     print msg[::-1]
Advertisement
Add Comment
Please, Sign In to add comment