- Checkmarx Documentation
- SAST/SCA Integrations
- Other Integrations
- Codebashing Integration with SAST
- Integrating Codebashing with SAST to Enable Generating Courses according to Detected Vulnerabilities
- Creating Environment Variables to define Courses and the Codebashing Platform
Creating Environment Variables to define Courses and the Codebashing Platform
You need three mandatory system environment variables. An additional three optional system environment variables can be created for the name and the description for the generated courses.
System Variable Name | System Variable Value/Description |
---|---|
CB_URL | The URL for the Codebashing platform. |
CB_API_KEY | The key you copied from the API Credentials dialog. |
CB_API_TOKEN | The token you copied from the API Credentials dialog. |
System Variable Name | System Variable Value/Description |
---|---|
CB_COURSE_NAME | The course title. This value is used for all generated courses. If left blank or the environment variable is not created, a default is used. |
CB_COURSE_DESCRIPTION | The course description. This value is used for all generated courses. If left blank or the environment variable is not created, a default is used. |
CB_ADMIN_EMAILS | Emails of specific admin users in the tenant to send updatees to. By default, updates on generated courses are sent to all admin users in the tenant. To send updates to specific admin users only, add these emails separated by commas as Variable Value, for example like user1@example.com, user2@example.com. |
Navigate to the System Properties dialog. Getting to the System Properties dialog depends on the Windows version in use. The System properties are referred to as Advanced System Settings and are for example accessed as follows.
Under Windows 10, System Properties can be accessed via the :About: About menu under Settings and System.
Under Windows Server 2012, System Properties can be accesses via Control Panel > System and Security > System.
Click <Environment Variables>. The list of existing environment variables appears.
To define a new environment variable, click <New…>. The New System Variable dialog appears and you are asked to enter the Variable Name and the Variable Value as illustrated in the tables above.
When done, click <OK>. The new variable is added.
Open the command prompt as administrator and define the system variables as illustrated by stating first the sytem variable name and then the system variable value. Replace the place holders for the system variable values in the brackets “<>” with the actual values as listed in the tables above.
setx CB_URL <platform-url> /m setx CB_API_KEY <api-credentials-key> /m setx CB_API_TOKEN <api-credentials-token> /m
Notice
After updating environment variables, you have to restart the CxJobsManager service for the post script action to work properly.