This guide needs the SafeDep Cloud Team or Enterprise plan and the Owner or Admin role. See pricing. The app must scan the repositories for your tenant.
What the check reads
For the SafeDep default of each setting and the scopes that the check applies, see Cloud Policy Settings.
Verified malware always fails the check. No setting and no trust entry changes that. The check does not apply a dependency cooldown.
The check still applies the Malicious Package Exclusions of your tenant. When an exclusion selects a package version, the check does not report an unverified malware verdict for that version. Verified malware still fails the check. PMG with
cloud.policy on ignores exclusions.
info is a partial value: the vulnerability data has no info grade, so the check ranks a vulnerability with no severity as info.
Fail on medium for a group of projects
-
Label the projects of the group. A repository is a project:
If a repository has no project yet, see Label projects.
-
Open the policy settings document and add a policy override:
-
Preview the change. The preview counts the projects that the policy override reaches, and how many of them can enforce
medium: -
Publish it:
Use the change number that
safedep policy editprinted. The next check of each project uses the new revision.
scan_gate.fail_on in the policy base instead. To target one forge, select on scm/forge, as in matchLabels: {scm/forge: bitbucket}.
Deny a license
The check applies the deny list first, then the allow list, to the license of each package that the pull request adds or updates. For the match rules, see License gate.-
Open the policy settings document:
-
Set the deny list in the policy base. Your list replaces the default list, so copy the nine default ids and add the new one:
-
Preview and publish the change with
safedep policy change showandsafedep policy change publish, as in Fail on medium for a group of projects.
deny: {licenses: []} in a policy override.
Allow only some licenses
Set an allow list for a group of projects. A package with a known license that is not on the list fails the check:- The deny list still applies. A license on both lists fails the check.
- A package with an unknown license still passes under
unknown: allow. To allow only the listed licenses, also setunknown: fail. See Fail on an unknown license. - To turn off the allow list of the policy base for a group, set
allow: {licenses: []}in a policy override.
Fail on an unknown license
Setunknown to report to show these packages in the check without a failure, or to fail to fail on them:
Waive a finding for one package
To pass a check that fails on a license or a vulnerability that your team accepts, create a trust entry. See Waive license findings and Waive named vulnerabilities.What the check shows
A failing check shows a policy block above the package report:- On GitHub, in the comment of the SafeDep app and in the output of the check run.
- On Bitbucket, in the comment of the SafeDep app. The build status of the commit links to the pull request.
- A passing check shows no policy block.
- On a public repository, the block shows the rule id of a package rule, not its reason.
- When the tenant has no policy revision, the block names only the SafeDep default policy.
When the check does not use your policy
- The repository has no project. The check resolves the policy with the
scm/labels of the repository. The policy base, the package rules of the policy base and the policy overrides that selectscm/labels apply. Acustom/label needs a project. See Label projects. - The installation is not linked to a tenant, or the plan of the tenant has no cloud policy. The SafeDep default policy applies alone.
- SafeDep Cloud cannot read the policy. The check retries, and then fails with an error. It never falls back to the default policy, because the default policy can be looser than yours.
Next steps
Explain a Decision
List the checks that a rule or a setting failed.
Target a Group
Label projects and select them in a policy override.
GitHub App
Install the SafeDep GitHub App.
Bitbucket App
Install and link the Bitbucket app.

