Open Lihaiquan opened 7 years ago
SRWebSocket.m L.661
(void)openConnection; { [self _updateSecureStreamOptions];
if (!_scheduledRunloops.count) { [self scheduleInRunLoop:[NSRunLoop SR_networkRunLoop] forMode:NSDefaultRunLoopMode]; }
/ (Source code modified) - Piccolo 2018-05-03 begin /
[_inputStream setProperty:NSStreamSocketSecurityLevelNegotiatedSSL forKey:(NSString )NSStreamSocketSecurityLevelKey]; [_outputStream setProperty:NSStreamSocketSecurityLevelNegotiatedSSL forKey:(NSString )NSStreamSocketSecurityLevelKey]; NSMutableDictionary settings = [NSMutableDictionary new]; [settings setObject:[NSNumber numberWithBool:NO] forKey:(NSString )kCFStreamSSLValidatesCertificateChain]; [settings setObject:(id)kCFNull forKey:(NSString *)kCFStreamSSLPeerName];
CFReadStreamSetProperty((CFReadStreamRef)_inputStream, kCFStreamPropertySSLSettings, (CFTypeRef)settings); CFWriteStreamSetProperty((CFWriteStreamRef)_outputStream, kCFStreamPropertySSLSettings, (CFTypeRef)settings);
/ (Source code modified) - Piccolo 2018-05-03 end /
[_outputStream open]; [_inputStream open]; }
@popking5466 still not working
SRWebSocket.m L.661
(void)openConnection; { [self _updateSecureStreamOptions];
if (!_scheduledRunloops.count) { [self scheduleInRunLoop:[NSRunLoop SR_networkRunLoop] forMode:NSDefaultRunLoopMode]; }
/ (Source code modified) - Piccolo 2018-05-03 begin /
[_inputStream setProperty:NSStreamSocketSecurityLevelNegotiatedSSL forKey:(NSString )NSStreamSocketSecurityLevelKey]; [_outputStream setProperty:NSStreamSocketSecurityLevelNegotiatedSSL forKey:(NSString )NSStreamSocketSecurityLevelKey]; NSMutableDictionary settings = [NSMutableDictionary new]; [settings setObject:[NSNumber numberWithBool:NO] forKey:(NSString )kCFStreamSSLValidatesCertificateChain]; [settings setObject:(id)kCFNull forKey:(NSString *)kCFStreamSSLPeerName];
CFReadStreamSetProperty((CFReadStreamRef)_inputStream, kCFStreamPropertySSLSettings, (CFTypeRef)settings); CFWriteStreamSetProperty((CFWriteStreamRef)_outputStream, kCFStreamPropertySSLSettings, (CFTypeRef)settings);
/ (Source code modified) - Piccolo 2018-05-03 end /
[_outputStream open]; [_inputStream open]; }