EXC_CRASH (SIGKILL (Code Signature Invalid))

I'm trying to sign a Mac app created with Unreal Engine. The signing process is manual using codesign. For some reason I'm having a crash on the app when adding certain entitlements that are necessary to the entitlements.plist file before signing. The crash looks like this:

Exception Type: EXC_CRASH (SIGKILL (Code Signature Invalid)) Exception Codes: 0x0000000000000000, 0x0000000000000000 Termination Reason: CODESIGNING 1 Taskgated Invalid Signature

Here's the crash full report:


Full Report

{"app_name":"Decoherence-Mac-Shipping","timestamp":"2023-10-11 08:49:18.00 -0500","app_version":"0.0.483","slice_uuid":"ad91922a-cea7-31bf-ba11-4984e24e77cc","build_version":"0.0.483","platform":0,"bundleID":"com.efectostudios.DecoherenceMac","share_with_app_devs":0,"is_first_party":0,"bug_type":"309","os_version":"macOS 13.2.1 (22D68)","roots_installed":0,"name":"Decoherence-Mac-Shipping","incident_id":"61D76BED-A68D-4535-AF3A-78BF60347328"} { "uptime" : 5500, "procRole" : "Default", "version" : 2, "userID" : 501, "deployVersion" : 210, "modelCode" : "iMac19,1", "coalitionID" : 2112, "osVersion" : { "train" : "macOS 13.2.1", "build" : "22D68", "releaseType" : "User" }, "captureTime" : "2023-10-11 08:49:17.3326 -0500", "incident" : "61D76BED-A68D-4535-AF3A-78BF60347328", "pid" : 15082, "cpuType" : "X86-64", "roots_installed" : 0, "bug_type" : "309", "procLaunch" : "2023-10-11 08:49:16.7724 -0500", "procStartAbsTime" : 5576178496866, "procExitAbsTime" : 5576738153681, "procName" : "Decoherence-Mac-Shipping", "procPath" : "/Users/Shared/*/DecoherenceTemp copy.app/Contents/MacOS/Decoherence-Mac-Shipping", "bundleInfo" : {"CFBundleShortVersionString":"0.0.483","CFBundleVersion":"0.0.483","CFBundleIdentifier":"com.efectostudios.DecoherenceMac"}, "storeInfo" : {"deviceIdentifierForVendor":"E8644E4C-3DF3-5239-897E-0A6D4BAFD5BD","thirdParty":true}, "parentProc" : "launchd", "parentPid" : 1, "coalitionName" : "com.efectostudios.DecoherenceMac", "crashReporterKey" : "7D9F74A0-44A0-D390-8EC8-6721FAB5FDF6", "throttleTimeout" : 2147483647, "wakeTime" : 1328, "sleepWakeUUID" : "014C6A54-479A-450B-94E2-5F9C7E6630D5", "sip" : "disabled", "exception" : {"codes":"0x0000000000000000, 0x0000000000000000","rawCodes":[0,0],"type":"EXC_CRASH","signal":"SIGKILL (Code Signature Invalid)"}, "termination" : {"flags":66,"code":1,"namespace":"CODESIGNING","indicator":"Taskgated Invalid Signature"}, "extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":0,"thread_set_state":0,"task_for_pid":2262},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"warnings":0}, "faultingThread" : 0, "threads" : [{"triggered":true,"id":78216,"threadState":{"r13":{"value":0},"rax":{"value":0},"rflags":{"value":512},"cpu":{"value":0},"r14":{"value":0},"rsi":{"value":0},"r8":{"value":0},"cr2":{"value":0},"rdx":{"value":0},"r10":{"value":0},"r9":{"value":0},"r15":{"value":0},"rbx":{"value":0},"trap":{"value":0},"err":{"value":0},"r11":{"value":0},"rip":{"value":4597456624,"matchesCrashFrame":1},"rbp":{"value":0},"rsp":{"value":140702040136552},"r12":{"value":0},"rcx":{"value":0},"flavor":"x86_THREAD_STATE","rdi":{"value":0}},"frames":[{"imageOffset":20208,"symbol":"_dyld_start","symbolLocation":0,"imageIndex":0},{"imageOffset":0,"imageIndex":1}]}], "usedImages" : [ { "size" : 622592, "arch" : "x86_64", "source" : "P", "base" : 4597436416, "uuid" : "bba77709-6cad-3592-ab03-09d0f7b8610e" }, { "size" : 85278720, "arch" : "x86_64", "source" : "P", "base" : 4308656128, "uuid" : "ad91922a-cea7-31bf-ba11-4984e24e77cc" } ], "vmSummary" : "ReadOnly portion of Libraries: Total=202.9M resident=0K(0%) swapped_out_or_unallocated=202.9M(100%)\nWritable regions: Total=11.4M written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=11.4M(100%)\n\n VIRTUAL REGION \nREGION TYPE SIZE COUNT (non-coalesced) \n=========== ======= ======= \nSTACK GUARD 56.0M 1 \nStack 8192K 1 \nVM_ALLOCATE 4K 1 \n__DATA 13.0M 3 \n__DATA_CONST 32K 1 \n__DATA_DIRTY 16K 1 \n__LINKEDIT 121.0M 3 \n__TEXT 81.9M 2 \nshared memory 4K 1 \n=========== ======= ======= \nTOTAL 279.9M 14 \n", "legacyInfo" : { "threadTriggered" : {

} }, "trialInfo" : { "rollouts" : [ { "rolloutId" : "5ffde50ce2aacd000d47a95f", "factorPackIds" : {

  },
  "deploymentId" : 240000334
},
{
  "rolloutId" : "5fb4245a1bbfe8005e33a1e1",
  "factorPackIds" : {

  },
  "deploymentId" : 240000021
}

], "experiments" : [ { "treatmentId" : "6dd670af-0633-45e4-ae5f-122ae4df02be", "experimentId" : "64406ba83deb637ac8a04419", "deploymentId" : 900000017 } ] }, "reportNotes" : [ "dyld_process_snapshot_get_shared_cache failed" ] }

Replies

For some reason I'm having a crash on the app when adding certain entitlements that are necessary to the entitlements.plist file before signing.

Are any of these restriction entitlements? If so, you’ll need to make sure that they’re authorised by a provisioning profile. See:

TN3135 also defines the term restricted entitlement.

ps When posting preformatted text, it’s a lot easier to read if you use a code block. See tip 5 in Quinn’s Top Ten DevForums Tips. Also, I have specific advice with regards crash reports: Posting a Crash Report.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"