简体   繁体   中英

Change Signing Certificate in Xcode 8 Beta 2

I have two certificates in my keychain that I use for code signing. One is my team's production certificate that I use for signing apps for enterprise distribution. The other is my development certificate (part of the same team) that I use for signing apps for development.

In Xcode 8 I have deselected 'Automatically manage signing' and now my certificate has been set to the production certificate associated with my team, which now only allows me to sign distribution apps. I am able to change the Provisioning Profile to a development one, but then I get an error that “Provisioning profile “Development-Profile" doesn't include signing certificate “Production-Certificate”. But Xcode 8 does not allow me to change my Certificate manually.

How can I change between code signing identities within the same team in Xcode 8?

Well I immediately found the answer to my own question, of course. I assumed the old Code Signing/Provisioning Profile sections from Build Settings had been removed and replaced completely by the Signing section of the General tab in Xcode. In fact they are still there and you can use them as usual. Thought I'd answer my own question instead of deleting for everyone else who might have assumed the same!

There are 2 ways to sign application in xcode8

  1. Automatic signing -- Managed by xcode, no need to worry but this is for development signing.

  2. Manual signing: This means "uncheck auto sign option in General tab" This leads to introduction of two more sections related to signing in xcode IDE. Debug and Release configuration, here you need to specify the profile you intended to use for building your application. Here you can specify the development/distribution profile. Offcourse this is also available in the Build settings section.

In General tab you cant change code signing identity. Using xcconfig file you can override the code signing identity. You are correct, here we don't have option to set the codesigning identity. Using xcconfig file you can override the code signing identity.

PROVISIONING_PROFILE_SPECIFIER = TEAM ID/PROFILE NAME CODE_SIGN_IDENTITY[sdk=iphoneos*] = iPhone Distribution CODE_SIGN_IDENTITY[sdk=watchos*] = iPhone Distribution

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM