HOW TO: Restore the Default Policy Levels for ASP.NET Applications

Article translations Article translations
Article ID: 815165 - View products that this article applies to.
Expand all | Collapse all

On This Page

SUMMARY

This step-by-step article describes how to restore the customized policy levels to the default settings for .NET-connected applications.

By default, managed assemblies are assigned one of the four trust levels: Full, High, Low, and None. These trust levels represent groups of specific rights to simplify assigning trust to managed assemblies. You can change the rights that are assigned to the High, Low, and None trust levels to meet the unique requirements of an environment.

Although you must use this level of customization for some environments, it can cause problems when you run assemblies that were designed to run in a specific trust level, because those assemblies may not have access to all resources that they require. This article describes how to restore the original settings that are assigned to each of the policy levels to their default state.

Trust Level Configuration Files

The .NET Framework stores copies of the default settings for each policy level in the same folder as the active configuration files. The backup configuration files add the .DEFAULT file name extension. The following table shows the locations of the three active configuration files and the three backup configuration files.

Note Configuration files exist for the High, Low, and None trust levels. However, there is no configuration file for the Full trust level. The Full trust level does not require a configuration file because assemblies that run at that level run without restrictions.

Collapse this tableExpand this table
File LocationDescription
\System Root\Microsoft .NET\Framework\Version Number\CONFIG\Web_notrust.configThe active configuration file that defines the permissions for applications that run at the None trust level.
\System Root\Microsoft .NET\Framework\Version Number\CONFIG\Web_notrust.config.defaultThe backup configuration file that defines the permissions for applications that run at the None trust level.
\System Root\Microsoft .NET\Framework\Version Number\CONFIG\Web_lowtrust.configThe active configuration file that defines the permissions for applications that run at the Low trust level.
\System Root\Microsoft .NET\Framework\Version Number\CONFIG\Web_lowtrust.config.defaultThe backup configuration file that defines the permissions for applications that run at the Low trust level.
\System Root\Microsoft .NET\Framework\Version Number\CONFIG\Web_hightrust.configThe active configuration file that defines the permissions for applications that run at the High trust level.
\System Root\Microsoft .NET\Framework\Version Number\CONFIG\Web_hightrust.config.defaultThe backup configuration file that defines the permissions for applications that run at the High trust level.


Restore Policy Level Settings

To restore the default policy level settings, follow these steps:
  1. Start Windows Explorer, and then move to the following folder:
    \System Root\ Microsoft.NET\Framework\Version Number\CONFIG\
  2. Rename the active, customized configuration file for the policy level that you want to restore. For example, add a .CUSTOM file name extension.
  3. Create a copy of the backup configuration file. For this file, use the same name as the active configuration file by removing the .DEFAULT extension.

    Note The backup configuration file has the same file name as the active configuration file, with an additional .DEFAULT file name extension.

REFERENCES

For more information about the securityPolicy element, visit the following Microsoft Web site:
http://msdn2.microsoft.com/en-us/library/zhs35b56(vs.71).aspx
For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
818013 HOW TO: Support Applications That Are Built on the .NET Framework


Properties

Article ID: 815165 - Last Review: April 30, 2003 - Revision: 2.6
APPLIES TO
  • Microsoft .NET Framework 1.0
  • Microsoft .NET Framework 1.1
Keywords: 
kbdir kbweb kbconfig kbhowtomaster KB815165

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com