Bug 34219 - IPA signing fails for Ad-Hoc build using xbuild from the command line if "Include iTunes artwork" is selected.
Summary: IPA signing fails for Ad-Hoc build using xbuild from the command line if "Inc...
Status: RESOLVED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: MSBuild ()
Version: XI 8.10
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Jeffrey Stedfast
URL:
Depends on:
Blocks:
 
Reported: 2015-09-23 17:20 UTC by Jon Goldberger [MSFT]
Modified: 2015-09-24 11:47 UTC (History)
2 users (show)

Tags:
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 or GitHub 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:
Status:
RESOLVED FIXED

Description Jon Goldberger [MSFT] 2015-09-23 17:20:38 UTC
## Description

When building and Ad-Hoc IPA from the command line with xbuild code signing fails and the following error is received in the device install log:

>Sep 23 08:21:07 Gregs-iPhone installd[37] <Error>: resource added: /private/var/mobile/Library/Caches/com.apple.mobile.installd.staging/temp.9QcWvV/extracted/Payload/FieldReports.app/iTunesMetadata.plist
>Sep 23 08:21:07 Gregs-iPhone installd[37] <Error>: 0x1e1f000 -[MICodeSigningVerifier performValidationWithError:]: 192: Failed to verify code signature of <MIExecutableBundle : path = /private/var/mobile/Library/Caches/com.apple.mobile.installd.staging/temp.9QcWvV/extracted/Payload/FieldReports.app identifier = com.newforma.ios.enterprise.fieldreports type = User App> : 0xe8008017 (Signed resources have been added, removed, or modified)
>Sep 23 08:21:07 Gregs-iPhone installd[37] <Error>: 0x1e1f000 -[MIInstaller performInstallationWithError:]: Verification stage failed
>Sep 23 08:21:07 Gregs-iPhone itunesstored[86] <Error>: 0x703000 __MobileInstallationInstallForLaunchServices_block_invoke240: Returned error Error Domain=MIInstallerErrorDomain Code=13 "Failed to verify code signature of <MIExecutableBundle : path = /private/var/mobile/Library/Caches/com.apple.mobile.installd.staging/temp.9QcWvV/extracted/Payload/FieldReports.app identifier = com.newforma.ios.enterprise.fieldreports type = User App> : 0xe8008017 (Signed resources have been added, removed, or modified)" UserInfo=0x1476efe0 {LibMISErrorNumber=-402620393, LegacyErrorString=ApplicationVerificationFailed, FunctionName=-[MICodeSigningVerifier performValidationWithError:], NSLocalizedDescription=Failed to verify code signature of <MIExecutableBundle : path = /private/var/mobile/Library/Caches/com.apple.mobile.installd.staging/temp.9QcWvV/extracted/Payload/FieldReports.app identifier = com.newforma.ios.enterprise.fieldreports type = User App> : 0xe8008017 (Signed resources have been added, removed, or modified), SourceFileLine=192}
>Sep 23 08:21:07 Gregs-iPhone itunesstored[86] <Warning>: ERROR: MobileInstallationInstallForLaunchServices returned nil
>Sep 23 08:21:07 Gregs-iPhone lsd[76] <Warning>: LaunchServices: installation failed for app com.newforma.ios.enterprise.fieldreports

This led me to this post:
http://support.hockeyapp.net/discussions/problems/31488-enterprise-distribution-always-fails-with-failed-to-verify-code-signature

and the suggestion to disable the ""Include iTunes artwork" option. It seems that including the iTunes artwork step is performed after the code signing, causing the above error. I am not sure if this is something we can change or not, or even it is needed since iTunes Artwork is generally not needed for Ad-Hoc builds, but filing this report just in case.
Comment 1 Jeffrey Stedfast 2015-09-24 11:47:31 UTC
This is already fixed in cycle6, master, etc.