Name

PolicyStatementAttribute

Synopsis

public enum PolicyStatementAttribute {
   Nothing = 0x00000000,Exclusive = 0x00000001,LevelFinal = 0x00000002,All = 0x00000003
}

The PolicyStatementAttribute enumeration is used in conjunction with the PolicyStatement class. PolicyStatementAttribute contains values that are assigned to the PolicyStatement.Attributes property to define a code group’s attributes. Code group attributes affect the policy resolution process by controlling how the permissions granted by one code group are merged with the permissions granted by other code groups.

The Exclusive value specifies that the permissions granted by the code group are the maximum set of permissions that a group member can receive from the current policy level. Because the permissions granted by each policy level intersect to determine the final grant set, a code group with the Exclusive attribute actually defines the maximum set of permissions in the final grant set. An assembly or application domain can be a member of at most one Exclusive code group per policy level, or the runtime throws a PolicyException.

Policy levels are resolved in the order enterprise, machine, user, and finally application domain. The LevelFinal value specifies that no policy levels below the current level will be evaluated. If resolving the permissions for an assembly, the runtime always evaluates the application domain policy regardless of whether the assembly is the member of a LevelFinal code group.

PolicyStatementAttribute ...

Get Programming .NET Security now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.