I am writing a Visual Studio 2012 extension, for internal use, which requires that all assemblies have a strong name. I am dependent on RestSharp (and a few other dlls), and since it is not strongly named, I am adding a strong name to it by following this. Everything works according to the output of the process, and even visual studio claims it is strongly named if I look at the properties of RestSharp.dll in the project references. However, when I go to use my extension I get a FileLoadException claiming:
Could not load file or assembly 'RestSharp, Version=104.1.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. A strongly-named assembly is required. (Exception from HRESULT: 0x80131044)
Any thoughts on how to resolve this or work around it?
PublicKeyToken=null
, it's looking for an unsigned version of the assembly. I would remove all of your references to RestSharp, and re-add them to the signed assembly. – SelfinsuranceDoes the project reference actually have to be signed?
yes. Signing it after the fact is not good enough. The assembly manifest for your assembly that references RestSharp keeps track of the fully qualified assembly name, including the strong name (or absence of one). – Selfinsurance