Xcode 6.1 iOS Distribution is always revoked or missing - ios

I'm trying to submit an app but I'm stuck. I can't get a the iOS Distribution signing identity to show up as valid under my account in Xcode 6.
It always shows up as revoked, never valid. I've made sure to connect it to my provisioning account on the dev site.
I also went to the developer site, revoked it there, recreated it, then went back to xcode to try to submit my app but I get this message:
When I check my account in preferences after getting this message, the iOS distribution doesn't even show up:
And when I try to add one it says:
I've tried:
Deleting the iOS Distribution cert and regenerating it on xcode (generates as revoked)
Deleting it and creating it on developer.apple.com
Linked my provisioning profile to the correct app id
Using Xcode 5 to submit my build instead
I don't know what to import or where to find a developer profile from. I've checked the dev documentation and it says the Your account already has a valid iOS Distribution certificate error happens when switching mac computers, but this is all on the same machine. I am using a VMWare to run this on an virtual image of iOS Mavericks, could that be culprit?

Make sure the time settings on your Mac are correct.
When you use a virtual machine and pause it, it pauses the time on the Mac as well. Your time settings are probably pushed back because of it, making your certificates invalid valid until a time later in the future.
For more info, see: Distribution certificate error:"This certificate is not yet valid."

Related

Xcode Signing certificate is invalid when build on ext device

I'm trying to solve an issue with Xcode 8.3.3 that prevents me to test my Apps on my devices.
At the moment I'm using a free provisioning account for my tests.
I've worked many months without any problem, then I've upgraded to Sierra and Xcode 8.3.3.
Unfortunately I don't know exactly after what action/update the problem started, because I have not used Xcode for several months.
The issue: when I try to build my app to run on my iPhone, I get these errors in project page, under General > Signing view:
Automatic signing failed
Xcode failed to provision this target. Please file a bug report at http://bugreport.apple.com/ and include the Update Signing report from the Report navigator.
Signing certificate is invalid.
Signing certificate "iPhone Developer: edoxxx#me.com (xxxxxxx)", serial number "xxxxxxx", is not valid for code signing. It may have been revoked or expired.
The issue happens either on my main Mac account and also if I create a fresh new user account,
it happens also if I use another AppleID account for code signing.
but it doesn't happens if I boot the same machine into another macOS installation (using the same AppleID and same device). In this last case I'm able to build and run the app without any issue on my device.
Because of that behaviour, I think that is something related to some software crap in the first OS installation, and not related to my user's "data" nor my AppleID account.
I've tried everything I've found on internet to clean-up the Xcode installation, including total removal/reinstall plus Keychain cleanup. But nothing solved the problem.
I've found some related informations in this topic:
https://forums.developer.apple.com/thread/83611‌
but no real solution.
Hope that someone could help me :)
Bye,
Edoardo
Here's what worked for me:
Open "Keychain Access"
Find the private key called "iOS Developer"
Delete the private key
Try code signing again, it should work!
I had the same thing happen to me. I discovered my problem was that in my build settings I had set my Code Signing Identity
Debug to iOS Developer
and my
Release to iOS Distribution
Because they were different. One wasn't able to find a signing certificate. The signing certificate I had downloaded was and iOS Developer certificate so when I switched my Code Signing Identity for Release back to iOS Developer everything was fixed.
After further investigation, I've found the problem.
Looking at differences in keychain between my productive machine and the fresh OS installation, I've dicrovered that the "Apple Worldwide Developer Relations" CA was missing in my productive machine (no idea why...).
I've erased all my developer certificates, downloaded new certificates from https://www.apple.com/certificateauthority/.
After the code signing fix in Xcode, I was back able to build and run my app on my device.
Strange that Xcode does not handle this kind of errors correctly, but report a "generic" error about code signing.
Although I added the new, valid certificate to the keychain, it was not working. The solution for me was:
1. Restarting Mac OS (because deleting certificate was not working)
2. Deleting all invalid certificates
You don't have to do something further. The valid certificate is being automatically used for your deployment(/development) provisioning profile.

iOS - Cannot Install Certificate

