This documentation is archived and is not being maintained.

StrongNameMembershipCondition Constructor

Initializes a new instance of the StrongNameMembershipCondition class with the strong name public key blob, name, and version number that determine membership.

[Visual Basic]
Public Sub New( _
   ByVal blob As StrongNamePublicKeyBlob, _
   ByVal name As String, _
   ByVal version As Version _
)
[C#]
public StrongNameMembershipCondition(
   StrongNamePublicKeyBlob blob,
 string name,
 Version version
);
[C++]
public: StrongNameMembershipCondition(
   StrongNamePublicKeyBlob* blob,
 String* name,
 Version* version
);
[JScript]
public function StrongNameMembershipCondition(
   blob : StrongNamePublicKeyBlob,
 name : String,
 version : Version
);

Parameters

blob
The strong name public key blob of the software publisher.
name
The simple name section of the strong name.
version
The version number of the strong name.

Exceptions

Exception Type Condition
ArgumentNullException The blob parameter is a null reference (Nothing in Visual Basic).

Remarks

Strong names are well suited to specifying code assemblies to which you give a rich set of powerful permissions. Since strong names are cryptographically verified, attackers cannot impersonate rightful assemblies and use their permissions.The name and version parameters are optional. For example, you can create a StrongNameMembershipCondition that checks for PublicKey and Name (but not Version) by passing a null reference (Nothing in Visual Basic) into the version parameter.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

StrongNameMembershipCondition Class | StrongNameMembershipCondition Members | System.Security.Policy Namespace

Show: