Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: [XE7][IOS] Problem with code signing


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 10 - Last Post: Dec 9, 2014 11:58 PM Last Post By: Kick Martens
Karol Wierzchoł...

Posts: 11
Registered: 3/6/12
[XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 20, 2014 3:44 AM
Hello,

I have created app for iOS and published it in AppStore.
Now, I try to upload new release and I have problem. I use last Delphi XE7 with Update 1.

Bundle ID is OK: pl.Company.AppName

When I try to upload IPA file with Application Loader, I have issue:

ERROR ITMS-9000: "Invalid Code Signing Entitlements. Your application bundle's signature contains code signing entitlements that are not supported on iOS. Specifically, value 'XXXXXX.AppName' for key 'application-identifier' in 'Payload/AppName.app/AppName' is not supported. This value should be a string starting with your TEAMID, followed by a dot '.', followed by the bundle identifier."

Hmm.. the first step in Application Loader is passed, so I think, bundle is OK. On next step I have this error.

On Project->Options->Provisioning I have corrected value for CFBundleIdentifier (pl.Company.AppName, BTW first step is passed). So, why in 'application-identifier' is wrong value: XXXX.AppName. I think, it should be XXXXX.pl.Company.AppName. But, where can I define it?

Can You help me?

TIA
Eli M

Posts: 1,346
Registered: 11/9/13
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 20, 2014 7:49 AM   in response to: Karol Wierzchoł... in response to: Karol Wierzchoł...
Look in your yourappname.entitlements file in the Release directory. What is in it?

In my App Store IPA file (which is just a zip file you can open) there is no entitlements file at all. If your app doesn't use entitlements it probably shouldn't have one either.
Hassan Farzadeh

Posts: 8
Registered: 3/16/00
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 20, 2014 9:35 AM   in response to: Karol Wierzchoł... in response to: Karol Wierzchoł...
Karol Wierzchołowski wrote:
Hello,

I have created app for iOS and published it in AppStore.
Now, I try to upload new release and I have problem. I use last Delphi XE7 with Update 1.

Bundle ID is OK: pl.Company.AppName

When I try to upload IPA file with Application Loader, I have issue:

ERROR ITMS-9000: "Invalid Code Signing Entitlements. Your application bundle's signature contains code signing entitlements that are not supported on iOS. Specifically, value 'XXXXXX.AppName' for key 'application-identifier' in 'Payload/AppName.app/AppName' is not supported. This value should be a string starting with your TEAMID, followed by a dot '.', followed by the bundle identifier."

I have exactly the same error when I try to deploy to appstore using Ad Hoc which is needed for TestFlight. I tried it with Hot fix from today and still the same issue
Karol Wierzchoł...

Posts: 11
Registered: 3/6/12
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 20, 2014 1:48 PM   in response to: Hassan Farzadeh in response to: Hassan Farzadeh
Hassan Farzadeh wrote:
Karol Wierzchołowski wrote:
Hello,

I have created app for iOS and published it in AppStore.
Now, I try to upload new release and I have problem. I use last Delphi XE7 with Update 1.

Bundle ID is OK: pl.Company.AppName

When I try to upload IPA file with Application Loader, I have issue:

ERROR ITMS-9000: "Invalid Code Signing Entitlements. Your application bundle's signature contains code signing entitlements that are not supported on iOS. Specifically, value 'XXXXXX.AppName' for key 'application-identifier' in 'Payload/AppName.app/AppName' is not supported. This value should be a string starting with your TEAMID, followed by a dot '.', followed by the bundle identifier."

I have exactly the same error when I try to deploy to appstore using Ad Hoc which is needed for TestFlight. I tried it with Hot fix from today and still the same issue

Where can I find this hotfix?
Eli M

Posts: 1,346
Registered: 11/9/13
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 20, 2014 2:07 PM   in response to: Karol Wierzchoł... in response to: Karol Wierzchoł...
Here:
http://cc.embarcadero.com/item/30036

However, that came out before Update 1. I would hope Update 1 already has that in it.
John Frazier


Posts: 726
Registered: 2/17/00
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 26, 2014 12:18 PM   in response to: Eli M in response to: Eli M
Eli M wrote:
Here:
http://cc.embarcadero.com/item/30036

However, that came out before Update 1. I would hope Update 1 already has that in it.

It does. Pay close attention to dates folks. That hotfix was intended to be used with the original RTM version of XE7.
--
John Frazier (Embarcadero Newsgroup Admin)
Hassan Farzadeh

Posts: 8
Registered: 3/16/00
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 26, 2014 12:34 PM   in response to: John Frazier in response to: John Frazier
John Frazier wrote:
Eli M wrote:
Here:
http://cc.embarcadero.com/item/30036

However, that came out before Update 1. I would hope Update 1 already has that in it.

It does. Pay close attention to dates folks. That hotfix was intended to be used with the original RTM version of XE7.
--
John Frazier (Embarcadero Newsgroup Admin)

Thanks for clarification John. I was desperate and hence tried it with the the old hotfix just in case that hot fix was not part of the update 1. Regardless, XE7 with update 1 still have two major IOS issues:
1. can't be used with IOS8 simulator (so we can't run on iPhone 6 / 6+ simulator. This is critical to have so that we can take screenshots and submit app to AppStore as screenshots from actual device is not acceptable since device resolution is lower than what appstore accepts! Screenshots from iPhone 6+ have a size of 1125x2001 while AppStore requirement is 1242 x 2208
2. can't compile for TestFlight submission (with Ad Hoc or AppStore compile) so now Delphi apps can't be beta tested.
Brian Hamilton ...

Posts: 556
Registered: 10/14/04
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 26, 2014 12:48 PM   in response to: Hassan Farzadeh in response to: Hassan Farzadeh
1. can't be used with IOS8 simulator (so we can't run on iPhone 6 / 6+ simulator. This is critical to have so that we can take screenshots and submit app to AppStore as screenshots from actual device is not acceptable since device resolution is lower than what appstore accepts! Screenshots from iPhone 6+ have a size of 1125x2001 while AppStore requirement is 1242 x 2208
2. can't compile for TestFlight submission (with Ad Hoc or AppStore compile) so now Delphi apps can't be beta tested.

simply use MS Paint to resize (pixel option, proportional off) the screen shots you do have , to the needed new sizes
Hassan Farzadeh

Posts: 8
Registered: 3/16/00
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 26, 2014 12:51 PM   in response to: Brian Hamilton ... in response to: Brian Hamilton ...
Brian Hamilton wrote:
1. can't be used with IOS8 simulator (so we can't run on iPhone 6 / 6+ simulator. This is critical to have so that we can take screenshots and submit app to AppStore as screenshots from actual device is not acceptable since device resolution is lower than what appstore accepts! Screenshots from iPhone 6+ have a size of 1125x2001 while AppStore requirement is 1242 x 2208
2. can't compile for TestFlight submission (with Ad Hoc or AppStore compile) so now Delphi apps can't be beta tested.

simply use MS Paint to resize (pixel option, proportional off) the screen shots you do have , to the needed new sizes

Brian,
We also thought it was as simple as resizing it and did it, but unfortunately, our app got rejected.
Brian Hamilton ...

Posts: 556
Registered: 10/14/04
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 26, 2014 3:34 PM   in response to: Hassan Farzadeh in response to: Hassan Farzadeh
We also thought it was as simple as resizing it and did it, but unfortunately, our app got rejected.

worth a try...worked for me (but mine was a free app, so maybe more lenient?)
Kick Martens

Posts: 2
Registered: 10/3/01
Re: [XE7][IOS] Problem with code signing  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Dec 4, 2014 8:22 AM   in response to: Brian Hamilton ... in response to: Brian Hamilton ...
Brian Hamilton wrote:
2. can't compile for TestFlight submission (with Ad Hoc or AppStore compile) so now Delphi apps can't be beta tested.

You have to follow these steps to get it to work:
1) You to regenerate your "App Store Distribution" provisioning profile. Just go to Apple Developer - Apple Member center, click "certificates", and under provisioning profiles - distribution, pick your App store distribution profile. click "Edit" for your profile and click "Generate'. Download this profile or fetch it using Xcode. Make sure that for your project, the provisioning for "App Store" is pointing to this profile.

