Code signing error in Xcode 8 - ios

I want to run my app on my device instead of on the simulator, but every time I try to run it, I get a code signing error:
'AppName' requires a provisioning profile. Select a provisioning profile for the "Debug" build configuration in the project editor.
Code signing is required for product type 'Application' in SDK 'iOS 10.0'
I added a provisioning profile to the build settings under 'Code signing' but I still keep getting this error. Is there something wrong with my provisioning profile or am I looking in the wrong place? By the way, I used this provisioning profile on the previous version of Xcode and never ran into any problems.

To fix it, I set > TARGETS > General tab > Signing > Automatically manage signing = CHECK MARK

I had a similar problem and it was because my iPhone Developer certificate had expired. You can check this with the Keychain Access app in Utilities.

Related

How to fix code signing error in Xcode 11?

I keep getting this error. I tried everything.
Code Signing Warning: "OSCSender - App" isn't code signed but requires entitlements. It is not possible to add entitlements to a binary without signing it.
Code Signing Error: Code signing is required for product type 'Application' in SDK 'iOS 13.2'
Code signing is required for product type 'Application' in SDK 'iOS 10.0' - StickerPackExtension requires a development team error
An empty identity is not valid when signing a binary for the product type 'Application' in xcode version 10.2
I also tried to switch from the new build system to legacy. I have turned on/off automatic signing.
I deleted all provisioning profiles, certificates and my account from Xcode. still the same problem!
I tried to turn off code signing from the .plist but it doesn't let me, even when I run as admin.
Catalina 10.15.2
Xcode Version 11.3
It happens when Xcode doesn't recognize your certificate.
It's just a pain in the ass to solve it, there are a lot of possibilities to help you.
But the first thing you should try is removing in the "Window" tab => Organizer, the provisioning that is in your device. Then re-add them (download them again on the apple website). And try to compile again.
By the way, did you check in the Project Info Window the "code signing identity"?

Error when archiving iOS application swift

