I'm starting integration with the iOS SDK. I'm doing a very very basic config. My config has everything disabled, and I only populate the ApplicationId and AccessToken

- (BOOL)application:(UIApplication *)application 
didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {

  // configure the Marketing Cloud SDK
  NSError *error = nil;
  BOOL success = [[MarketingCloudSDK sharedInstance] sfmc_configure:&error];
  if (success == YES) {
      [[MarketingCloudSDK sharedInstance] sfmc_setDebugLoggingEnabled:YES];

However I get the following output even with just this:

[foundation] SecItemDelete Exception. Error = -34018
 MarketingCloudSDKFoundation+DataUtils.m line: 262
[foundation] setup failed because encryption key could not be created or fetched with configuration {
    accesstoken = ...;
    appid = "...";
    etanalytics = 0;
    inbox = 0;
    location = 0;
    pianalytics = 0;
error Error Domain=MarketingCloudSDKErrorDomain Code=9 "SecItemDelete Exception. Error = -34018" UserInfo={NSLocalizedDescription=SecItemDelete Exception. Error = -34018}
MarketingCloudSDKFoundation.m line: 229

Anyone know what might cause this? Why this might be? I've tried it also with the MID and server url populated, still the same output...


So this is to do with signing as mentioned by Jeff Sylvia's comment. This is because I was running it in the simulator, when you run it in a real iPhone you do not get this error.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.