2) You have to add a key in your entitlements for it to work. There is a file in your project directory named "Entitlement.TemplateiOS.xml". This is the template for your Entitlements file. This should look something like this:

<?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>
<%getTaskAllowKey%>
<%applicationIdentifier%>
<%pushNotificationKey%>
<%keychainAccessGroups%>
</dict>
</plist>

We need to change it so the entitlement for betatesting is always added:

<?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>beta-reports-active</key>
<true/>
<%getTaskAllowKey%>
<%applicationIdentifier%>
<%pushNotificationKey%>
<%keychainAccessGroups%>
</dict>
</plist>

3) also check if Deployment options "ios device" for your project contain your entitlements file. Create an empty project to check how they should be.

4) Now build and deploy your app using the "application store" configuration. You can check if your ipa file contains the right entitlements by just renaming the .ipa file to .zip. then (on your windows development machine) you can simply view the contents of the ipa and you should check the file: \Payload\<yourappname>.app\embedded.mobileprovision. Just open it with notepad and look for <key>Entitlements</key> beneath it should be the contents of your entitlement file, check that it contains the <key>beta-reports-active</key><true/> segment!

5) upload the build using apploader and check the "Testflight beta testing" switch on the right side above your build overview in iTunes Connect

EDIT: You should remove the changes in the xml when you are debugging. For some reason you get an e8008016 error when you want to deploy and test to a device. reverting the changes in the xml fixes this again. I will try to figure out how to make this working for both situations

Edited by: Kick Martens on Dec 9, 2014 11:55 PM
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02