mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Revert "attempt to fix expired key for mtproto"
This reverts commit d08dcacfdac8ed8097671d4e7ac3387e67bcb8f2.
This commit is contained in:
parent
75d6f07a57
commit
ec074f650d
@ -6,5 +6,4 @@
|
||||
|
||||
- (instancetype)initWithPersistentKey:(MTDatacenterAuthKey *)persistentKey ephemeralKey:(MTDatacenterAuthKey *)ephemeralKey completion:(void (^)(bool))completion;
|
||||
|
||||
-(void)complete;
|
||||
@end
|
||||
|
@ -168,8 +168,4 @@
|
||||
}
|
||||
}
|
||||
|
||||
-(void)complete {
|
||||
_completion(true);
|
||||
}
|
||||
|
||||
@end
|
||||
|
@ -250,7 +250,7 @@ static int32_t fixedTimeDifferenceValue = 0;
|
||||
_tempKeyExpiration = 24 * 60 * 60;
|
||||
|
||||
#if DEBUG
|
||||
_tempKeyExpiration = 30;
|
||||
//_tempKeyExpiration = 30;
|
||||
#endif
|
||||
|
||||
_datacenterSeedAddressSetById = [[NSMutableDictionary alloc] init];
|
||||
|
@ -55,7 +55,7 @@
|
||||
|
||||
#import <MtProtoKit/MTSignal.h>
|
||||
#import <MtProtoKit/MTQueue.h>
|
||||
#import <MtProtoKit/MTBindKeyMessageService.h>
|
||||
|
||||
typedef enum {
|
||||
MTProtoStateAwaitingDatacenterScheme = 1,
|
||||
MTProtoStateAwaitingDatacenterAuthorization = 2,
|
||||
@ -885,7 +885,7 @@ static const NSUInteger MTMaxUnacknowledgedMessageCount = 64;
|
||||
|
||||
- (MTDatacenterAuthKey *)getAuthKeyForCurrentScheme:(MTTransportScheme *)scheme createIfNeeded:(bool)createIfNeeded authInfoSelector:(MTDatacenterAuthInfoSelector *)authInfoSelector {
|
||||
if (_useExplicitAuthKey) {
|
||||
MTDatacenterAuthInfoSelector selector = scheme.media ? MTDatacenterAuthInfoSelectorEphemeralMedia : MTDatacenterAuthInfoSelectorEphemeralMain;
|
||||
MTDatacenterAuthInfoSelector selector = MTDatacenterAuthInfoSelectorEphemeralMain;
|
||||
if (authInfoSelector != nil) {
|
||||
*authInfoSelector = selector;
|
||||
}
|
||||
@ -2151,15 +2151,6 @@ static NSString *dumpHexString(NSData *data, int maxLength) {
|
||||
}
|
||||
|
||||
if (_useExplicitAuthKey != nil) {
|
||||
if (scheme.media) {
|
||||
for (NSInteger i = (NSInteger)_messageServices.count - 1; i >= 0; i--)
|
||||
{
|
||||
MTBindKeyMessageService* messageService = (MTBindKeyMessageService *)_messageServices[(NSUInteger)i];
|
||||
if ([messageService respondsToSelector:@selector(complete)]) {
|
||||
[messageService complete];
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (_cdn) {
|
||||
_validAuthInfo = nil;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user