Xcode 12.5 "code signature version is no longer supported"

After upgrading to Xcode 12.5 and iOS 14.5, I can no longer debug my app on my local physical device.

I get the below error.

I searched and cannot find any answers.

How do I fixed this?

Details

Unable to install "MyApp"
Domain: com.apple.dt.MobileDeviceErrorDomain
Code: -402620375
  • -

The code signature version is no longer supported.
Domain: com.apple.dt.MobileDeviceErrorDomain
Code: -402620375
User Info: {
  DVTRadarComponentKey = 261622;
  MobileDeviceErrorCode = "(0xE8008029)";
  "com.apple.dtdevicekit.stacktrace" = (
0  DTDeviceKitBase           0x000000011edd83b8 DTDKCreateNSErrorFromAMDErrorCode + 220
1  DTDeviceKitBase           0x000000011ee16ae1 __90-[DTDKMobileDeviceToken installApplicationBundleAtPath:withOptions:andError:withCallback:]_block_invoke + 155
2  DVTFoundation            0x0000000107881b7c DVTInvokeWithStrongOwnership + 71
3  DTDeviceKitBase           0x000000011ee16822 -[DTDKMobileDeviceToken installApplicationBundleAtPath:withOptions:andError:withCallback:] + 1440
4  IDEiOSSupportCore          0x000000011eccf999 __118-[DVTiOSDevice(DVTiPhoneApplicationInstallation) processAppInstallSet:appUninstallSet:installOptions:completionBlock:]_block_invoke.294 + 3534
5  DVTFoundation            0x00000001079b4931 __DVT_CALLING_CLIENT_BLOCK__ + 7
6  DVTFoundation            0x00000001079b655b __DVTDispatchAsync_block_invoke + 1191
7  libdispatch.dylib          0x00007fff20508603 _dispatch_call_block_and_release + 12
8  libdispatch.dylib          0x00007fff205097e6 _dispatch_client_callout + 8
9  libdispatch.dylib          0x00007fff2050f5ca _dispatch_lane_serial_drain + 606
10 libdispatch.dylib          0x00007fff2051008d _dispatch_lane_invoke + 366
11 libdispatch.dylib          0x00007fff20519bed _dispatch_workloop_worker_thread + 811
12 libsystem_pthread.dylib       0x00007fff206b04c0 _pthread_wqthread + 314
13 libsystem_pthread.dylib       0x00007fff206af493 start_wqthread + 15
);
}
  • -


System Information

macOS Version 11.3 (Build 20E232)
Xcode 12.5 (18205) (Build 12E262)
Timestamp: 2021-04-29T22:41:18-04:00
Post not yet marked as solved Up vote post of bumbleparrot Down vote post of bumbleparrot
36k views

Replies

i trying to solve this problem over the month but was and am failing.

Given that, my advice is that you open a DTS tech support incident so that DTS’s iOS code signing specialist can help you one-on-one.

Share and Enjoy

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

Identifier=xxxxx

Format=bundle with generic

CodeDirectory v=20200 size=240 flags=0x0(none) hashes=1+3 location=embedded

Signature size=4896

Signed Time=Aug 10, 2021 at 2:13:55 PM

Info.plist entries=23

TeamIdentifier=Y44M6Qxxxxx

Sealed Resources version=2 rules=10 files=78

Internal requirements count=1 size=204

I had the same issue. We have a static library that we sign&embed. This library has some dependencies on some CocoaPods.

I was able to solve this issue by rearranging Build phases in my Apps Targets Build Phase settings.

Correct order was as follows:

  • Compile
  • Copy Bundle Resources
  • Copy Pods Resources
  • Embed Pods Frameworks
  • Link Binary With Libraries
  • Copy our Static Framework (embed & sign)

Hope it will help anyone...

Go to Target settings and add flag --generate-entitlement-der to OTHER_CODE_SIGN_FLAGS

  • That worked for me, thanks for posting!

  • That worked for me too ! (the error appeared when trying to run app on ios 15.5 from xcode 12.4 , after iPhoneOS.platform>>DeviceSupport updated with 15.5) thanks !!

Add a Comment

I tried various things, last my issue was resolved when i click on trust on device -> general -> device management

Apple has changed the codesign signature to include DER encoded entitlements in addition to the plist encoded entitlements. This additional DER encoded entitlements section is required in iOS 15 and becomes the default behavior of codesign in the latest Xcode. To use codesign on an older machines with an older version of Xcode add the --generate-entitlement-der flag to your call to codesign. If signing through Xcode, you can add this flag to the OTHER_CODE_SIGN_FLAGS setting in the Build Settings tab.

from here: https://stackoverflow.com/a/68467307/7033956

  • yes, i follow the link and fix the bug

Add a Comment
  • You will need to add the --generate-entitlement-der to your OTHER_CODE_SIGN_FLAGS under Build Settings.

Add a Comment

If you are getting this error.. it is a bug! There is no solution to this other than rebuilding your project and removing all package dependencies which are not absolutely necessary! Do not waste your time and energy trying to solve this... it's an issue with one of your package dependencies and is out of your control. Good luck!

i am still facing this issue in xcode 13.2, applied all possible answers but no luck

Found a workaround and described it in this thread.

TL;DR Adding the following options to the codesign command will result in a v=20500:

-o runtime --runtime-version "16.4.0"

So the solution would be adding those options to the OTHER_CODE_SIGN_FLAGS in the Build Settings of your app target, e.g.:

-o runtime --runtime-version $DEPLOYMENT_TARGET

After this the app successfully installs on a device.