SecurityException: Strong name validation failed. (Exception from HRESULT: 0x8013141A)
Closed this issue · 6 comments
I'm getting the following when trying to use this...
System.IO.FileLoadException
HResult=0x8013141A
Message=Could not load file or assembly 'AutoUpdater.NET, Version=1.9.1.0, Culture=neutral, PublicKeyToken=501435c91b35f4bc' or one of its dependencies. Strong name validation failed. (Exception from HRESULT: 0x8013141A)
Are you using a NuGet package? Is it possible to provide a sample project that can replicate this?
If you check on the command-line wit
sn.exe -v AutoUpdater.NET.dll
you receive the error message that the assembly does not have a valid strong name.
The strange thing is, that the assembly is signed, but somehow it's not a valid signature.
In scenarios, where your main application has a strong name, it requires the same from all dependencies.
The strong name worked up to 1.8.6 but is broken since 1.9.0 (and 1.9.1).
I use the version from nuget
A workaround is to use IL-Repack to re-apply a different strong name signature.
The assembly has a strong name. But it seems to be not valid. Have you cross checked with sn.exe?
Yes, you are right. It shows valid for 1.8.6 but invalid for 1.9.1. I also noticed that it is missing the satellite assemblies too. Build is created by appveyor.yml. I will investigate it further.
Issue with satellite assemblies and signature failure was connected. I accidentally allowed Resource.Embedder package to embed satellite assemblies in .NET Core assemblies too, and it messed up the signature. Can you try the new NuGet package from here?
