mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2026-10-12 16:11:59 -05:00
Fix password encryption with non-alpha passwords. Fixes #1371
This commit is contained in:
1 parent
5f3511ce39
commit
c702ef9c48
1 file changed
+1
-2
@@ -48,9 +48,8 @@ def decrypt(ciphertext, key):
|
||||
iv = ciphertext[:AES.block_size]
|
||||
cipher = AES.new(pad(key), AES.MODE_CFB, iv)
|
||||
decrypted = cipher.decrypt(ciphertext[AES.block_size:])
|
||||
l = decrypted.count(padding_string)
|
||||
|
||||
return decrypted[:len(decrypted)-l]
|
||||
return decrypted
|
||||
|
||||
|
||||
def pad(str):
|
||||
|
||||
Reference in new issue
Block a user