Advertisement
Guest User

Untitled

a guest
Dec 12th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. import base64
  2. import os
  3. import socket
  4.  
  5. #get the thing
  6. s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
  7. s.connect(("services.cyberprotection.agency",13222))
  8. s.recv(1024)
  9. r = s.recv(1024)
  10. r = r.split("\n")[4:-2]
  11.  
  12. print(r)
  13. secret = bytearray.fromhex(r[0].split('=')[1].strip()).decode()
  14. print("secret is ",secret)
  15. iv = bytearray.fromhex(r[1].split('=')[1].strip()).decode()
  16. #iv = r[1].split('=')[1].strip()
  17. encrypted = r[2].strip()
  18.  
  19. BLOCK_SIZE = 32
  20.  
  21. PADDING = '{'
  22.  
  23. def rot(a,b):
  24. alphabet = 'abcdefghijklmaopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ123456789'
  25. #alphabset = "abcdefghijklmaopqrstuvwxyzabcdefghijklmaopqrstuvwxyz"
  26. string = ""
  27. for letter in range(len(a)):
  28. string+=alphabet[alphabet.find(a[letter])+b]
  29. return string
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement