简体   繁体   中英

How Good Dynamics secures NSURLConnection?

Once GD is enabled (by calling enableSecureCommunication or authenticating the application) NSURLConnection is automatically secured. How does it do that?

Sorry to be answering over one year after the question was asked.

iOS has a feature called the URL Loading System. This allows an application to register its own handlers for HTTP requests, for example. The Good Dynamics library instance in your application could register its own HTTP request handler, in order to secure communications.

For reference, see the GDURLLoadingSystem class reference in the API Reference of the Good Dynamics SDK for iOS on the http://developer.good.com site, and http://developer.apple.com/library/ios/#documentation/Cocoa/Conceptual/URLLoadingSystem/ for the iOS side.

My guess would be that Good Dynamics SDK does what is called method swizzling or class posing

Both methods allow to replace existing Objective C method or class with their own implementation. So, Good SDK does this for NSURLConnection class.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM