| November
23rd 2005
Strong
Names for Assemblies
Part of the security
model for .NET involves signing assemblies with strong names using
a public/private key. Whilst appearing reasonably straightforward
("just" add a few lines to the AssemblyInfo file) - beware - it gets
more complicated!
An assembly that
is signed requires all the assemblies it uses to be so too. And if
these are COM wrappers then they need signing!
For C# this is
actually not difficult - a property of the project can be set (Wrapper
Assembly Key File) and it's done. But for VB no such property exists.
The only way is to sign/strong name each DLL - which means generating
from a type library. Command line tools are required at this point,
and if you don't have the TLB to work from it gets more difficult.
One approach we
took was to use "The Regulator" and copy the source code (in C#)
into a DLL of our own - and strong name that!
No doubt VS2005
fixes this but we're not in a position to upgrade...
|