mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 22:46:10 +00:00
Closed beta 1000017001: enable auth_key_destroy.
Now we use only new authorization keys for signing in. If we are preparing to sign in and we see, that some of the authorization keys were not generated in this launch, but were read from file, we destroy all existing auth keys and generate a completely new set.
This commit is contained in:
@@ -22,9 +22,9 @@ Copyright (c) 2014-2017 John Preston, https://desktop.telegram.org
|
||||
|
||||
#include "core/utils.h"
|
||||
|
||||
#define BETA_VERSION_MACRO (0ULL)
|
||||
#define BETA_VERSION_MACRO (1000017001ULL)
|
||||
|
||||
constexpr int AppVersion = 1000017;
|
||||
constexpr str_const AppVersionStr = "1.0.17";
|
||||
constexpr bool AppAlphaVersion = true;
|
||||
constexpr bool AppAlphaVersion = false;
|
||||
constexpr uint64 AppBetaVersion = BETA_VERSION_MACRO;
|
||||
|
@@ -318,7 +318,7 @@ void Messenger::destroyStaleAuthorizationKeys() {
|
||||
auto keys = _mtproto->getKeysForWrite();
|
||||
for (auto &key : keys) {
|
||||
// Disable this for now.
|
||||
if (false && key->type() == MTP::AuthKey::Type::ReadFromFile) {
|
||||
if (key->type() == MTP::AuthKey::Type::ReadFromFile) {
|
||||
_private->mtpKeysToDestroy = _mtproto->getKeysForWrite();
|
||||
_mtproto.reset();
|
||||
LOG(("MTP Info: destroying stale keys, count: %1").arg(_private->mtpKeysToDestroy.size()));
|
||||
|
Reference in New Issue
Block a user