Skip to content

Commit efbe64d

Browse files
ci: address Copilot review feedback on secrets scanning [SVLS-8660]
- Fix .gitleaks.toml comment to reference correct `commits` key under [allowlist] - Add `permissions: contents: read` to secrets-scan workflow job - Enable `--redact` flag to prevent secret values appearing in CI logs Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent cb600c4 commit efbe64d

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.github/workflows/secrets-scan.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,17 @@ jobs:
1010
gitleaks:
1111
name: Secrets Scan
1212
runs-on: ubuntu-22.04
13+
permissions:
14+
contents: read
1315
steps:
1416
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
1517
with:
1618
fetch-depth: 0
1719

1820
- name: Run gitleaks
1921
uses: gitleaks/gitleaks-action@ff98106e4c7b2bc287b24eaf42907196329070c7 # v2.3.9
22+
with:
23+
args: --redact
2024
env:
2125
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26+
GITLEAKS_LICENSE: ${{ secrets.GITLEAKS_LICENSE }}

.gitleaks.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ title = "datadog-lambda-extension gitleaks config"
22

33
# This file configures gitleaks to suppress known false positives.
44
# Only add entries here after confirming a finding is NOT a real secret.
5-
# If a real secret is found: rotate it immediately, then add the commit to [allowlist.commits].
5+
# If a real secret is found: rotate it immediately, then add the commit hash to the `commits` list under [allowlist] below.
66
#
77
# Maintenance workflow:
88
# 1. gitleaks flags something on a PR

0 commit comments

Comments
 (0)