SecAnnotate.exe (.NET Security Annotator Tool)

SecAnnotate.exe (.NET Security Annotator Tool)

The .NET Security Annotator tool (SecAnnotate.exe) is a command-line application that identifies the SecurityCritical and SecuritySafeCritical portions of one or more assemblies.

A Visual Studio extension, Security Annotator, provides a graphical user interface to SecAnnotate.exe and enables you to run the tool from Visual Studio.

This tool is automatically installed with Visual Studio and with the Windows SDK. To run the tool, we recommend that you use the Visual Studio Command Prompt or the Windows SDK Command Prompt (CMD Shell). These utilities enable you to run the tool easily, without navigating to the installation folder. For more information, see Visual Studio and Windows SDK Command Prompts.

  • If you have Visual Studio installed on your computer: On the taskbar, click Start, click All Programs, click Visual Studio, click Visual Studio Tools, and then click Visual Studio Command Prompt.


    If you have the Windows SDK installed on your computer: On the taskbar, click Start, click All Programs, click the folder for the Windows SDK, and then click Command Prompt (or CMD Shell).

  • At the command prompt, type the following, where parameters are described in the following section, and assemblies consist of one or more assembly names separated by blanks:

SecAnnotate.exe [parameters] [assemblies]






Shows statistics about the use of transparency in assemblies that are being analyzed.




Specifies a directory to search for dependent assemblies during annotation.




Includes extended signature information in the annotation report file.




Suppresses searching for referenced assemblies in the global assembly cache.




Specifies the output annotation file.




Specifies the maximum number of annotation passes to make on assemblies before stopping the generation of new annotations.




Specifies quiet mode, in which the annotator does not output status messages; it outputs only error information.




Includes the specified assembly when resolving dependent assemblies during annotation. Reference assemblies are given priority over assemblies that are found in the reference path.




Suppresses running the specified transparency rule on the input assemblies.




Forces the Annotator tool to treat all assemblies that do not have any transparency annotations as if they were entirely transparent.




Verifies only that an assembly's annotations are correct; does not attempt to make multiple passes to find all required annotations if the assembly does not verify.




Specifies verbose output while annotating.




Includes the specified directory when searching for symbol files during annotation.

Parameters and assemblies may also be provided in a response file that is specified on the command line and prefixed with an at sign (@). Each line in the response file should contain a single parameter or assembly name.

For more information about the .NET Security Annotator, see the entry Using SecAnnotate to Analyze Your Assemblies for Transparency Violations in the .NET Security blog.

Community Additions

© 2015 Microsoft