Creating a provisioning profile and signing it - xcode

When trying to archive, Xcode throws lots of errors.
Failed to create provisioning profile.
It also complains about no registered devices:
There are no devices registered in your account on the developer website. Plug in and select a device to have Xcode register it.
And some more errors related to provisioning profiles:
No profiles for 'com.Tom-s-Creations.Bouncy-Heavens' were found
Xcode couldn't find any iOS App Development provisioning profiles
matching 'com.Tom-s-Creations.Bouncy-Heavens'.
I'm new to Xcode code signing and would like some help. How would I go about this issue?

First solution:
You have to create a profile on the apple developer website.
https://developer.apple.com
There you can you also register devices for the development.
You can set the provisioning profile in Xcode on the signing area below the team.
Second Solution:
You can also enable automatic signing in the signing area. Selet "your name" (Personal Team)
So no signing is required. This has the disadvantage that you can only use the simulator. If you need real hardware for development and testing you have to sign.

Related

Xcode-apple developer account errors

I wanna publish a test flight on i phone that was published a few times before. when I wanna achieve the app's codes on Xcode I get that errors.
Failed to create provisioning profile. There are no devices registered in your account on the developer website. Select a device run destination to have Xcode register it.
No profiles for 'com.OttoTilesDesign.OttoTilesDesignVisualizer--explicit--' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'com.OttoTilesDesign.OttoTilesDesignVisualizer--explicit--'.
If you want to publish you need an "App Store" provisioning profile connected to the "identifier" in your app.
Use this profile in unity and xcode.
Try to create a new one. I had a similar issue and a reimport solved it.
Be sure that you select "any ios device" in the topline of xcode.
you only need a registered device when you want to deploy for internal/local testing.
if you want to do that, you need to register your devices with the uuid under: https://developer.apple.com/account/resources/devices/list

macOS App manually signing with provisioning profile for App Store got error Code signature invalid

