1.5.0
- Implemented major changes to support the usage of multiple instances of TrustKit, instead of being forced to use a singleton.
- This is useful for larger Apps that have split some of their functionality into multiple frameworks/SDKs. Each framework can initialize its own instance of TrustKit and use it for pinning validation independently of the App's other components. See the
-initWithConfig:
method for more information. - The singleton approach should still be used by most Apps as it is simpler. A few minor code changes are required for Apps migrating from previous versions, detailed at the end of this page.
- This is useful for larger Apps that have split some of their functionality into multiple frameworks/SDKs. Each framework can initialize its own instance of TrustKit and use it for pinning validation independently of the App's other components. See the
- Pinning validation notifications have been removed and replaced by a callback that can be set in order to receive information about any pinning validation performed by TrustKit. See the
pinningValidatorCallback
property of theTrustKit
class for more information. - The default value for the
kTSKSwizzleNetworkDelegates
setting has been changed toNO
. - Support for iOS 7 and macOS 10.9 has been dropped.
Migrating from 1.4.2
For initializing TrustKit, switch from:
[TrustKit initializeWithConfiguration:trustKitConfig];
to:
[TrustKit initSharedInstanceWithConfiguration:trustKitConfig];
For any code using the TSKPinningValidator
class, switch from:
[TSKPinningValidator handleChallenge:challenge completionHandler:completionHandler];
to:
[TrustKit.sharedInstance.pinningValidator handleChallenge:challenge completionHandler:completionHandler];