Skip to main content
adicionou 44 caracteres ao conteúdo
Fonte Link
Chun
  • 7,5mil
  • 4
  • 32
  • 57

Pessoal estou tentando descriptografar AES, só que eu estou me deparando com esseo seguinte erro

Traceback (most recent call last): File "./teste2.py", line 190, in main() File "./teste2.py", line 186, in main decrypt(password) File "./teste2.py", line 172, in decrypt dec = base64.b64decode(crypt.decrypt(password)) File "/usr/lib/python2.7/base64.py", line 76, in b64decode raise TypeError(msg) TypeError: Incorrect padding

Código:

Traceback (most recent call last):
File "./teste2.py", line 190, in main()
File "./teste2.py", line 186, in main decrypt(password)
File "./teste2.py", line 172, in decrypt dec = base64.b64decode(crypt.decrypt(password))
File "/usr/lib/python2.7/base64.py", line 76, in b64decode raise TypeError(msg)
TypeError: Incorrect padding

def decrypt(password): iv = ''.join(chr(random.randint(0, 0xFF)) for i in range(16)) crypt = AES.new(password, AES.MODE_CBC, iv) dec = base64.b64decode(crypt.decrypt(password)) print "[+] ResultEste é o meu código: %s" % dec

def decrypt(password):
    iv = ''.join(chr(random.randint(0, 0xFF)) for i in range(16))
    crypt = AES.new(password, AES.MODE_CBC, iv)
    dec = base64.b64decode(crypt.decrypt(password))
    print "[+] Result: %s" % dec

Pessoal estou tentando descriptografar AES só que eu estou me deparando com esse erro

Traceback (most recent call last): File "./teste2.py", line 190, in main() File "./teste2.py", line 186, in main decrypt(password) File "./teste2.py", line 172, in decrypt dec = base64.b64decode(crypt.decrypt(password)) File "/usr/lib/python2.7/base64.py", line 76, in b64decode raise TypeError(msg) TypeError: Incorrect padding

Código:

def decrypt(password): iv = ''.join(chr(random.randint(0, 0xFF)) for i in range(16)) crypt = AES.new(password, AES.MODE_CBC, iv) dec = base64.b64decode(crypt.decrypt(password)) print "[+] Result: %s" % dec

Pessoal estou tentando descriptografar AES, só que eu estou me deparando com o seguinte erro:

Traceback (most recent call last):
File "./teste2.py", line 190, in main()
File "./teste2.py", line 186, in main decrypt(password)
File "./teste2.py", line 172, in decrypt dec = base64.b64decode(crypt.decrypt(password))
File "/usr/lib/python2.7/base64.py", line 76, in b64decode raise TypeError(msg)
TypeError: Incorrect padding

Este é o meu código:

def decrypt(password):
    iv = ''.join(chr(random.randint(0, 0xFF)) for i in range(16))
    crypt = AES.new(password, AES.MODE_CBC, iv)
    dec = base64.b64decode(crypt.decrypt(password))
    print "[+] Result: %s" % dec
Fonte Link

TypeError: Incorrect padding

Pessoal estou tentando descriptografar AES só que eu estou me deparando com esse erro

Traceback (most recent call last): File "./teste2.py", line 190, in main() File "./teste2.py", line 186, in main decrypt(password) File "./teste2.py", line 172, in decrypt dec = base64.b64decode(crypt.decrypt(password)) File "/usr/lib/python2.7/base64.py", line 76, in b64decode raise TypeError(msg) TypeError: Incorrect padding

Código:

def decrypt(password): iv = ''.join(chr(random.randint(0, 0xFF)) for i in range(16)) crypt = AES.new(password, AES.MODE_CBC, iv) dec = base64.b64decode(crypt.decrypt(password)) print "[+] Result: %s" % dec