forked from ChelseaKR/ctdl-validate
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (36 loc) · 1.42 KB
/
Copy pathtrufflehog.yml
File metadata and controls
40 lines (36 loc) · 1.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# Full-history verified-secret scan. gitleaks runs diff-scoped in pre-commit
# (see .pre-commit-config.yaml); this is a periodic sweep of the entire commit
# history with a different engine and its own detector set, catching anything
# a diff-scoped scan by construction cannot (a secret introduced and later
# removed in the same PR still shows up in history). Also runs on push and
# pull_request so every change is swept, not just the weekly schedule.
name: trufflehog
on:
push:
branches: [main]
pull_request:
schedule:
- cron: "0 9 * * 0" # weekly, Sunday, staggered off ci.yml
workflow_dispatch:
permissions:
contents: read
concurrency:
group: trufflehog-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
scan:
name: full-history secret scan (verified only)
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0 # full clone; this is a whole-history scan, not a diff
persist-credentials: false
- name: TruffleHog (verified secrets only)
uses: trufflesecurity/trufflehog@6f3c981e7b77f235fd2702dd74af25fc4b72bf11 # v3.96.0
with:
path: ./
# The action's baked-in command already passes --fail; repeating it
# is a CLI error ("flag 'fail' cannot be repeated").
extra_args: --only-verified