Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
67a711fe3c | ||
|
|
9591a27e59 |
No files matched your search
@@ -32,7 +32,7 @@ the git-tracked files plus lockfiles generated in the job (also gitignored
|
|||||||
ones like Flutter's `pubspec.lock`), so run it after the dependency fetch:
|
ones like Flutter's `pubspec.lock`), so run it after the dependency fetch:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- uses: https://git.rfa.cz/tth-pub/ci-actions/trivy-gate@v1.1
|
- uses: https://git.rfa.cz/tth-pub/ci-actions/trivy-gate@v2
|
||||||
with:
|
with:
|
||||||
scan-type: fs
|
scan-type: fs
|
||||||
```
|
```
|
||||||
@@ -78,7 +78,7 @@ other IaC in the tree. These findings are reported (HIGH/CRITICAL by
|
|||||||
default) and never block.
|
default) and never block.
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- uses: https://git.rfa.cz/tth-pub/ci-actions/trivy-gate@v1.2
|
- uses: https://git.rfa.cz/tth-pub/ci-actions/trivy-gate@v2
|
||||||
with:
|
with:
|
||||||
scan-type: fs
|
scan-type: fs
|
||||||
scanners: misconfig
|
scanners: misconfig
|
||||||
@@ -94,7 +94,13 @@ default rules apply with test files and fixtures allowlisted. The release
|
|||||||
binary is verified by SHA-256.
|
binary is verified by SHA-256.
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- uses: https://git.rfa.cz/tth-pub/ci-actions/gitleaks@v1.2
|
- uses: https://git.rfa.cz/tth-pub/ci-actions/gitleaks@v2
|
||||||
with:
|
with:
|
||||||
mode: block # or warn
|
mode: block # or warn
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Versions
|
||||||
|
|
||||||
|
`v1` image gate + SBOM; `v2` fs scans, binary runtime, misconfig, gitleaks;
|
||||||
|
`v3` gitleaks fetches the parent of a single commit in a depth-1 checkout
|
||||||
|
(dispatch/cron runs scanned the whole tree as a root commit before).
|
||||||
+8
-1
@@ -83,7 +83,14 @@ runs:
|
|||||||
opts="--first-parent --diff-merges=off $BEFORE..$SHA"
|
opts="--first-parent --diff-merges=off $BEFORE..$SHA"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
[ -n "$opts" ] || opts="--diff-merges=off -1 ${SHA:-HEAD}"
|
if [ -z "$opts" ]; then
|
||||||
|
# One commit (dispatch/cron). In a depth-1 checkout it has no
|
||||||
|
# parent and would be diffed as a root commit, i.e. the whole
|
||||||
|
# tree (upstream files of a fork included): fetch its parent.
|
||||||
|
head="${SHA:-HEAD}"
|
||||||
|
git rev-parse -q --verify "$head^" >/dev/null 2>&1 || git fetch -q --deepen=1 origin 2>/dev/null || true
|
||||||
|
opts="--diff-merges=off -1 $head"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
if [ -n "$CONFIG" ] && [ -f "$CONFIG" ]; then
|
if [ -n "$CONFIG" ] && [ -f "$CONFIG" ]; then
|
||||||
cfg=(--config "$CONFIG")
|
cfg=(--config "$CONFIG")
|
||||||
|
|||||||
Reference in new issue
Block a user