JavaScript is not currently enabled, but is required for full CodeSonar manual search and browse functionality.

If you are viewing this file in your hub's Web GUI, enable JavaScript in your browser: you will also need it for GUI functionality.

If you opened this file directly from disk, your browser may be directly suppressing JavaScript functionality: certain browsers perform this suppression on local files (but not files delivered by web servers) for security reasons.

CodeSonar® 9.2p0 CONFIDENTIAL CodeSecure Inc
C and C++
C#
Third-Party External

CodeSonar Plug-in for Visual Studio: Options and Properties [Windows only]

Configuration for the CodeSonar plug-in for Visual Studio takes place at two levels of granularity.



CodeSonar Plug-in Options

Overall CodeSonar plug-in options are available from the CodeSonar menu in the main Visual Studio menu bar.

To view the CodeSonar plug-in properties:

  1. Open the CodeSonar menu in the main Visual Studio menu bar.
  2. Select Options.

Visual Studio will display the Options dialog, with the CodeSonar plug-in options selected.

screenshot: options dialog

To modify options:

  1. Edit the values to reflect your required changes.
  2. Click Apply.
  3. Click OK.

Project Properties

Each project has a set of associated CodeSonar properties, describing the project's analysis mode and current analysis.

To view project properties:

  1. Right-click on the project in the Solution Explorer.
  2. Select CodeSonar > Properties from the menu that opens.

Visual Studio will display the CodeSonar Project Properties dialog for the project.

screenshot: project properties dialog

Hub address The hub location for the project's current analysis.
Authentication type Anonymous only CodeSonar will only attempt to authorize the build/analysis as special user Anonymous.
(Corresponds to command line -auth anonymous.)
Password CodeSonar will attempt to authenticate and authorize the build/analysis using a hub user account username and password.
(Corresponds to command line -auth default if Try Anonymous first is selected; -auth password otherwise.)
  • Try Anonymous first: When selected, CodeSonar will first attempt to authorize the operation as Anonymous. If this is not successful, CodeSonar will attempt password-based authentication.
  • Username: The username for a user account on the hub specified in the Hub address field.
  • Password: The password for the Username specified above.
Certificate CodeSonar will attempt to authenticate and authorize the operation using a user certificate.
(Corresponds to command line -auth certificate.)
  • Certificate location: Browse to select a user certificate.
  • Private key location: Browse to select the private key file corresponding to the specified certificate.
Build/Analyze Import analysis results
or
Hook build
The project's analysis mode.
  • Import analysis results: Import mode. In this mode, the text field shows the URL of the imported analysis.
  • Hook Build: Hook mode
Project File If you leave this field blank, the locally-stored CodeSonar project files will have names based on the Visual Studio project name, and the analysis directory will be stored in the directory in which the build is performed.

To specify a different project name, or to use a different directory to store CodeSonar analysis artifacts, specify a file path in this field.

path/to/CSOpfiles_name
Then: Relative paths are interpreted with respect to the current working directory as determined by Visual Studio.
Project Specifies the hub project with which this Visual Studio project will be associated, as a string with one of the following forms.
  • proj-name
  • /proj-name
  • /ancestors/proj-name
Where:
  • proj-name is the project name, used to identify the project to the hub.
  • ancestors is the project's Ancestors string: a /-separated sequence of project tree names, representing the path from the root project tree to the project's parent project tree through the hub's overall project tree hierarchy. (Note that this does not entail correspondence with a file system path.)
  • The leading / denotes the root project tree.

If you leave this field blank, the hub project name will be determined as follows.

  • If you specified a Project File value of the form path/to/CSOpfiles_name, the hub project name will be CSOpfiles_name.
  • Otherwise, the hub project name will be the same as the Visual Studio project name.
Specifying a Project value here is equivalent to specifying a -project argument to the CodeSonar build/analysis command line: see the option documentation and hub project identification examples for full details.
Presets Use the menu to select a configuration preset to apply to the CodeSonar build/analysis for this project. By default, no presets will be applied.
Configuration File If you specify a configuration file here it will be applied to the CodeSonar build/analysis as an additional configuration file.
analysis management Specify how the analysis should be managed. Choose a radio button:
  • Local Analysis: the analysis is managed locally on the machine where you are running Visual Studio.
    Use the Allow Services checkbox (enabled by default) to specify whether or not CodeSonar should run as a service.
  • SaaS Analysis : the analysis is managed remotely, using an analysis launch daemon from the saas launchd group.
    This is the recommended setting for CodeSonar SaaS analyses.
  • Remote Analysis: the analysis is managed remotely, using the analysis launch daemon that you specify.
    Enter one of the following in the to Launchd field identify the remote analysis launch daemon.
    positive integer N all launch daemons that are transitive descendants of the launchd group whose LDGroup ID is N.
    negative integer -M the single launch daemon whose Launch Daemon ID is M.
    /Foo/Bar/* all launch daemons that are transitive descendants of the launchd group(s) whose LDGroup Path is /Foo/Bar/. Case sensitive.
    /Foo/Bar/user@machine all launch daemon(s) whose Parent LDGroup is Foo/Bar, System User is user, and Machine is machine. Case sensitive.

To modify project properties:

  1. Edit the values to reflect your required changes.
  2. Click Apply.
  3. Click OK.

Visual Studio Plug-in Links

The following sections provide detailed information about installing and using the CodeSonar plug-in for Visual Studio.

 

To report problems with this documentation, please visit https://support.codesecure.com/.