StrongNameDiff

System.Net.Security.CAS

Represents a difference between two strong-named assemblies. This class is part of the .NET security model, specifically related to Code Access Security (CAS) and assembly identity. It is used internally by the .NET Framework for comparing assembly versions and strong names, particularly in scenarios involving policy evaluation and authorization.

Summary

The StrongNameDiff class provides a way to programmatically determine the differences between two strong-named assemblies. This is crucial for security operations where assemblies need to be verified against predefined policies or compared for compatibility and identity.

Syntax

C#
public sealed class StrongNameDiff : System.Object
Visual Basic
Public NotInheritable Class StrongNameDiff
Inherits System.Object

Remarks

The StrongNameDiff class is not typically used directly by application developers. It is primarily an internal component of the .NET Framework's security infrastructure. When the .NET runtime loads an assembly, it performs various checks, including strong name validation. If differences are detected between the assembly's strong name and expected values (e.g., from a policy file or a previously loaded assembly), classes like StrongNameDiff might be used internally to categorize and report these discrepancies.

Understanding this class can be beneficial for developers working with advanced security configurations, reflection, or security-aware code analysis tools. It highlights the granular level at which the .NET Framework manages and verifies assembly identities.

Inheritance Hierarchy

Thread Safety

Public static members of this type are thread-safe. Any instance members are not guaranteed to be thread-safe.

Requirements

Namespace

System.Net.Security.CAS

Assembly

System.dll

See Also