I try to use manual signing in macOS using provisioning profile. But everytime I try to run it will crash with error
EXC_CRASH (Code Signature Invalid)
If I try to use automatically manage signing or manually manage signing but without provisioning profile it works fine. What is wrong with my provisioning profile? I need to use manual manage signing because my app actually is Xamarin.mac which is not possible in VS for Mac to sign automatically or sign manually without provisioning profile. I am not using weird entitlement. I only need app sandbox to release app store so in my provisioning profile I don't add any capabilities
If your signature is invalid it is likely that you haven't created the correct type of certificate. There are several certificate types that can be instanced and your app will not build correctly if you have created the wrong certificate type.
Common certificate types include:
iOS development
iOS distribution
Mac app development
Mac app distribution
Mac installer distribution
Developer ID application
Developer ID installer
For more information about manually creating your certificate, see my answer to this question: macOS installer certificate evaluation error in Keychain: Invalid Extended Key Usage
Also note that during development you would use an iOS development certificate, but for uploading to the App Store via iTunes connect, you will need an iOS distribution certificate and it needs to be enabled on an Apple ID that has paid for iOS distribution. For more information on enrollment to the Apple developer program, which will enable you with privileges to get a valid distribution certificate see here: https://developer.apple.com/support/enrollment/
If you are sure that it is not a problem with the certificate itself, do note that there other parameters involved when creating a provisioning profile manually - it's not just a certificate + private key. This is a profile that needs to be created in the Apple developer portal, but as long as you have a valid Apple ID to use for creating the provisioning profile it shouldn't be difficult. There are detailed instructions here: https://learn.microsoft.com/en-us/xamarin/ios/get-started/installation/device-provisioning/manual-provisioning but allow me to paraphrase:
1) Go to the Apple Developers Member Center (https://developer.apple.com/membercenter/index.action), and under the section Certificates, Identifiers & Profiles select "Provisioning Profiles".
2) Click the + button, in the top right corner to create a new profile.
3) From the Development section, select the radio button next to iOS App Development, and press Continue:
4) From the dropdown menu, select the App ID that to use
5) Select the Certificate(s) to include in the provisioning profile, and press Continue
6) Select all the devices that the app will be installed on, this will be all the devices and computers that belong to your Apple ID that will get a distribution certificate installed on it.
7) Provide the Provisioning Profile with an identifiable a name, and press Continue to create the profile
8) Press "Download" to download the provisioning profile onto a Mac
9) Double-click on the file to install the provisioning profile in Xcode. Note that Xcode might not show any visual clues that it has installed the profile except for opening. This can be verified by browsing to Xcode > Preferences > Accounts. Select your Apple ID and click "View Details..." Your new provisioning profile should be listed, as illustrated below:
After the provisioning profile has been successfully created it may be necessary to restart Xcode so that all the development certificates are correctly loaded and available for use.
Checklist:
Is my code signing certificate the correct type
Was my provisioning profile properly registered in the Apple Developer portal (https://developer.apple.com) for the Apple ID that is used on the machine building the app
Is my Apple ID correctly enrolled in the Apple Developer program with no outstanding fees to be paid, or licenses like EULA to accept.
Have I downloaded my provisioning profile from my Apple Developer portal and correctly installed it on my machine that is trying to build / release the app.
NOTE:
In order to distribute apps to the app store there is no choice but to create and pay for the provisioning profile within the developer portal, and install it on your machine by downloading it from Apple.
Best of luck!

Xamarin/XCode register provisioning profile error

I have the following problem. I'm creating Xamarin iOS application(by vs for max 2017) and during a building I have this error:
No installed provisioning profiles match the installed iOS signing
identities.
As far as I can understand the solution of this problem is connected with creating provisioning profile by xCode. But when I try to generate provisioning profile(with name testtesyui) by xCode I see this error:
Failed to create provisioning profile.
There are no devices registered in your account on the developer website.
Plug in and select a device to have Xcode register it.
No profiles for 'testtesyui' were found
Xcode couldn't find any iOS App Development provisioning profiles matching 'testtesyui'.
I don't have any real iOS device and I'm planning to use iOS emulator.
Below, I listed screnshoots from xCode ui(I've hid personal data):
xCode account settings,
xCode general settings
Could some one help with this problem? Please let me know if you need more details.
Thanks.
Updating:
I opened info.plist file in vs for mac and I saw the following:
info.plist content.
I've tried to sign in in my apple account, but in the end I saw this message:
signin. As a result, I still cannot select my team.
Could you please give advice where am I wrong?
my problem was in a solution configuration. By some reason, I tryed to build my application in Debug|iPhone mode, not in Debug|iPhoneSimulator mode.
When I switched to Debug|iPhoneSimulator mode, then the build works fine.
You need to enable automatic signing to work with simulator
Once you’ve ensured you have an Apple ID connected to Visual Studio for Mac, you’re ready to enable Automatic Signing
Steps
In your iOS project, open the Info.plist file. In the Signing section, select your team from the Team dropdown:
Then, select the Automatically manage signing  checkbox.
More Info here

Xcode 8 - Provisioning Profile vs. Provisioning Profile (Deprecated)

I have just updated to Xcode 8 and I now have two options for app signing, Provisioning Profile and Provisioning Profile (Deprecated).
Why is one deprecated, and what is the difference between the two?
Update 2017/02/13
User interface for managing signing certificates and provisioning profiles has been changed at Xcode 8.3 beta 2.
Changed the user interface for managing signing certificates and
provisioning profiles. Certificates are managed from the Accounts
preferences pane by selecting a team and clicking Manage Certificates.
Automatically managing signing is recommended, however if your app
requires manually signing provisioning profiles are managed in the
General tab of the project editor. Use the Provisioning Profile
dropdown to import or download profiles. In addition it displays
profiles that match the current signing configuration of the target.
(28641027)
Why is one deprecated?
I think Its deprecated because the signing system has been rewritten in Xcode8.
The signing system has been rewritten to include a new mode for
automatically managing signing assets, in addition to a dedicated
manual mode where the profiles for the target must be explicitly
selected. When automatically managing signing assets, Xcode will
create signing certificates, update app IDs, and create provisioning
profiles. For manual mode, only custom created profiles can be
selected and Xcode will not modify or create any signing assets. Xcode
now encodes profiles in the target using the
PROVISIONING_PROFILE_SPECIFIER build setting. This setting allows
specifying both the team ID and the name or identifier of the profile.
There are some Signing relate known Issues with Xcode 8.1 you should known.
So maybe we should not set Provisioning Profile in Build Setting tab, switch to General tab , and set in Signing category instead.
If you set provisioning profile in Build Setting and enable Automatically manage signing in General tab Xcode will complain about that.
What is the difference between the two?
I also updated to XCode 8 and ran into this as well. Both the Provisioning Profile and Provisioning Profile (Deprecated) were set as blank on my project in XCode 8.
I tried setting them back to what they were for each environment but the Debug environment had all of the options in the dropdown removed.
After creating an Archive and uploading to iTunes Connect I got a notice that the provisioning profile wasn't quite correct, which was working fine prior to XCode 8.
Following what the others have posted about XCode 8 getting an update to its Signing, I went to the general tab and noticed a new section that allows you to have XCode automatically manage the signing. I checked that box and now it looks like this:
I have not uploaded a new Archive to iTunes Connect yet but when I do I'll add an update here to see if it's resolved the Provisioning Profile warning.
UPDATE:
After selecting Automatically manage signing in XCode and re-sending to the App Store it's still complaining so that didn't quite work. Might have to remove and re-create all provisioning profiles to get this working. What a pain. Thanks Apple.
In Provisioning Profile (Deprecated) description, information is The UUID of a valid provisioning profile. A missing or invalid profile will cause a build error (deprecated, use [PROVISIONING_PROFILE_SPECIFIER] instead).
I found the link https://possiblemobile.com/2016/06/code-signing-xcode-8/.
Please follow these steps
Select project TARGET and go to GENERAL tab
Under Signing check the option Automatically manage signing
Hope that helps !

Weird code-signing error

I'm trying to upload a new Mac app, designed under Xcode 5, to the Mac App Store. I have done this before for many apps with previous Xcode versions, so I thought I had it mastered, but I am banging my head against this one. It must be some trivial issue, but I don't see what!
Description of my settings:
My target's "General" settings have "Signing: Mac App Store", then my account as "Team"
I have sandbox enabled ("Capabilities" tab of the target)
In "Build Settings", I have:
CODE_SIGN_ENTITLEMENTS = MyApp/MyApp.entitlements
CODE_SIGN_IDENTITY = Mac Developer
PROVISIONING_PROFILE = Mac Team Provisioning Profile: com.myname.myapp
The app builds and runs fine. Yet, when I validate it for App Store distribution, I get the following error:
Invalid Provisioning Profile. The provisioning profile included in the bundle MyApp [MyApp.app] is invalid. [Missing code-signing certificate.] For more information, visit the Mac OS Developer Portal.
What am I missing?
Solution
You should review the section in the App Distribution Guide covering the management of certificates and provisioning profiles for Mac Apps. Specifically the section on Troubleshooting will provide the most insight and covers fixes for the provision profile issue you've reported. I recommend you explore the entire troubleshooting area as sometimes certificate expiration dates impact the validity of provisioning profiles.

Resources