我试图禁用一些密码(弱),如单DES,单DES 40位等.
我尝试使用这段代码如何在Cocoa中使用CFSocket/CFStream时设置SSL密码?从邮件列表消息CFNetwork SSL和长阻塞延迟但我需要访问套接字数据来获取CFDataRef.
这是我试图在AFURLConnectionOperation类中的握手方法中插入的代码:
- (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge (NSURLAuthenticationChallenge *)challenge{
CFReadStreamRef stream = [sock getCFReadStream];
CFDataRef data = CFReadStreamCopyProperty(stream, kCFStreamPropertySocketSSLContext);
// Extract the SSLContextRef from the CFData
SSLContextRef sslContext;
CFDataGetBytes(data, CFRangeMake(0, sizeof(SSLContextRef)), &sslContext);
// Get all enabled ciphers
size_t numCiphers;
SSLGetNumberEnabledCiphers(sslContext,&numCiphers);
SSLCipherSuite ciphers[numCiphers];
SSLGetEnabledCiphers(sslContext,ciphers,&numCiphers);
// Create a new cipher array with only non-DH ciphers, and set it
SSLCipherSuite finalCiphers[numCiphers];
int numFinalCiphers = 0;
for(int i=0; i<numCiphers; i++) {
SSLCipherSuite suite = …Run Code Online (Sandbox Code Playgroud) 我有工作swift在Xcode 7.我是全新的Swift, Xcode, and Firebase.我想UITableViewController在我的iOS应用程序中有三个s.前两个TableView controllers需要动态内容,第三个TableView控制器需要静态内容.我希望第二个和第三个TableView控制器根据在前一个TableView控制器上按下的内容显示数据.所有数据都来自我的Firebase.我不知道从哪里开始.请指出我正确的方向!谢谢!