Safeguard Docs
Compliance ConnectorsSetup by categoryVulnerability Scanning

SonarQube

Connect SonarQube to Safeguard: what it provides, how to set it up, and the frameworks it provides evidence for.

Connect SonarQube to collect vulnerability scanning evidence with automated compliance tests, switched on per workspace.

CategoryVulnerability Scanning
Connect withAPI token
What a connection producesAutomated compliance tests
SonarQube's guidedocs.sonarsource.com

Connect with an API token

  1. In SonarQube:

    1. Sign in to SonarQube as a dedicated user that can access only the projects Safeguard should read (a user token gives all the permissions of the user who issued it).
    2. SonarQube Server: go to Account menu › My account › Security.
    3. In the form at the top of the page, enter a token name, select the token type User token, and select an expiration (or No expiration if allowed).
    4. Select Generate, then copy the token value immediately; when you dismiss the notification you will not be able to retrieve it.
    5. SonarQube Cloud: open your account menu in the top right corner, select My account › Access Tokens, and generate a personal token there (or use a Scoped Organization Token on the Team plan and above).

    Where to find the other values:

    • Base URL (optional): For SonarQube Server, the URL of your instance. Leave empty for SonarQube Cloud.
    • Organization (optional): SonarQube Cloud only: your organization key, shown in your organization's URL on SonarQube Cloud.

    SonarQube shows the secret only once, so copy it before you leave the page.

    If an administrator enforces a maximum token lifetime (Enterprise Edition and above), No expiration is not offered. On SonarQube Cloud, tokens without an expiration date are removed after 60 days of inactivity, and the Personal Tokens tab is only available to users signed in with GitHub. User tokens are deleted when the user is deleted. Which project permission the dedicated user needs is not covered by the fetched pages.

    Source: docs.sonarsource.com, docs.sonarsource.com, checked 2026-10-07.

    The permissions Safeguard needs: Browse.

  2. On Compliance › Connectors, open SonarQube, click Connect, choose API token and fill in:

    FieldWhat to enter
    Base URL (optional)Leave blank to use https://sonarcloud.io.
    API tokenRequired. Stored encrypted and never shown again.
    Organization (optional)—
  3. Click Connect with token.

Frameworks

Safeguard's automated tests read SonarQube and map to the controls below. When a test passes, the result is evidence toward each control it maps to, in every framework listed. It is evidence toward a control, not proof that the control is met on its own.

FrameworkEvidenceControlsTests
SOC2Automated testsCC7.14
ISO/IEC 27001Automated testsA.8.84
HIPAA Security RuleAutomated tests164.308(a)(1)4
PCI DSSAutomated tests6.3.3, 11.3.14
NIST CSF 2.0Automated testsID.RA-01, ID.RA-064

These tests are switched on per workspace by the Safeguard team.

On this page