The advantages that strong named assemblies have:
1) The assembly name has uniqueness and so it can be deployed outside of the AppBase
2) The Assembly Loader can detect tampering with the assembly
3) Versioning now is taken notice of
1) and 2) are only reliable if you have a process for key management. Most specifically if your proiate key becomes known then kiss goodbye to the guarantee of 2) and partially of 1), someone can spoof your assembly with their own and change your assembly and re-sign it. I say partially for 1) because if you are only interested in preventing *accidental* collision of assembly names then private key management isn't an issue.
Point 3) may actually be a problem rather than a benefit. You cannot pass types from one version of an assembly in place of types from another version - if this is a scenario you think may occur with your application (more than one version of it loaded into an AppDomain and types used from one version where another is expected) then you may really prefer the CLR to igmore the version. One wau round this is to keep your version number the same on your assembly, but then how do you tell which version of an assembly soneome is using? If You don't strong name then unless the applkication uses Assembly.LoadFrom it will always pick up a single version.
The other issue with strong named assemblies is that, by default, they cannot be called from partially trusted code. To allow this you have to apply the [AllowPartiallyTrustedCallers] attribute to your assembly and this should never be done lightly. Its possible to open up gaping security holes by mistake this way.
So for no-touch deployment applications (which often run in a partially trusted environment) strong naming can be an problem not a benefit.
Regards
Richard Blewett - DevelopMentor
http://staff.develop.com/richardb/weblog
nntp://news.microsoft.com/microsoft.public.dotnet.framework/<
[email protected]>
If strong-named assemblies have so many advantages, why not sign all
assemblies with strong-name. Is there any scenario, where an assembly should
not be signed with strong-name?
---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (
http://www.grisoft.com).
Version: 6.0.766 / Virus Database: 513 - Release Date: 17/09/2004
[microsoft.public.dotnet.framework]