When you build an iOS app using Xcode, certain settings in your project are used to automatically create the required code-signing (签名服务)files during the build process. For example, if you have not yet created a development certificate and provisioning profile, Xcode will generate one for you automatically. If you have previously created these items but want to switch to another certificate or profile for testing purposes, then you should manually change this setting in Xcode before building again.
With Xcode
Using Xcode, you can sign your app using your developer profile or Apple’s free provisioning profile.
You can use your developer profile to distribute the app on the App Store and test it on devices.
If you want to publish an app on the App Store, you need a paid Apple Developer Program membership.
Apple offers a free tier of its Developer Program that allows developers to deploy apps for development and testing only. This provisioning profile is referred to as “Development” or “Instructional” in Xcode but is called “Free (Ad Hoc)” when read from iTunes Connect after creating an ad hoc distribution build for uploading an IPA file for manual testing by beta testers or internal teams within your organization before submitting it via TestFlight or HockeyApp directly into Apple Review Queue for review by Apple staff prior publishing it publicly as a final product version through iTunes Connect (or App Store Connect).
Before you distribute an app to users or submit it to the App Store
Signing up is one of the most important steps in the life of your app. It’s also one of the most under-appreciated, but it’s a critical step for making sure you can distribute your app and get it into users’ hands safely.
To understand why signing is so important, we need to understand how iOS works.
When you create an app, it’s not actually “complete.” It has some code that runs when your app is launched, but there are also a lot of other things that happen behind the scenes. For example, iOS runs through a series of checks to make sure your app loads properly and doesn’t have any issues that could cause problems for users.
Xcode will automatically generate the appropriate signing assets for iOS
Xcode will automatically generate the appropriate signing assets for iOS, tvOS, and watchOS platforms. The signing process is automated by Xcode and performed in the background without any user intervention.
For macOS apps that are intended to be distributed outside the Mac App Store, use Xcode to manually sign the app with a Developer ID certificate; this is necessary for Gatekeeper compatibility.
Xcode will automatically generate the appropriate signing assets for iOS, tvOS, and watchOS platforms.
To create a provisioning profile that can be used by Xcode for manual distribution, follow these steps:
-Log in to your Apple Developer account at developer.apple.com.
-Select Certificates from the menu on the left side of your screen.
-Click on Identifiers under Certificates in the left navigation bar at https://developer.apple.com/account/#/certificates/.
Signature identity is the only digital signature
Signing identities are unique digital signatures that certify who you are and what apps you can develop. The most commonly used signing identity is an Apple Developer ID (ADID), which is used by all iOS applications for code signing. Other types of signing identities include:
Enterprise Distribution Certificates (EDC)
App Store Purchaser IDs (APID)
A distribution provisioning profile is used to specify which devices can run your app
When you sign your app, the signing tool generates a distribution provisioning profile. The distribution provisioning profile is used to specify which devices can run your app, as well as which App Store environment (sandbox or production) to use when submitting your binary for review.
When you’re ready to send an app to Apple and want it reviewed by Apple’s internal testers or in the App Store review queue, you need to create or update one or more distribution profiles. A distribution provisioning profile is a file that contains information used by iTunes Connect and Xcode on iOS devices when submitting apps for review on Apple platforms (iPhone, iPad, etc.).
A provisioning profile is a collection of digital entities
The provisioning profile is a collection of digital entities that uniquely ties developers and devices to an authorized iPhone Development Team and enables a machine to be used for testing.
A provisioning profile contains information about your apps, such as their name and bundle identifier, along with the distribution method. The distribution method determines how your apps are deployed to devices for testing. If you want testers to be able to run your app on their devices using TestFlight beta testing, then select Internal Only as the distribution method.
When you build an iOS app using Xcode
When you build an iOS app using Xcode, certain settings in your project are used to automatically create the required code-signing files during the build process. The code signing process is completely automated and happens behind the scenes as part of the build step of your project’s target. In simple terms: when you use Xcode to compile and package your app, it automatically generates a unique certificate for you (based on a variety of factors), then uses this certificate to generate one or more provisioning profiles that allow Apple’s App Store servers to accept your development builds as valid.
To prepare a development build for testing on an iOS device
To create a development build for testing on an iOS device, Xcode will automatically assign a development certificate and provisioning profile to each target in your project. These items are used by the OS at runtime when you run your app on an iOS device or simulator. A valid development certificate is required for code signing and must be uploaded along with any app that you want to release through the App Store.
A provisioning profile contains all of the information needed by an application or other software program so that it can run on an Apple device (iOS device or Mac). As part of preparing your app for distribution, you must create a provisioning profile specific to each type of device (iPhone/iPad) and operating system version (iOS 8) that you intend to support.
You need professional tools to do proper Ios builds and signings
The truth is that you need professional tools to do proper Ios builds and signatures(超级签名). Not only will the right tool make your app much more secure, but it will also make it easier to distribute your app.
Hopefully
This article has helped you understand the different types of signing tools available and what they can do for your app. As always, we recommend using Xcode for iOS builds because it offers great support for both code signing and ad hoc builds. But if you prefer to use tools other than Xcode, there are many alternatives out there that can help with your build processes.