Configurable ClickOnce Security Permissions

As a general rule, you should always configure your ClickOnce application to request only the code access security permissions that it actually needs. You can easily configure security permissions in Visual Studio 2005 on the security pane of the Project Designer. The security pane contains an Enable ClickOnce Security Settings check box that you can select to add security permission requests to the deployment manifest for your application. A good starting point is to specify the zone from which your application will be deployed, because applications deployed from different locations are automatically granted different levels of permissions. Then you can use the permission calculator tool to analyze your application, enable required permissions, and warn you of permissions that are not part of your zone default. It's a good idea to avoid requiring security permissions beyond those of your default zone, and Visual Studio has one more new feature to help you accomplish that goal. Now you can test your application's performance using different security credentials debugging your applications with configurable security permissions.

Calculate and configure the security permissions your application needs on the security pane.