<generatePublisherEvidence> Element

 

Specifies whether the runtime creates Publisher evidence for code access security (CAS).

<configuration>
<runtime>
<generatePublisherEvidence>

<generatePublisherEvidence    
   enabled="true|false"/>  

The following sections describe attributes, child elements, and parent elements.

Attributes

AttributeDescription
enabledRequired attribute.

Specifies whether the runtime creates Publisher evidence.
ValueDescription
falseDoes not create Publisher evidence.
trueCreates Publisher evidence. This is the default.

Child Elements

None.

Parent Elements

ElementDescription
configurationThe root element in every configuration file used by the common language runtime and .NET Framework applications.
runtimeContains information about runtime initialization options.
System_CAPS_ICON_note.jpg Note

In the .NET Framework 4 and later, this element has no effect on assembly load times. For more information, see the "Security Policy Simplification" section in Security Changes.

The common language runtime (CLR) tries to verify the Authenticode signature at load time to create Publisher evidence for the assembly. However, by default, most applications do not need Publisher evidence. Standard CAS policy does not rely on the PublisherMembershipCondition. You should avoid the unnecessary startup cost associated with verifying the publisher signature unless your application executes on a computer with custom CAS policy, or is intending to satisfy demands for PublisherIdentityPermission in a partial-trust environment. (Demands for identity permissions always succeed in a full-trust environment.)

System_CAPS_ICON_note.jpg Note

We recommend that services use the <generatePublisherEvidence> element to improve startup performance. Using this element can also help avoid delays that can cause a time-out and the cancellation of the service startup.

This element can be used only in the application configuration file.

The following example shows how to use the <generatePublisherEvidence> element to disable checking for CAS publisher policy for an application.

<configuration>  
    <runtime>  
        <generatePublisherEvidence enabled="false"/>  
    </runtime>  
</configuration>  

Runtime Settings Schema
Configuration File Schema

Show: