@anonymous/BrilliantUnrealisticDobermanpinscher
Python

No description

Files
  • main.py
main.py
import random
import base64
from Crypto.Cipher import AES


BLOCK_SIZE = 16
PADDING = '{'

pad = lambda s: s + (BLOCK_SIZE - len(s) % BLOCK_SIZE) * PADDING


def decode():
  e = raw_input('Введите код раунда')
  c = raw_input('Введите код проверки раунда')
  key = AES.new(pad(c))
  return key.decrypt(base64.urlsafe_b64decode(e)).decode().rstrip(PADDING)


print(decode())
Python 2.7.10 (default, Jul 14 2015, 19:46:27) [GCC 4.8.2] on linux