Skip to content

Commit 66959ea

Browse files
committed
feat: export findings to securityhub
1 parent 13f53c5 commit 66959ea

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/reusable-cve-scan.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,8 +196,12 @@ jobs:
196196
set -euo pipefail
197197
AWS_ACCOUNT_ID=$(aws sts get-caller-identity --query Account --output text)
198198
export AWS_ACCOUNT_ID
199-
# Generate ASFF using Trivy's built-in template
200-
trivy convert --format template --template "@contrib/asff.tpl" --output trivy-results.asff trivy-results.json
199+
200+
# Download ASFF template explicitly (trivy-action does not ship contrib templates)
201+
curl -fsSL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/asff.tpl -o asff.tpl
202+
203+
trivy convert --format template --template "@asff.tpl" \
204+
--output trivy-results.asff trivy-results.json
201205
202206
- name: Import findings into AWS Security Hub
203207
if: inputs.add_to_securityhub

0 commit comments

Comments
 (0)