DeclarativeSecurityAction DeclarativeSecurityAction DeclarativeSecurityAction DeclarativeSecurityAction Enum


Specifies the security actions that can be performed using declarative security.

public enum class DeclarativeSecurityAction
public enum DeclarativeSecurityAction
type DeclarativeSecurityAction = 
Public Enum DeclarativeSecurityAction


Assert Assert Assert Assert 3

The calling code can access the resource identified by the current permission object, even if callers higher in the stack have not been granted permission to access the resource.

Demand Demand Demand Demand 2

Check that all callers in the call chain have been granted the specified permission.

Deny Deny Deny Deny 4

Without further checks refuse Demand for the specified permission.

InheritanceDemand InheritanceDemand InheritanceDemand InheritanceDemand 7

The derived class inheriting the class or overriding a method is required to have the specified permission.

LinkDemand LinkDemand LinkDemand LinkDemand 6

Check that the immediate caller has been granted the specified permission.

None None None None 0

No declarative security action.

PermitOnly PermitOnly PermitOnly PermitOnly 5

Without further checks, refuse the demand for all permissions other than those specified.

RequestMinimum RequestMinimum RequestMinimum RequestMinimum 8

Request the minimum permissions required for code to run. This action can only be used within the scope of the assembly.

RequestOptional RequestOptional RequestOptional RequestOptional 9

Request additional permissions that are optional (not required to run). This request implicitly refuses all other permissions not specifically requested. This action can only be used within the scope of the assembly.

RequestRefuse RequestRefuse RequestRefuse RequestRefuse 10

Request that permissions that might be misused not be granted to the calling code. This action can only be used within the scope of the assembly.

Applies to