Skip to main content

Setting Up the Eclipse Plugin (v9.2.0 and up)

The instructions below refer to local installation of the CxSAST Eclipse Plugin. It is also possible to make the Eclipse plugin centrally available to organizational IDE users, so they can link to it. Upon plugin updates, the organizational IDE users are automatically prompted to update. For further information and instructions, refer to Eclipse Project Update Sites.

Prerequisites

The following components must be installed and available before installing the Checkmarx Eclipse plugin:

  • The latest version of Eclipse installed

  • CxSAST 9.2 or higher installed

Connecting to Proxy

  • In order to set up the CxSAST Eclipse plugin using a proxy, you can now use the built-in proxy settings.

  • After configuring the proxy, restart the Eclipse environment.

To edit the eclipse.ini file to pint to the JDK setup:

1. Download the CxSAST Eclipse plugin zip archive.

2. Locate the eclipse.exe file and edit the vm arguments accordingly:

-vm C:/Program Files/Java/jdk-11.0.13/bin.

To edit the location for generating the Checkmarx plugin logs:

1. Navigate to and open log4j2.xml with your text editor.

2. Enter the desired location for the Checkmarx plugin log file, for example to C:\Users\admin\.p2\pool\plugins\com.checkmarx.cxviewer_<version>\config

To set up and configure the CxSAST Eclipse plugin:

Notice

For instructions on local installation of the CxSAST Eclipse Plugin on Linux, refer to Setting Up the CxSAST Eclipse Plugin on Linux.

1. Download the CxSAST Eclipse plugin zip archive.

2. Open Eclipse, go to the Help menu and select Install New Software.

6345588790.jpg

3. Click <Add...>.

6345588787.jpg

4. Enter a name into the Name field, for example, CxViewerPlugin.

Notice

To make the plugin centrally available to all organizational Eclipse users and enable automatic prompts for plugin updates:

  • Place the downloaded plugin zip archive on the CxSAST Server (in a distributed deployment: on CxManager).

  • On that Server, create a folder named Eclipse in the web server's home directory, for example: C:\inetpub\wwwroot\Eclipse.

  • Extract the plugin archive to the Eclipse folder.

  • In Eclipse, go to Location and type: http://<CxSAST>/Eclipse/, where <CxSAST> is the IP address or resolvable hostname of the CxSAST server.

5. Click <Archive...>, browse to the CxEclipsePlugin zip file and click <Open>.

6345588784.jpg

6. Select the CxViewer plugin and complete the wizard.

7. Restart the Eclipse environment.

8. In Eclipse, go to the Window menu and select Preferences.

9. From CxViewer Preferences, select Authentication.

6345588781.png

10. Type the path to the CxSAST server in the Server URL field (e.g., http://<server_name>). It is recommended that you use the hostname.

Notice

  • Make sure that no "/" is added at the end of http://<server_name>, which could happen when copying and pasting the URL/hostname in.

  • In case of server connection issues, enter the hostname instead of the IP address in the server URL field. Both the IP address and the hostname are listed in the etc/hosts file (for example, 10.32.5.117 sdlc-sast-89.cxquality.com).

11. Click <Test> to validate the connection.

Notice

The Logout button can be used in case you want to log in using a different user or to a different server.

The ‘Trust All SSL Certificates’ checkbox can be used to add certified security to the connection in the following:

  • When enabled, all certificates are trusted.

  • When disabled (by default), only certificates signed by a trusted certificate authority can be accepted.

Notice

The checkbox is only enabled when the URL starts with ‘https’ (SSL).

12. Click Apply and Close.

Notice

If you want to improve your viewing experience, it is recommended to avoid using a laptop or small screen.

To remove the plugin:

  • Unbind all projects and then use the Windows uninstallation option to uninstall the Checkmarx plugin