From d96068ac819fc0f9940441cffe70018222673357 Mon Sep 17 00:00:00 2001 From: Daniil Gentili Date: Mon, 30 Jan 2017 12:48:58 +0100 Subject: [PATCH] Bugfix --- src/danog/MadelineProto/MTProtoTools/AuthKeyHandler.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/danog/MadelineProto/MTProtoTools/AuthKeyHandler.php b/src/danog/MadelineProto/MTProtoTools/AuthKeyHandler.php index 563c58ca..8d507b4d 100644 --- a/src/danog/MadelineProto/MTProtoTools/AuthKeyHandler.php +++ b/src/danog/MadelineProto/MTProtoTools/AuthKeyHandler.php @@ -62,6 +62,11 @@ trait AuthKeyHandler * *********************************************************************** * Find our key in the server_public_key_fingerprints vector */ + if (!isset($this->key->keydata)) { + // Load rsa key + \danog\MadelineProto\Logger::log(['Loading RSA key...'], Logger::ULTRA_VERBOSE); + $this->key = new RSA($this->settings['authorization']['rsa_key']); + } foreach ($ResPQ['server_public_key_fingerprints'] as $curfp) { if ($this->key->keydata['fp'] === $curfp) { $public_key_fingerprint = $curfp;