Comments (13)
Sorry yes the error is when we upload to the store:
ERROR ITMS-90035: Invalid Signature. A sealed resource is missing or invalid.
But it doesn't give any detail as to why the signature is invalid so what I shared was the output from codesign -vvvvvvv <Path to .app>
to identify which resource(s) the message was referring to and it seems to be the Swift .dylib
files that it isn't happy with.
from xamarin.swift.
Hey @bwalpoleuk when are you getting this error? I assumed it was from App Store when upload, but the path says /Users/Me/Downloads/Payload/MyApp.Touch.app/.
from xamarin.swift.
@bwalpoleuk
I think I had this error once or a twice but I am not 100% sure. Replying with what I remember have given me trouble uploading to AppStore. I could try to replicate it buy i'm not at the build mac ATM , I will try it tomorrow as i'm going to upload a version of my app anyway.
I think had a similar error message when I forgot to remove the SwiftFrameworksSimulator folder or I signed the archive before removing said folder but I can not remember 100%
from xamarin.swift.
@Flash3001 Great thanks, at least I'm not the only one to see the issue. I can't see the SwiftFrameworksSimulator in the .app
, would any potential signing issue be caused by the order of the targets in the .csproj
or something like that?
from xamarin.swift.
@bwalpoleuk there was an issue related to the order of execution on the .csproj that was causing the SwiftFrameworksSimualdor folder not to be removed. It was related to using PackageReference. You can see more about that here Flash3001/iOSCharts.Xamarin#47 (comment). The script was updated to fix this issue, but I don't think this is what is causing your upload errors.
So if you are using https://www.nuget.org/packages/Xamarin.Swift4/ version 4.0.0.1 and its targets run before the basic Xamarin.iOS targets a lot can get wrong (reason on the comment I mentioned before). On version 4.0.0.2 the order shouldn't matter anymore, but there is a report on #25 about it not working as expect (didn't identify the issue yet).
That kind of issue you see when checking with the codesign happens because your APP was modified after it was signed.
Please check the following:
- What is the Xamarin.Swift4 (or 3) version you are using? 4.0.0.1 or 4.0.0.2?
- Run the codesign using codesign -dv PATH. It will return the TeamIdentifier, this way we can know if it was signed. Here is an example of one of mine:
Identifier=com.apple.dt.runtime.swiftCoreAudio
Format=Mach-O universal (armv7 armv7s arm64)
CodeDirectory v=20400 size=1863 flags=0x0(none) hashes=52+2 location=embedded
Signature size=4860
Signed Time=20 Mar 2019 23:40:23
Info.plist entries=5
TeamIdentifier=MY_TEAM
Sealed Resources=none
Internal requirements count=1 size=232
Let's try a few the following to see if we can get more clues on what is going on:
- Build your app using the Archive for Publishing from VS4M then press
Sign and Distribute -> App Store
. Check the codesign for this build.
One thing from your error logs that caught my attention is that on the first line it says Payload/MyApp.Touch.app/: a sealed resource is missing or invalid file modified
I had several issues with invalid codesigns during the initial development for this project, if I am not mistaken it was happening because I had all the device dylibs in a separated folder. They were signed in there and then moved to the final destination. It was some time ago so I might have confused myself haha.
from xamarin.swift.
@Flash3001 We are using 4.0.0.2 of the Swift 4 libraries.
If I build and archive locally via VS4M then the code signing appears to be valid, below is the output from codesign -dv PATH
for the two builds.
Valid code signature:
Identifier=co.uk.myapp
Format=app bundle with Mach-O universal (armv7 arm64)
CodeDirectory v=20400 size=233664 flags=0x0(none) hashes=7293+5 location=embedded
Signature size=4792
Signed Time=21 Mar 2019 at 08:28:35
Info.plist entries=37
TeamIdentifier=MY_TEAM
Sealed Resources version=2 rules=13 files=491
Internal requirements count=1 size=188
Invalid code signature:
Identifier=co.uk.myapp
Format=app bundle with Mach-O universal (armv7 arm64)
CodeDirectory v=20400 size=233504 flags=0x0(none) hashes=7288+5 location=embedded
Signature size=4792
Signed Time=18 Mar 2019 at 08:12:31
Info.plist entries=37
TeamIdentifier=MY_TEAM
Sealed Resources version=2 rules=13 files=493
Internal requirements count=1 size=188
On the face of it the only difference I can see is that the invalid build contains two more files, this seems to be the iTunesArtwork
and iTunesArtworkx2
files.
But what this does seem to show is that the issue is only happening when the app is built on AzureDevOps, we are using the standard Xamarin.iOS task to do this: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/xamarin-ios?view=azure-devops.
We do copy the .ipa
to a new location after the build so it can be published as an artefact.
from xamarin.swift.
@Flash3001 I've created a new AzureDevOps pipeline to try and investigate the issue, even if I limit this pipeline to just build the app using the standard iOS task as referenced above the code signature is invalid.
So the problem seems to be related to how AzureDevOps is doing the build, this task does build at the solution level I don't know if thats a problem?
from xamarin.swift.
@Flash3001 After a bit more investigation I've found that adding the Xamarin.Swift4 4.0.0.2
package is fine but adding any other package even Xamarin.Swift4.Core 4.2.1.1
causes the issue.
from xamarin.swift.
@bwalpoleuk this is quite interesting. I have no experience at all with AzureDevOps, but is it possible to define your Xcode version?
If you add Xamarin.Swift4.Core 4.2.1.1 or any other 4.2.1.1 package it breaks or version 4.2.1 and 4.2.0 also breaks it?
Package 4.2.1.1 was uploaded to work with Xcode 10.1 10B61. 4.2.1 is the same, but at some point Apple was (not sure if it still is) blocking the upload for apps including arm64e architecture so I had to remove it from the Swift dylibs. That is the only difference between 4.2.1.1 and 4.2.1 . If 4.2.1 is working for you try to keep it.
Can you send me a build log from a clean Release|iPhone build from AzureDevOps (using Diagnostics verbosity)? If you don't want to put in here please send it to my e-mail. I want to check if any build step is doing any change to those files that are not expected.
from xamarin.swift.
@Flash3001 You can set the Xcode version thats used in the build and we have this set to 10.1.
I've tried using 4.2.1 and 4.2.0 but I get the same result, I'll send you a build log via email.
from xamarin.swift.
@bwalpoleuk I've checked the log you've sent me and the first thing I noticed is that the only Swift runtime it is processing is libswiftCore.dylib
. If you check it you wont find any references to others like libswiftUIKit.dylib or libswiftFoundation.dylib. Can you open the generated APP file and see if they are included? That is a bit different from the codesign -vvvv
check you first sent as it indicated that those files were included.
from xamarin.swift.
from xamarin.swift.
@bwalpoleuk I was banging my head against this issue yesterday, and I have no explanation why, but downgrading Xamarin.Swift from 4.0.0.2 to 4.0.0.1 solved it. Perhaps worth a try if this is still a problem.
from xamarin.swift.
Related Issues (20)
- I Have done the swift framework binding as you explained in medium . I build binding library succesfully and give reference to my app .But when i call framework method from my app, app suddenly crash and stop.My swift framework is written in version swift v5.0.1. I added nuget xamarin.swift which is mentioed as for swift v5. But it is also not helping me from crashing. Can you guid me on this issue. HOT 7
- msbuild command line build does not add SwiftSupport folder HOT 5
- Not being able to deploy/debug on iOS versions prior to 12.2 HOT 8
- ITMS-90428: Invalid Swift Support - Payload - The files libswiftCoreGraphics.dylib, libswiftDarwin.dylib, libswiftos.dylib, libswiftQuartzCore.dylib, libswiftFoundation.dylib, libswiftMetal.dylib, libswiftCoreLocation.dylib, libswiftCoreFoundation.dylib, libswiftCoreImage.dylib, libswiftObjectiveC.dylib, libswiftUIKit.dylib, libswiftDispatch.dylib, libswiftCore.dylib donβt match with the /Payload/MyApp.app/Frameworks/ HOT 6
- ipa-packager and sh file for Swift 5.0
- Paths to swift dylibs are different in XCode 11 HOT 5
- Invalid Swift Support: `incorrect code signature` or `SwiftSupport folder is missing` HOT 3
- SwiftSupport tasks not running HOT 3
- Build targets not running. HOT 3
- TestFlight build fails at startup with `Termination Description: DYLD, dependent dylib '@rpath/libswiftCore.dylib' not found for....` HOT 2
- ITMS-90428: Invalid Swift Support -
- Xamarin.Mac support
- MSB4044: The "CheckSwiftVersionsTask" task was not given a value for the required parameter "SdkVersion" HOT 16
- Error MSB4044: The "CheckSwiftVersionsTask" task was not given a value for the required parameter "AppManifest". (MSB4044) HOT 9
- swift support broken HOT 5
- symbol '_OBJC_CLASS_$_SwiftObject' not found HOT 1
- No support for RealityKit - Between Swift and Xamarin
- Build is failed with iOS and VS2022 / Error MSB4057: The target "_CollectFrameworks" does not exist in the project HOT 6
- The "Codesign" task was not given a value for the required parameter "StampFile", nor was there a "CodesignStampFile" metadata on the resource /path/*.dylib HOT 2
- error MSB4044: The "CompileEntitlements" task was not given a value for the required parameter "AppBundleDir" HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xamarin.swift.