mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-08-09 05:19:41 +00:00
Fix RSA key unpacking on missing fingerprint (#1324)
This commit is contained in:
@@ -66,7 +66,7 @@ def encrypt(fingerprint, data, *, use_old=False):
|
|||||||
the cipher text, or None if no key matching this fingerprint is found.
|
the cipher text, or None if no key matching this fingerprint is found.
|
||||||
"""
|
"""
|
||||||
global _server_keys
|
global _server_keys
|
||||||
key, old = _server_keys.get(fingerprint, None)
|
key, old = _server_keys.get(fingerprint, [None, None])
|
||||||
if (not key) or (old and not use_old):
|
if (not key) or (old and not use_old):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user