EncryptionConfigLoader
public class EncryptionConfigLoader
class to load the encryption configuration for a given appId and deviceId
-
key to store the encryption key in secure storage
Declaration
Swift
public static let encryptionKeyID: String -
Default initializer for EncryptionConfigLoader
Declaration
Swift
public init(sapURLSession: SAPURLSession, settingsParameters: SAPcpmsSettingsParameters)Parameters
sapURLSessionan SAPURLSession implementation that can be used to communicate with the SAP Mobile Services
settingsParametersSAPcpms settings metadata to be able to concatenate the SAPcpms URL
-
Loads settings from the server. Send a REST request to SAP Mobile Services fetchEncryptionKey endpoint. Retrieves JSON payload. Converts the response to String and return it to the completion handler.
Declaration
Swift
public func load(completionHandler: @escaping (String?, Error?) -> Void)Parameters
completionHandlercalled on a background queue with the result received from the server. The parameters are the retrieved encryptionKey and Error. One of them could be nil.