-
Notifications
You must be signed in to change notification settings - Fork 514
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Strong name and InternalsVisibleTo crash on device (works on emulator) #4895
Comments
* Works around iOS issue: xamarin/xamarin-macios#4895
Hi, I was able to confirm the issue with the attached test case. Could be a signing issue. Full build logs: https://gist.github.com/VincentDondain/6d6ae0a19baf12c6b4c600c5bc84928a |
@VincentDondain Thanks for taking a look. As we can't rely on a fix from your end to unlock our users, I've worked around it (luckily, since the Future label scares me :)) by removing any dependency to internals and removing the That means this issue is no longer blocking us. |
It's not related to simulator or device builds. Enabling the linker on simulator builds trigger the same runtime exception. That's likely because of .netstandard which force us to update the references (and not ship all facades) in assemblies - which would break the signature. However mono did not, historically, check signatures at runtime. @luhenry has mono changed its runtime checks wrt |
hmm... maybe not (mono)
|
Workaround: Put a space before
instead of
Unlike most other assembly data being processed this value is a string, and not pre-parsed, metadata reference. As such the formatting is not guaranteed. This also explains why this is working in so many other cases (and tests that we have). |
The input is a "user" string, i.e. not some well formatted metadata. Spec [1] mention it's comma separated, but spaces are optional. [1] https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/specifying-fully-qualified-type-names#specifying-assembly-names Fixes xamarin#4895
The input is a "user" string, i.e. not some well formatted metadata. Spec [1] mention it's comma separated, but spaces are optional. [1] https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/specifying-fully-qualified-type-names#specifying-assembly-names Fixes #4895
The input is a "user" string, i.e. not some well formatted metadata. Spec [1] mention it's comma separated, but spaces are optional. [1] https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/specifying-fully-qualified-type-names#specifying-assembly-names Fixes #4895
The input is a "user" string, i.e. not some well formatted metadata. Spec [1] mention it's comma separated, but spaces are optional. [1] https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/specifying-fully-qualified-type-names#specifying-assembly-names Fixes #4895
The input is a "user" string, i.e. not some well formatted metadata. Spec [1] mention it's comma separated, but spaces are optional. [1] https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/specifying-fully-qualified-type-names#specifying-assembly-names Fixes #4895
The input is a "user" string, i.e. not some well formatted metadata. Spec [1] mention it's comma separated, but spaces are optional. [1] https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/specifying-fully-qualified-type-names#specifying-assembly-names Fixes #4895
This issue happens when using the Sentry SDK with Xamarin.iOS. All the assemblies that comprise that SDK are strong named and the
Protocol
package exposes internals to theSentry
package.I've created a small reproducible app.
Steps to Reproduce
It works with the iOS emulators and with Android devices.
Expected Behavior
App starts
Actual Behavior
App crashes
Environment
Build Logs
App builds and deploys to the device, the crash is:
Example Project (If Possible)
https://github.com/bruno-garcia/repro-xamarin-ios-strong-name-internalsvisibleto
Branch work/removed-strong-naming had the strong name removed and the app starts normally.
The text was updated successfully, but these errors were encountered: