Skip to content

Commit

Permalink
[CP-Sec] Enable OpenSSF scorecard, dependabot and add security policy
Browse files Browse the repository at this point in the history
  • Loading branch information
carlewis committed Sep 25, 2024
1 parent 62562f0 commit fe2e9d2
Show file tree
Hide file tree
Showing 4 changed files with 77 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

version: 2
updates:
# Enable version updates for Github Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "monthly"
groups:
github-actions:
patterns:
- "*"
reviewers:
- "codeplaysoftware/security-managers"
53 changes: 53 additions & 0 deletions .github/workflows/scorecard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Scorecards' GitHub action

name: Scorecard supply-chain security
on:
# For Branch-Protection check. Only the default branch is supported. See
# https://github.com/ossf/scorecard/blob/main/docs/checks.md#branch-protection
branch_protection_rule:
schedule:
- cron: '25 15 * * 3'
push:
branches: [ "master" ]

# Declare default permissions as read only.
permissions: read-all

jobs:
analysis:
name: Scorecard analysis
runs-on: ubuntu-latest
permissions:
# Needed to upload the results to code-scanning dashboard.
security-events: write
# Needed to publish results and get a badge (see publish_results below).
id-token: write

steps:
- name: "Checkout code"
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
persist-credentials: false

- name: "Run analysis"
uses: ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0
with:
results_file: results.sarif
results_format: sarif
publish_results: true

# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
# format to the repository Actions tab.
- name: "Upload artifact"
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4.4.0
with:
name: SARIF file
path: results.sarif
retention-days: 5

# Upload the results to GitHub's code scanning dashboard (optional).
# Commenting out will disable upload of results to your repo's Code Scanning dashboard
- name: "Upload to code-scanning"
uses: github/codeql-action/upload-sarif@294a9d92911152fe08befb9ec03e240add280cb3 # v3.26.8
with:
sarif_file: results.sarif
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# TensorOpt

[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/codeplaysoftware/TensorOpt/badge)](https://scorecard.dev/viewer/?uri=github.com/codeplaysoftware/TensorOpt)

TensorOpt is designed as a wrapper around ML graph libraries.
Its purpose is to be integrated in ML frameworks using SYCL such as TensorFlow.

Expand Down
8 changes: 8 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Security Policy

## Reporting a Vulnerability

To report a vulnerability or a security issue please fill the security
advisories form [here](../../security/advisories/new), send an email to
[email protected] or contact us using the [contact form on our web
page](https://codeplay.com/company/contact/?q=Report%20Security%20Issue).

0 comments on commit fe2e9d2

Please sign in to comment.