Fortinet white logo
Fortinet white logo

Administration Guide

26.2.0

GitLab

GitLab

The following steps will help you integrate with a GitLab Project.

FortiCNAPP does not support SCM integration with self-hosted GitLab.

Self-hosted Gitlab is supported for the following integrations:

Integrating repositories with GitLab requires you have an Owner or Maintainer role in GitLab.

Integrating FortiCNAPP with GitLab requires token-based authentication. Before you create a Group Access Token, you should decide which GitLab Groups you want FortiCNAPP to scan and choose one to start with. Visit the GitLab Documentation for help creating a Group Access Token.

The token you create must have the role set to Maintainer and both the read_repository and api scopes selected.

Once you have created a Group Access Token, you can integrate with GitLab.

To integrate with GitLab:
  1. Log in to the console.

  2. Go to Settings > Integrations > Code security.

  3. Click Add integration.

  4. Select an integration type:

    1. Select a Git provider.

    2. Select GitLab.

  5. Click Go to GitLab.

  6. Log in to your GitLab Account.

  7. Click Authorize.

  8. In the console, enter your Group Access Token and use the dropdown the select the corresponding GitLab group.

  9. Click Test integration.

  10. Once the test returns Integration successful, click Next. The Code Security app then scans and lists the integrated organizations and repositories.

  11. Click Close to exit the integration wizard.

    FortiCNAPP Code Security will automatically scan the default branch of all your repositories. Once the scans are completed, you will be able to see the results in the UI.

Once integrated, you can enable or disable different Code Security tools. The following topics provide information on navigating through the UI of each Code Security tool:

GitLab

GitLab

The following steps will help you integrate with a GitLab Project.

FortiCNAPP does not support SCM integration with self-hosted GitLab.

Self-hosted Gitlab is supported for the following integrations:

Integrating repositories with GitLab requires you have an Owner or Maintainer role in GitLab.

Integrating FortiCNAPP with GitLab requires token-based authentication. Before you create a Group Access Token, you should decide which GitLab Groups you want FortiCNAPP to scan and choose one to start with. Visit the GitLab Documentation for help creating a Group Access Token.

The token you create must have the role set to Maintainer and both the read_repository and api scopes selected.

Once you have created a Group Access Token, you can integrate with GitLab.

To integrate with GitLab:
  1. Log in to the console.

  2. Go to Settings > Integrations > Code security.

  3. Click Add integration.

  4. Select an integration type:

    1. Select a Git provider.

    2. Select GitLab.

  5. Click Go to GitLab.

  6. Log in to your GitLab Account.

  7. Click Authorize.

  8. In the console, enter your Group Access Token and use the dropdown the select the corresponding GitLab group.

  9. Click Test integration.

  10. Once the test returns Integration successful, click Next. The Code Security app then scans and lists the integrated organizations and repositories.

  11. Click Close to exit the integration wizard.

    FortiCNAPP Code Security will automatically scan the default branch of all your repositories. Once the scans are completed, you will be able to see the results in the UI.

Once integrated, you can enable or disable different Code Security tools. The following topics provide information on navigating through the UI of each Code Security tool: