Skip to content

Commit

Permalink
ci: implement security auditing checks
Browse files Browse the repository at this point in the history
`cargo-audit` and the RustSec Advisory DB

see: https://rustsec.org/
  • Loading branch information
nrdxp committed Sep 30, 2024
1 parent bf430fe commit fc901eb
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .cargo/audit.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[advisories]
ignore = []
severity_threshold = "low"

[output]
format = "json"
quiet = false

[yanked]
enabled = true

25 changes: 25 additions & 0 deletions .github/workflows/audit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: "Audit Dependencies"
on:
push:
paths:
# Run if workflow changes
- '.github/workflows/audit.yml'
# Run on changed dependencies
- '**/Cargo.toml'
- '**/Cargo.lock'
# Run if the configuration file changes
- '.cargo/audit.toml'
# Rerun periodicly to pick up new advisories
schedule:
- cron: '0 0 * * *'
# Run manually
workflow_dispatch:

jobs:
security_audit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: rustsec/audit-check@v2.0.0
with:
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit fc901eb

Please sign in to comment.