Created
May 26, 2015 13:02
-
-
Save raimon49/8e1945359a16b49aef50 to your computer and use it in GitHub Desktop.
Ignoring certificate errors with NSURLConnection
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@implementation NSURLRequest(OOA) | |
+ (BOOL)allowsAnyHTTPSCertificateForHost:(NSString *)host { | |
return YES; | |
} | |
@end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension NSURLRequest { | |
statuc func allowsAnyHTTPSCertificateForHost(host: String) -> Bool { | |
return true | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
change statuc to static in the swift version