I've been around Stack Overflow a lot trying to solve this issue, and it's making very little sense.
I'm trying to publish an app, but I'm getting the error:
This is utterly confusing, because we have three different certificates for iOS Distribution and I've downloaded all three of them and attempted to add them to Keychain. The Preference->Accounts=>View Details dialog does not show the certificates. It only displays (even after refreshing) an iOS Development and a Mac Development certificate. When I attempt to add an iOS Distribution certificate I get a similar error, despite the fact we have THREE valid iOS Distribution certificates.
I've started from scratch too. I deleted all provisioning profiles related to the app in the Member Center, recreated the app Identifier to make sure it mirrors the Bundle Identifier, and generated a new provisioning profile with the valid certificate and app ID, downloaded and installed it, and I am STILL getting the same error.
I've gone into Build Settings and switched between automatic and assigning specific provisioning profiles.
The biggest issue is that the certificates don't appear in keychain. I double click on them and keychain opens, but nothing happens. I drag them into keychain, and still nothing happens.

The identity used to sign the executable is no longer valid at Xcode

I tried to run the program on my device and I got that error The identity used to sign the executable is no longer valid. I have tried all discussions provided in this link. All didn't work for me. I deleted all developer certificates and get new certificate from Apple and put it into the keychain. Then I made new development provisioning profile as Xcode iOS Wildcard App ID (to be generic). The status is active at Apple's developer site. So I put it into provisioning profile. I choose the correct certificate and profile at Code Signing from Build Phases at Xcode. I did all what I can think of, but that error never disappear. My Xcode version is 6.4 and my iOS is 8.4, all latest versions. What could be wrong?
Thanks
Check device UDID is correctly added and also check if device is added in provision profile or not
All what they post above are correct. The problem sometimes depends on some small issues individually. For me how I solved is
(1)I started from scratch. All certificates, app id , provisioning profile etc everything I made new in the portal. In the step making provisioning profile, profile should link to certificate and your device.
(2)Then need to check the development certificate is valid. Sometimes, the certificate is not valid immediately. For that, I reset the system clock and timezone at both device and Mac pc. I am not sure because of resetting the clocks at both devices or not, when I reboot the systems the certificate became valid. Then it works afterwards.
I went to the portal, deleted all of my certs (no live apps currently) and used the 'create' btn from the accounts menu:
Preferrences | View Details | Action => 'Reset'
Remove your apple id from Xcode preference and add it back again. Clean, rebuild and make sure coding signing is correct in project settings. That works for me.
I have solved the same problem. Just from "https://developer.apple.com/account/ios/profile/production/create" re-created the new Provisioning Profiles. Then download and install the new Provisioning Profiles of (Development and Distribution).

Issue while submit to app store - "you are already has a valid ios distribution certificate"

enter image description hereI am trying to submit my updated version of app to app store in my machine.
While exporting I am getting the error "Your account already has a valid iOS distribution certificate”.
Previously it was done by another person in one another machine, but i am not having the old certificate and provisioning profile.
I created the certificate and provisioning profiles, so all my code signing identities are on my machine. I'm able to run the app in device with the same certificate, I can create ipa in my machine and install the ipa in iPad its working fine, but unable to submit to app store.
I am using Xcode 6.3.2, Please anyone guide me on this.
Sounds like you may have created an additional distribution certificate. Login to your developer account manually and check this. If you do have two, then delete the older one (which I will assume was created by the previous developer).

Xcode messing up with certificate identities and multiple team ids

When building my App (for Archive) I get:
You have a valid iOS Distribution certificate in the Member Center,
but it is not installed locally. If your signing identity is installed
on another Mac, you can export a developer profile on that Mac and
import it on this Mac. You can also revoke your current certificate
and request a new one.
The Apple documentation suggests that its because I just moved computer. See link here.
However I haven't just moved computer. I am simply trying to upload my build to iTunes connect.
My email is associated to two developer profiles that are both installed on my Mac and hence I believe that Xcode its confusing itself by believing that I have already a profile installed.
For this reason I created a new distribution profile from the member centre, one for App Store distribution and one for ad hoc distribution. I then dowloaded it and clicked on it. Despite having done so it does not work.
When I click on Fix issue I get the message quoted above.
I tried to refresh the details in the Accounts sections of Xcode preferences, but was not of much help.
I believe Xcode is messing up with the team ids.
Is there a way to solve this without revoking and requesting a new certificate?
And if not what is the best way to fix this?
I would try downloading and installing the certificate from the portal. Then open the KeyChain app and see whether it appears under "My Certificates" section. If so, that should fix your problem, though check to make sure you don't have duplicates. If it does not appear, then it means you don't have the private key, and it will not be useable unless you can import the private key. You probably need to revoke and create a new certificate.

Resources