Launch iOS app to launch

I am making an application that uses GCM, a background task and a keychain to save user information. I released the version using my development certification by adding the UDID of our device to the Apple developer account. But after a few days, I received feedback from users that a crash occurs every time they start. I am looking through the code but cannot find this error. I got these logs:

Nov 23 16:34:51 iPhone securityd[9174] <Error>: secTaskDiagnoseEntitlements MISSING keychain entitlements: no stored taskRef found Nov 23 16:34:51 iPhone securityd[9174] <Error>: secTaskDiagnoseEntitlements MISSING keychain entitlements: no stored taskRef found Nov 23 16:34:51 iPhone amfid[10315] <Error>: SecTrustEvaluate [leaf IssuerCommonName SubjectCommonName] Nov 23 16:34:51 iPhone securityd[9174] <Error>: secTaskDiagnoseEntitlements MISSING keychain entitlements: no stored taskRef found Nov 23 16:34:51 iPhone securityd[9174] <Error>: secTaskDiagnoseEntitlements MISSING keychain entitlements: no stored taskRef found Nov 23 16:34:51 iPhone amfid[10315] <Error>: SecTrustEvaluate [leaf Revocation1] Nov 23 16:34:51 iPhone amfid[10315] <Notice>: developer cert trust result = 5 Nov 23 16:34:51 iPhone amfid[10315] <Error>: /private/var/mobile/Containers/Bundle/Application/446DE89C-A427-4A51-AEA9-7AC86DFD088A/App.app/App not valid: 0xe8008018: The identity used to sign the executable is no longer valid. Nov 23 16:34:51 iPhone com.apple.xpc.launchd[1] (UIKitApplication:com.xxxxx.App[0xb005][10966]) <Notice>: Service exited due to signal: Killed: 9 Nov 23 16:34:51 iPhone assertiond[9148] <Warning>: Unable to obtain a task name port right for pid 10966: (os/kern) failure (5) Nov 23 16:34:51 iPhone SpringBoard[9139] <Warning>: Unable to register for exec notifications: No such process Nov 23 16:34:51 iPhone SpringBoard[9139] <Warning>: Unable to obtain a task name port right for pid 10966: (os/kern) failure (5) Nov 23 16:34:51 iPhone SpringBoard[9139] <Warning>: Unable to obtain a task name port right for <FBApplicationProcess: 0x1425836d0; com.xxxx.App; pid: 10966> Nov 23 16:34:51 iPhone SpringBoard[9139] <Warning>: Application 'UIKitApplication:com.xxxxx.App[0xb005]' exited abnormally via signal. Nov 23 16:34:51 iPhone SpringBoard[9139] <Error>: CGContextSaveGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable. Nov 23 16:34:51 iPhone SpringBoard[9139] <Error>: CGContextTranslateCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable. Nov 23 16:34:51 iPhone SpringBoard[9139] <Error>: CGContextRestoreGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable. Nov 23 16:34:51 iPhone SpringBoard[9139] <Error>: CGContextSaveGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable. Nov 23 16:34:51 iPhone SpringBoard[9139] <Error>: CGContextTranslateCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable. Nov 23 16:34:51 iPhone SpringBoard[9139] <Error>: CGContextRestoreGState: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable. Nov 23 16:34:51 iPhone SpringBoard[9139] <Warning>: Application '(null)' exited for an unknown reason. 

Please help me with this. Thank you all. I often revoke and create new certificates and profiling and use them for programming. This is normal?

+6
source share
2 answers

I know you have a workaround, but I prefer to explain why this happens.

You need the right file for your project and enable APNS with development or distribution. Apple doc

 <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>aps-environment</key> <string>development</string> </dic> 

Your file may be similar to this, but it indicates distribution, so using development will cause it to fail.

Hope this helps

0
source

Although the stack is not very clear, it narrows your crash to a few things.

  • Your certificates do not look valid. Go to Keychain Access and check if you have a valid certificate and Keypair is attached to it.

  • Your Provisioning profile has become invalid. Go to developer.apple.com and verify that your security profile that you used is valid.

  • Permissions to use Facebook are revoked for any reason. Please check your Facebook app and make sure everything is in order.

0
source

All Articles