Application could not be uploaded to the device. Your code signing/provisioning profiles not correct

julien_BEjulien_BE Member ✭✭

Hello,

(sorry for the non clickable links, it's my first post, and seems I cannot put url yet)

I'm quite lost here. It has been a few hours I'm stuck on this one. :s
I enabled Push Notifications service to my existing App ID through the Provisioning Portal on Apple's website.
image.ibb.co/ncwscy/image.png

I regenerated the provisioning profiles and downloaded them on my mac. Push notifications is correctly added to the provisioning profiles.
image.ibb.co/jK3AVJ/image.png

In Debug Mode everything works as expected. I can start my app in debug mode on my iPhone and I receive correctly push notifications.

When I try to deploy the app in Release Mode on my iPhone, I got the following error:

VerifyingApplication - PercentComplete: 40%
ApplicationVerificationFailed: Failed to verify code signature of /private/var/installd/Library/Caches/com.apple.mobile.installd.staging/temp.2G7ky8/extracted/restofriends.iOS.app : 0xe8008016 (The executable was signed with invalid entitlements.)
error MT1006: Could not install the application '/Users/julien/Projects/stoemp-front/iOS/bin/iPhone/Release/restofriends.iOS.app' on the device 'iPhone de Julien': Your code signing/provisioning profiles are not correctly configured. Probably you have an entitlement not supported by your current provisioning profile, or your device is not part of the current provisioning profile. Please check the iOS Device Log for details (error: 0xe8008016).

Application could not be uploaded to the device.

I compared the entitlements of the app and the embedded provisioning profile like explained here but content is the same:
developer.apple.com/library/content/qa/qa1798/_index.html

App file:
image.ibb.co/g4uQVJ/image.png

Provisioning profile:
image.ibb.co/iZcLVJ/image.png

I split my Entitlements.plist file into two files, to be sure to have 'production' as aps-environment when in Release mode.
stackoverflow.com/questions/45941192/automated-conversion-of-aps-environment-from-development-to-production-in-xamari

Nothing change, still always have the same error.

I tried to rebuild, to restart Visual Studio, and even restarted my iPhone, still always have the same error.

Visual Studio for Mac Version 7.5.2 (build 40)
Mono 5.10.1.57
Xamarin.iOS 11.12.0.4
Xcode 9.4 (14160)

Any idea ?? :smile:

Answers

  • julien_BEjulien_BE Member ✭✭

    I'm a bit progressing !

    Finally I get it deployed in Release mode.
    I had to change the Signing Identity and Provisioning Profile in the iOS Bundle Signing options.
    It was set to Automatic

    image.ibb.co/eocbLJ/image.png

    It seems setting them to Automatic make it fails to deploy ??!

    Any idea why? I would prefer to have them back to Automatic

Sign In or Register to comment.