generated from ossf/project-template
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Adolfo García Veytia (puerco) <[email protected]>
- Loading branch information
Showing
2 changed files
with
49 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# SPDX-FileCopyrightText: Copyright 2024 The OSPS Baseline Authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
--- | ||
# Requires the Security Insights data source to be installed: | ||
# https://github.com/mindersec/minder-rules-and-profiles/blob/main/data-sources/security-insights.yaml | ||
--- | ||
version: v1 | ||
release_phase: alpha | ||
type: rule-type | ||
name: OSPS-DO-04 | ||
display_name: Ensures a project has a vulnerability reporting policy | ||
short_failure_message: No vulnerability reporting policy found. | ||
severity: | ||
value: low | ||
context: | ||
provider: github | ||
description: | | ||
Checks that the project links a vulnerability reporting policy. | ||
guidance: | | ||
This rule type checks for the project's vulnerability reporting tool. | ||
Currently, the rules looks for sources in the `vulnerability-reporting` | ||
section of the Security Insights file. | ||
def: | ||
in_entity: repository | ||
rule_schema: | ||
type: object | ||
ingest: | ||
type: git | ||
eval: | ||
type: rego | ||
data_sources: | ||
- name: securityinsights | ||
rego: | ||
type: deny-by-default | ||
def: | | ||
package minder | ||
import rego.v1 | ||
default allow := false | ||
si = minder.datasource.securityinsights.parse({}) | ||
allow if { | ||
count(si["vulnerability-reporting"]) > 0 | ||
} |