I am trying to upload my app to the app store, but when I archive the app, I get an error saying, "No non–expired provisioning profiles were found.
Xcode can attempt to fix this issue". It gives me an option to fix the issue, and when I press it, I get another error saying, "Unable to create a provisioning profile because your team has no devices registered in the Member Center. Please connect a device, enable it for development, and add it to the Member Center using the Organizer." And an error saying, "codeSign Error: code signing is required for product type "Application in SDK "iOS 8.4". What is causing this? How do I fix it?
to fix this
codeSign Error: code signing is required for product type "Application in SDK "iOS 8.4
open Build Settings of your target => Code Signing
then change "Don't Code Sign" to yours for "Code Signing Identity" row
You either could generate a provision profile by yourself in your developer account on developer.apple.com. After you need to download it and say to the xcode to use it (Build Settings => Code Signing => Provision Profile, if the xcode doesn't see the downloaded provision have to add it to ~/Library/MobileDevice/Provisioning Profiles/ folder). After all try to restart the xcode, clean up the last build and build all over again.

No matching provisioning profiles found for WatchKit extension when submitting to App Store

I'm using xcode 6.3
xcode had created a provisioning profile "xxx.xxx.xxx.watchkitextension" automatically, in the code signing of watchkit extension target, I've tried choosing this profile or leaving it Automatic, they all giving me this error "Failed to locate or generate matching signing assets" when I submit it to App Store.
Any ideas? thanks.
This problem looks similar to this question.
Submit WatchKit Provisioning Error
I had the same problem. Here is the solution that worked for me.
Technical Q&A QA1830 The beta-reports-active Entitlement Q: How do I resolve the "beta-reports-active" code signing error? https://developer.apple.com/library/ios/qa/qa1830/_index.html
I had to regenerate the "Distribution" Provisioning Profile that I was using to submit my entire app, before I included the WatchKit extension. Specifically, these steps fixed my problem:
I logged onto developer.apple.com, selected "Certificates, Identifiers & Profiles".
On the Certs IDs & Profiles website > Provisioning Profiles page, click the App Store profile.
Click 'Edit'
Click 'Generate'
Following steps help me out:
1.Make sure "App Groups" in Capabilities page in Container target and Extension target.
2.Goto Xcode > Preferences > Accounts > YOUR_ACCOUNT > View Details ..., CTRL+Click one of the Profiles and open in Finder. Move all Profiles to Trash.
3.Open "App Groups" in Container target and Extension target. Xcode will generate two profiles for you, just like iOSTeam Provisioning Profile: YOURAPPID and iOSTeam Provisioning Profile: YOURAPPID.watchkitextension.
(Make sure your container target and WatchKit App target choose the first one as PP,and your extension target choose the second one).
4.If everything goes well, you can do whatever build, run and submit.
I needed to revoke my certificates (preferences -> accounts). After that XCode offered to recreate them. All fine now. Not sure whether this has unwanted side effects as previous certificates are now invalid.
I had the same error message trying to submit an update to a Watch App that was previously rejected. Since i had previously uploaded, I did not see this error. I used a support incident to get help after exhausting all paths.
I got a response in just 1 or 2 business days -- which at first annoyed me. They said i needed to reset everything to use "team provisioning profiles" and all would be fine. I am an individual developer, so my "team profile" is just mine... but I did walk through all the steps and ta-da, much to my surprise, everything worked and the errors went away. Nothing really to do with any of the application specific or other provisioning profiles i had -- i must have changed a "signing identity" somewhere so Xcode's automatic resolution / fix up did not work.
Apple's message was:
CONVERTING TO TEAM BASED CODE SIGNING
Team-based signing should be used in Xcode 5 and later: it’s the recommended workflow and is what’s covered in App Distribution Guide. Team based code signing requires resetting of all code signing settings in each targets build settings to their defaults. Xcode will no longer use the Code Signing Identity and Provisioning Profile build settings, but instead choose the best combination of signing identities and provisioning profile for the scheme being built.
Technical Q&A QA1814 - Setting up Xcode to automatically manage your provisioning profiles
Which is quite clear and solved all my problems.

CodeSign error: code signing is required for product type 'Application' in SDK 'iOS 6.1'

I know this has been asked before.
However, I have ensured that the profile is in BOTH the project and target.
Actually should I set that up in the project or in target?
Update: I can actually install the app on device but if and only if I change the code signing identity to iPhone Developer for debug.
However, I obviously want to launch the application with my distribution profile instead of my developer profile.
I finally got this thing solved.
Basically I deleted all certificate and provisioning profile from itunes connect or apple developer website.
Then I waited 5 minutes. Add 2 distribution provisioning profile. Then do it again.
It works.
Oh ya, I need to ensure that the code signing identity points to the right provisioning profile. That's it.
Make your deployment target less than 6.1. It will work
In my case, I didn't set the Scheme correctly. Newbies can forget this sometimes.
Go to: Product -> Scheme -> Edit Scheme
Select Archive and make sure that the Build Configuration has desired value Debug/Release (as compared to target settings)

Code Signing Identity in XCode 4.5

I get this message when I start a build to my device in Xcode;
Code Sign error: A valid provisioning profile matching the application's Identifier 'vindfyrar2' could not be found
I've been through all the certificate/provisioning profile verification process.
I have valid provisionings profiles installed on my device in xcode organizer.
What I think is my problem is that I can't see any provisioning profiles in the target or project build settings -> code signing identity.
Take a look at the pictures below please!
Anyone please have some time to help me?
Whenever I encounter this problem, I find that restarting Xcode and selecting a different provisioning profile in your project (not target) build settings will cause the list to refresh. If you see no profiles anywhere, download them again from your apple developer center and drag them into the Organizer's Provisioning Profiles pane.
In the project build settings, set the Code Signing Identity to Automatic Profile Selector (iPhone Developer). Now check that Code Signing menu again, it should say "(currently matches: iPhone Developer: Jan Gifvars (xxxx) in 'iOS Team Provisioning Profile:*)". If it doesn't, you need to make sure you've got proper private key, certificate, and provisioning profiles. Follow ALL the steps in this tech note.
https://developer.apple.com/legacy/library/technotes/tn2250/_index.html

Resources