iTunes Connect : why isn't my distribution profile "managed by Xcode"? - xcode

I'm stuck with this damn "Application failed codesign verification" warning that I simply can't solve... I'm about to submit my app to Apple. :(
Having a look to my provisioning profiles made me realize that the status of my development profile is "Active, managed by Xcode" whereas my distribution profile is only "Active". It may be the reason of this problem because anything else seems to be OK. So what is wrong here ?
Thanks a lot for your advices.

Having a look to my provisioning profiles made me realize that the
status of my development profile is "Active, managed by Xcode" whereas
my distribution profile is only "Active".
The team development profile includes certificates for all the developers on your team and device ID's for all your devices. Since only one person is authorized to distribute applications for any given account, and since there are no device ID's associated with the distribution provision, there's no need to have Xcode or the provisioning portal manage your distribution provision -- there'd be very little to manage.
It may be the reason of this problem because anything else seems to be
OK. So what is wrong here?
No, difference in the description of your development and distribution profiles isn't the problem. The problem is that the codesign utility was, for some reason, unable to sign your application. There are several things that can prevent your app from being signed, such as:
Wrong distribution profile selected in your project's build settings.
App ID in distribution profile doesn't match that of the app you're trying to sign.
Problem with distribution profile, e.g. an expired certificate.
There are also a great many questions right here on SO pertaining to signing your app for distribution. It doesn't make sense to rehash all those answers here, especially without more information about what you've already checked or at least seeing the specific error. Take a look at some of those questions first and see if something rings a bell. Otherwise, take a look at the Troubleshooting section of the Tools Workflow Guide.

Related

XCode test Distribution ipa in device

I have a little problem and I am wondering if this is possible. I have just finished updating an app with push notification for a client. I don't have a hold of the server side so I tested the push by modifying the app id and just make it as my own temporarily, created the necessary certificates and provisioning profiles and then tested it using PushMeBaby app. All works fine without problems.
And now, the client wants to publish it and he gave me the distribution certificate and provisioning profile for distribution. I am not a member of his team but I somehow find a way to build it using the command line.
Now comes my problem, I wanted to test it first on my device to check if the push notification works. The server is already setup since it is already existing in the store. I know for sure that the push will work, but somehow I really feel the need to test it first on my device. I tried to request him to use testflight for testing but he said he doesn't know how to do it. I tried to present myself to do it but he doesn't allow it because the original developer made some anomalies with his account, so as much as possible, he won't give it to me saying there must be other way to test it myself.
And so I asked, is there any way to test it with just the distribution certificate and provisioning profile provided? If not, what would be the best alternative to do it, considering having the client do a very minimal and easy stuff on his side, if any.
Hoping for someone to actually give a hand or a hint.
Thanks in advance.

Does running an example code from Swift learning resources really require enrolling in Mac developer program?

... or am I doing something wrong? (Yep. I was. Feel free to skip to the Update section.) I've read a couple of quickstart posts and was ready to dive into the "amazingly new language", so I visited https://developer.apple.com/swift/resources/ in order to get my hands on some nifty tutorials and what did I get? I downloaded a Lister XCode project, opened it, switched build target to My Mac, started the build and... all I got was a couple of windows telling me to become a developer for 99 bucks.
I'm pretty new to all this locked-in-itself Mac/OS X/whatever ecosystem and, coming here from mostly free and painful Linux, I find these little things really repulsive, so I hope that this problem is really in my head and I can run exemplary code without paying $99.
If this is an off-topic question, please point me in the right direction (except for the case when you think I should crawl into some dark corner and cry about how hard thing in real life are).
Update. This issue seems to have a happy ending. As some of you mentioned in the comment section and in your answers, I should've disable the code signing feature for the project in order to build and run it. The confusion was all mine when I did disable the signing procedure for the sub-projects that interested me (ListerOSX and its dependencies), but as it turned out, in order to successfully compile and launch the project, one also should disable signing for all the sub-projects (targets, whatever). E.g. if you are launching ListerOSX, make sure you've disabled signing for Lister Watch app etc.
Seeing as this was at least a bit subtle for me, of whom you might say 'Mac development newbie', I'd still ask you not to close the question but rather leave it open: should anyone else stumble into the same problem, my story might actually help.
Recent versions of Mac OS X will not allow software to run unless it is signed by a developer, or the user is technically savvy enough to bypass gatekeeper (which is not very hard. Just right click on the app and select "open", and then the unsigned software will run).
This is an attempt by Apple to block malware distribution. If malware is not signed, then users who are likely to fall for malware will not know how to make it run. If malware is signed, then Apple can can pass the signature (and associated contact details) to the FBI who will try to organise a lengthy jail term.
What this means for you, as a developer, is you need to either get a certificate or accept that your software will only run with gatekeeper turned off.
The normal mac developer program is $99/year and includes a whole bunch of stuff that makes it well worth the price. However there is a free "Developer ID" membership level that only gives you the ability to sign your apps.
So, you've got three options:
sign up for a free developer account and sign with that
sign up for a paid account
don't sign your code and accept that it will not pass gatekeeper. just disable code signing in your "release" builds. It's already disabled by default in "debug" builds.
Disable code signing via on all targets in the project settings. Code signing with an official Apple certificate requires a paid account. You can still sign your code to identify yourself as the author, but it will not pass Gatekeeper automatically and you will not be able to sign directly from Xcode.

One Provisioning Profile for multiple apps?

I am really confused with ios provisioning profile. Can I use one Development Provisioning Profile for multiple apps? Same question for Distribution Provisioning Profile.
thanks for your help.
Yes, you can use the same certificates for multiple apps.
It may seem complicated, but once you look at it, it's not so bad. Here's the breakdown:
The development provisioning profile gives you the opportunity to test apps you create (any) until you try to push it to Apple. When you do that, the distribution profile comes into play. Essentially, it connects any apps you produce with your App Store storefront.

Signing of binary by someone else

I am trying to figure out if I am in a potential bind here. I am having someone else develop my app and I have given them complete access to my developer account to create the certificates to build the binary. I have uploaded the binary using the Application Loader and it it now waiting for review by Apple. My question is when it comes time to update the app, will I be able to do so without using the programmer who signed the certificate? When I become competent I'd like to do this myself but I'm clearly not there yet. I don't want to be in a situation where I have to keep going back to the same programmer to do the smallest thing.
Yes, provided you:
Have them send you the signing assets as described in "Exporting Your Code Signing Assets to Your File System" in the Xcode documentation. Note that they will still be able to sign using your key.
Have them send you the original project, obviously.
Once you part ways with them you should change the passwords of any accounts they've been given access to, like Apple ID and iTunes Connect.
At a later date, or as a last resort, you can create new signing assets as described in "Reset You Signing and Provisioning Assets..." in the Tools Workflow Guide.
So, most important going forward, they must not have access to any Apple accounts belonging to you.

iDevice for Dummies: Can a device be assigned multiple provisions (Personal/Enterprise)? [closed]

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.
Closed 11 years ago.
Is it possible to assign multiple provisions to an iDevice? To be honest, I'm not sure if I'm using the correct terminology, but basically, I'm developing an iPad app for a company and I've only been testing it in the simulator because I don't have a registration to the developer program and they haven't setup their enterprise registration yet either. And I'm sure you all know how limited the simulator is...
I don't really care about the $99 it costs to join, but what I'm worried about is having my iDevices locked permanently to my personal registration and unable to switch back and forth to the enterprise registration.
I'd appreciate it if someone can explain to me how the registrations work. And keep in mind, I'm a dummy. :)
Thanks in advance!
You may provision your device with both the standard and enterprise programs, and install their individual provisioning profiles to build your app with. But you'll have to sign your app differently because the provisioning portal generates different app IDs for your app for each account.
If you'd like to test that provisioning profiles work correctly with different developer program accounts, you can duplicate your existing build configuration profile by Control-clicking your Xcode project, choosing Get Info, going to the Configurations tab and duplicating a configuration. Then sign one configuration against your standard provisioning profile, and sign the other against the enterprise provisioning profile (go to the Build tab and look under the Code Signing section). Once ready to test your app on your iPad, pick and build as necessary.
Yes. A device can have many different provisions installed from many different developers, either or both enterprise and personal (or occasionally special ones from Apple).
In summary, when you sign up for and are accepted into a paid iOS developer program, you can create and download 2 certificates, then you can download provisions (using those certificates and your device UDIDs and your app IDs), then Xcode, using those certificates and provisions, can build and sign apps that will run on any devices with those UDIDs and with those provisions installed.

Resources