Advertisement
Lonely_Wanderer

Forencis200

Nov 14th, 2019
523
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.48 KB | None | 0 0
  1. import math
  2. epas ="IZHsD7DZSZ5mT5zVH35dPpDo"
  3. d = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz+/="
  4. magic = ["IZHs","D7DZ","SZ5m","T5zV","H35d","PpDo"]
  5. list1 = []
  6.  
  7. def encode(input):
  8.     di = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz+/="
  9.     list = []
  10.     i = 0
  11.     b=0
  12.     c=0
  13.     while i < len(input):
  14.         a = ord(input[i])
  15.         i= i + 1
  16.         if len(input) > 1:        
  17.             b = ord(input[i])
  18.             i= i + 1
  19.         if len(input) > 2:        
  20.             c = ord(input[i])
  21.             i= i + 1
  22.         d = (a << 16) + ((b | 0) << 8) + (c | 0)
  23.         c1 = (d & (63 << 18)) >> 18
  24.         c2 = (d & (63 << 12)) >> 12
  25.         c3 = 64 if math.isnan(b) else (d & (63 << 6)) >> 6
  26.         c4 = 64 if math.isnan(c) else (d & 63)
  27.         list.append(di[c1])
  28.         list.append(di[c2])
  29.         list.append(di[c3])
  30.         list.append(di[c4])
  31.     return ''.join(str(e) for e in list)
  32.        
  33.  
  34. def check(s1):
  35.     s= encode(s1)
  36.     if s == magic[0] or s == magic[1] or s == magic[2] or s == magic[3] or s == magic[4] or s == magic[5]:
  37.         if list1.count(s1+":"+s) == 0:
  38.             list1.append(s1 + ':' + s)
  39.  
  40. def magic2():
  41.     for c1 in d:
  42.         for c2 in d:
  43.             for c3 in d:    
  44.                 s1 = c1 + c2 + c3
  45.                 s2 = c3 + c1 + c2
  46.                 s3 = c2 + c3 + c1
  47.                 check(s1)
  48.                 check(s2)
  49.                 check(s3)
  50.     print(list1)
  51.  
  52.  
  53. magic2()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement