iOS

How to generate xcarchive for enterprise deployment

Abilash Balasubramanian

17 May 2018

generate xcarchive for enterprise deployment

Are you confused of generating xcarchive file without team admin access for enterprise deployment?

xCxOMFpCO5PEjKYNvDkn 9vyWErZylWk2qh QKSRk5Y0NWt6zKkqGbrO5txKWT9 UZgNhiaIoVkK8vPEzxXZXJ8L7 ZN1VJhP8

No issue, below are the step by steps procedure and instructions that will guide you to generate successful xcarchive for enterprise deployment.

Overview of iOS app signing

To install an iOS app on a physical device, you need to sign the app with a personal/enterprise team, developer, or enterprise certificate provided by Apple and properly configure a provisioning profile for the device. Provisioning makes it possible for testers to launch the app on a device. An actual code signing process flow diagram is shown in below figure.

 

PCRgS2XUCt2hFJStwDr5fNg5SzC4BoT3D9 21uvIx8mNsP6zobU DI hfjNuJBxhgKJF6FZ0xJjOrb32us

 

Developer certificate creation:

For creating developer certificate, first, log in to https://developer.apple.com using your developer apple account.

Note: Make sure you have selected right developer enterprise team before proceeding further.

Select Certificates, IDs and Profiles section available on the left panel. Then click add new certificate option to navigate to Certification creation page shown in Figure 1.

Figure 1

Above figure listed only iOS App Development certificate,  because your developer account is provided with development access from the Enterprise team.

Create a CSR file.

Launch Keychain Access app, within the Keychain Access, select Keychain Access > Certificate Assistant > Request a Certificate from a Certificate Authority.

  • In the Certificate Information window, enter the following email information and select the “Saved to disk” option.

  • Click Continue within Keychain Access to complete the CSR generating process.

When your CSR file is created, a public and private key pair are automatically generated. Your private key is stored on your computer.

Upload your CSR file to generate developer certificate.

Once a certificate is created successfully, click download option and store it locally.

Certificate validation:

How to validate my developer certificate which created from the enterprise team?

You have to inform the enterprise team-admin about the developer certificate along with necessary certificate details,

Certificate details required for validations,

Name,

Type,

Expires,

Created By

Enterprise team is supposed to provide you with the necessary provisional profile which supports your app bundle ID and developer certificate.

Download and use the provisional profile manually,

(Or)

Go to xcode preference > select developer account > team > Download all profiles.

Generate Xcarchive file:

System requirements

Code signing:

  • Change the Bundle Identifier to an appropriate name, it’s best to choose a bundle identifier name that corresponds with your developer account because you can’t use an already registered name.

  • Under the Signing heading, select “Automatically manage signing,” and then confirm by selecting “Enable Automatic” or select “Manual manage signing” and then select appropriate provisioning profile available on your MAC for respective bundle ID.

Before proceeding archive process, make sure you have selected Generic iOS device option as a destination.

Product > Archive option. Choose them and proceed to generate *.xcarchive file, shown in figure 2

 PpeyvKvVGbZ0nK3n3Jp5YVGV4xNGEtrhQqdZst Rie94w360J4OYq7okMnBTZvRdWgqOJkA6xH oc4ouFiU9jXGotZikXKbdhmVyT553m3rOH1ZSILSQMCd18KOOFoCPUUQ59ujs

Figure 2

Navigating to respective xcarchive file:

Once after successful archive process, from organizer window Right click to your archived app > show in finder. Shown in figure 3 & 4.

fQoEgTP2OeGtEMqCxC4JdimI8SEla3cDv Bbd2KenblrLhh862sVd1VERKrsCmVlA1ODg7xqLjD0 bNXm2xOSRX2YuBYuViEltXaweCZtdFZnyrHY 0wcDDUwyfuZSeC0BVgPuy2

Figure 3

LOBqRH9dVlNd1K4MYP6REuWQFqXDaxQJ2U8llF7v ABiwB5E3jbJXai1cDA5I51rHV1w24nWU4XCYjzxbeT4rN00 UwlV Nn2FdXEt EzjQ8d8yNE51Yv4j29zUEwmuTgsM8pfCb

Figure 4

Yeah hoo!!! Now, you have successfully created xcarchive file for your app which can be used for enterprise deployment.

References:

i.https://docs.telerik.com/platform/appbuilder/cordova/code-signing-your-app/configuring-code-signing-for-ios-apps/create-development-certificate

ii. https://www.nowsecure.com/blog/2016/11/15/xcode-export-app-security-testing/

iii.https://doc.owncloud.org/branded_clients/branded_ios_app/publishing_ios_app_2.html