Device registration and app re-signing
When developing an iOS app using your ad-hoc profile, you can only test on devices that are already specified in the provisioning profile for that app. Once you know these devices, you must register them in your Apple developer account, add them to your provisioning profile, generate a new provisioning profile, download and then build your app with the new profile.
App Center will help you register tester device IDs into your Apple Developer account and apply them to the latest release without leaving the App Center portal.
To configure devices, you can turn on automatically manage devices under distribution group settings, or opt-in to doing it when distributing a new release. This option will be under the Device step in the distribute new release wizard.
To add devices to an existing release, you can find register devices under the Distribution Group.
- Automatically managing devices in groups works only for distributing to non-public and non-shared groups.
- If you're distributing to individual users, you will have to register their devices manually, and re-sign the app. You can add these emails to a group to use the tools mentioned in this article.
- If you add multiple groups to your release, you have to configure each group separately using the Automatically manage devices under group settings.
- Managing devices is only required for iOS apps signed with a developer or ad-hoc profiles.
Before you can use the device capabilities of App Center, you will need:
- The production certificate used for the original app signing.
- The set of credentials to your Apple Developer account which holds the role of Account Holder, Admin, or App Manager.
- Turn off "Automatically manage signing" in your Xcode project.
Distribute new release
When distributing a new release, a Devices step is part of the wizard. The step checks if you have unprovisioned devices in the distribution group; if this happens, you can check the Register devices and sign my app checkbox. App Center then performs three operations for you:
- Register new device IDs in the Apple developer portal.
- Adds them to the provisioning profile and downloads it.
- Re-signs the uploaded binary so that all testers can install it.
The flow requires username and password for the Apple developer portal and the certificate used to sign the app at build time. The certificate is exported to a .p12 file; you can read more on how to generate a .p12 file here. If you already have Apple ID and certificate saved in App Center, you can choose it from the dropdown menus.
To initiate the device registration flow, select a distribution group with unprovisioned devices and navigate to the Devices tab.
Click the Register devices button.
A dialog prompts for your username and password used in the Apple developer portal.
a. Once you log in with your Apple username and password, App Center can add the unprovisioned devices to both your Apple developer account and the releases provisioning profile.
b. Optionally you can upload a .p12 file to resign the app and have it distributed to the newly added devices. You can read more on how to generate a .p12 file here.
If you want to add devices and make a distribution later, you can leave the re-sign unchecked and download the updated provisioning profile with the button on the review screen.
a. Alternatively, the profile is available to download through Xcode or the Apple developer portal.
Privacy concerns on username and password
When adding Apple credentials and a signing certificate to App Center, using a secure connection, it is uploaded and saved in an encrypted vault. It is not possible for any user to download or retrieve sensitive information from the vault.
By using a set of credentials and certificates, it is automatically available to app collaborators but only for that specific service. As an example, developer X adds credentials and certificates to distribution group "Tester," when developer Y distributes a new release to the Tester group, X's username, password, and certificate are by default selected. App Center only uses your Apple ID during the transaction, and it does not use it for any other means.
What is happening when you click register devices
App Center registers device IDs in your Apple developer account and adds them to the provisioning profile used for distribution. An Apple Developer account has a finite number of spots for devices split by device type. Apple works with five device types: iPad, iPhone, iPod, Apple TV, and Apple Watch. Each of these has a limitation of 100 devices, i.e., if you register six devices all of which are iPhones you have 94 devices IDs left for iPhones and still have 100 left for each of the four other device types.
What is re-signing
For app distribution, code signing is a necessity set by Apple; this is the same for distribution through Xcode, App Center, or the iTunes Store. Furthermore, code signing is a precaution to make sure nobody has tampered with your app. You can read more about code signing in the Apple documentation.
When you sign your app with an ad-hoc distribution provisioning profile, it includes a list of devices, which can install your app. When App Center re-signs an app, it first updates the provisioning profile to include all devices in a distribution group and then re-signs the app with the updated provisioning profile so that all devices can install the latest release.
Generating a .p12 file
To perfom this step, you need an Apple production certificate stored on your local machine. If this is not the case, you will be missing a private key.
Open the Keychain Access app on your Mac and select the My Certificates section on the left.
Find the right distribution certificate and expand it to see the corresponding private key.
A. If the private key is not present, you need to either create a new certificate or get it from the machine where the certificate was created.
Make sure both the certificate and the private key are selected, then right-click on the items to get the context menu and select Export 2 items….
Select a location on disk to save the file as a .p12 – it is recommended that you choose a strong password for the file.
Remove certificates and Apple IDs from App Center
You can remove the certificates and Apple IDs from App Center in the developer accounts.
- Click on your profile picture in the upper-right corner and select Account settings.
- In the left menu, click Developer accounts.
- Remove the secret use by using the three vertical dots on the right side of the table and click Remove...
Manually registering devices
If you're trying to distribute directly to users, you can follow these steps from the Apple Developer website to manually add devices to your account, and re-sign your app.
Profile not found
When logging into Apple through App Center, the provisioning profile(s) included in your application are checked against those in your developer account. If any profile used in the binary is not found in your Apple Developer account, App Center will not be able to re-sign your application. To resolve this, ensure that your Apple Developer account contains all of the provisioning profiles used in your application; you can check application profiles in the General tab of Xcode project settings, or the iOS bundle signing options in Visual Studio for Mac.
Team not found
When logging into Apple through App Center, the team included in your application are checked against those in your developer account. If any team used in the binary cannot be found in the used Apple developer account, App Center will not be able to re-sign your application. To resolve this, ensure that your Apple developer account contains the team used in your application; you can check the applications team in the "General" tab of Xcode project settings or the iOS bundle signing options in Visual Studio for Mac.
Updated license agreement
Apple periodically updates its license agreement, and for continued Developer portal use, you must read and agree with the updated license.
- Sign in to Apple Developer portal.
- Follow the instructions given to accept the license agreement.
App Center is unable to help with content in the license or the flow for the license agreement.
Our tester did not register their device ID
If a tester accidentally clicked I already registered it, follow the step to register a device manually:
- Navigate to https://install.appcenter.ms/register-device on your mobile device.
- Click Register and follow the on-screen instructions.
Contact us with questions or suggestions about device registration, by commenting on below or through App Center by clicking on the blue chat button in the lower-right corner of every App Center page.