Bug 42932 - Visual Studio - error: No installed provisioning profiles match the installed iOS code signing keys
Summary: Visual Studio - error: No installed provisioning profiles match the installed...
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: iOS ()
Version: 4.1.1 (C7SR0)
Hardware: PC Mac OS
: High normal
Target Milestone: 4.3.0 (C9)
Assignee: Adrian Alonso
Depends on:
Reported: 2016-07-29 19:41 UTC by Michael
Modified: 2018-01-31 00:13 UTC (History)
11 users (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Michael 2016-07-29 19:41:16 UTC
I am having a real problem when attempting to build and deploy an Adhoc profile using Visual Studio. When I attempt to build and reply an Adhoc build it fails with the following error

No installed provisioning profiles match the installed iOS code signing keys

If I generate a new iOS distribution certificate, then create a new provisioning profile whence referencing the certificate and the device I am replying to, it will work the first time I  attempt to build and deploy the app to the device.

Every time after the first time it fails with the error. This also is not working with the Visual Studio Team Services build agent. So this is a serious issue.

It works OK in Xamarin Studio.

Environment Detailed below

Visual Studio 2015 Update 3 v14.0.25424.00 with
Xamarin Android
Xamarin iOS

Xamarin Studio
=== Xamarin Studio Community ===

Version 6.0.1 (build 8)
Installation UUID: c0a4c8dc-0061-4b22-a3ad-b4e6bc68b1db
Mono 4.4.1 (mono-4.4.0-branch-c7sr0/4747417) (64-bit)
GTK+ 2.24.23 (Raleigh theme)

Package version: 404010000
=== Xamarin.Profiler ===

Version: 0.31.0
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

=== Xamarin.Android ===

Version: (Xamarin Studio Community)
Android SDK: /Users/Username/Library/Developer/Xamarin/android-sdk-macosx
Supported Android versions:
2.3 (API level 10)
4.0.3 (API level 15)
4.4 (API level 19)
5.0 (API level 21)
6.0 (API level 23)

SDK Tools Version: 24.4.1
SDK Platform Tools Version: 23.0.1
SDK Build Tools Version: 23.0.1

Java SDK: /usr
java version "1.8.0_101"
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode)

Android Designer EPL code available here:

=== Xamarin Android Player ===

Not Installed

=== Apple Developer Tools ===

Xcode 7.3.1 (10188.1)
Build 7D1014

=== Xamarin.Mac ===

Version: (Xamarin Studio Community)

=== Xamarin.iOS ===

Version: (Xamarin Studio Community)
Hash: 3cf8aae
Branch: c7sr0
Build date: 2016-06-20 16:09:58-0400

=== Build Information ===

Release ID: 600010008
Git revision: 0ecc3639cde21616d675e4fdef1b858d166dd065
Build date: 2016-06-20 13:16:51-04
Xamarin addins: a9252e6df4851fbbed1f9c6228e7b6dd1b475ac5
Build lane: monodevelop-lion-cycle7-sr0

=== Operating System ===

Mac OS X 10.11.5
Darwin W013208-MAC 15.5.0 Darwin Kernel Version 15.5.0
Tue Apr 19 18:36:36 PDT 2016
root:xnu-3248.50.21~8/RELEASE_X86_64 x86_64

Which operating system version and device: 
iOS targetting 9.0.0
Device running 9.2.1
Mac OS X El Capitan
Windows 7
Comment 1 Emanuel 2016-08-25 18:28:28 UTC
Hi @Michael, thanks for reporting!

I could not reproduce this issue so I'll need some info from your side:
- Could you attach your build output?
- Is your AdHoc distribution profile listed in the iOS Bundle Signing properties page?
- Are you explicitly selecting the identity and provisioning profile or just living these fields as Automatic?
- When Xamarin for Visual Studio starts to fail, are you still able to build from Xamarin Studio?

Thanks for your help!
Comment 2 Michael 2016-08-25 18:59:30 UTC
1. I will attempt to get the build output to you soon, I am in the middle of other work at the moment

2. Yes the adhoc distribution profile is listed in the bundle signing properties

3. I am explicitly selecting these

4. Yes Xamarin studio worked perfectly
Comment 3 david 2016-10-13 00:59:01 UTC
Just on the off-chance: can you check your .csproj file in a text editor? I had this error when all my profiles were apparently correct, and there was a duplicate <CodesignProvision> key in the csproj file for the iOS project.

I don't know if the IDE put the duplicate there, or our version control system did it.

Either way, removing the duplicate fixed the problem.

Comment 4 Michael 2016-10-13 13:42:01 UTC
No, there is only one <CodesignProvision> element per build profile
Comment 5 Adrian Alonso 2016-12-22 19:02:28 UTC
Michael, are you still experimenting this issue? Thanks, Adrian
Comment 6 Jose Gallardo 2016-12-23 02:54:29 UTC
As we've added several improvements to our build system and deploying/debugging mechanism since the bug was reported, I'm resolving it tentatively as Fixed.
That said, if you're still facing this issue with current bits, please feel free to reopen the bug.
Comment 7 Danish Akhtar 2016-12-23 06:39:55 UTC
I have checked this issue with latest C9 builds XVS + X.iOS and I am successfully able to build and deploy iOS application in Adhoc mode using VS.

As of now I am closing this issue, Please feel free to Reopen it, if you will encounter this issue again with latest builds.

Comment 8 Samiya A 2018-01-31 00:13:24 UTC
I'm experiencing the exact same issue, even on Xamarin studio, though previously it used to work just fine. I've made sure my provisioning profiles are selected correctly (also in the csproj file), the profiles are valid and the certificates are valid too. Can anyone help? Please reopen this issue