Skip to content

Commit 4239046

Browse files
bluesentinelsecclueleafMichael LongCarolMebiomMaria Carolina Conceição
authored
Sync v1.4.0 to 1.x (#135)
* replace scanner example (#84) * Write CSV with no vulns (#86) * reproducing issue - test 1 * resolve issue 85 - test 2 * test 3 * test fix --------- Co-authored-by: Michael Long <mlongii@amazon.com> * testing CSV with no vulns * test against main branch * Write Dockerfile CSV and Markdown on no vulns (#88) Co-authored-by: Michael Long <mlongii@amazon.com> * Set example workflows to main branch for testing * Display 'no vulns found' for Dockerfiles (#92) Co-authored-by: Michael Long <mlongii@amazon.com> * Tweak dockerfile report (#93) Co-authored-by: Michael Long <mlongii@amazon.com> * Omit Dockerfile table on no vulns (#94) Co-authored-by: Michael Long <mlongii@amazon.com> * Updated workflows to v1.x - testing auto-updates (#96) Co-authored-by: Michael Long <mlongii@amazon.com> * update README (#97) Co-authored-by: Michael Long <mlongii@amazon.com> * Extend vulnerability severity providers (#98) * Add severity providers: GHSA, GitLab * Add severity providers: GHSA, GitLab * Add REDHAT_CVE and UBUNTU_CVE providers * rename GHSA to GITHUB --------- Co-authored-by: Michael Long <mlongii@amazon.com> * Add platform argument for container image scans (#102) * add --platform support for multi-arch containers * test multi-arch images on current branch * test actions against sbomgen 1.5.1-beta * fix --platform parsing error * fix platform parsing bug * test workflows on sbomgen latest (1.5.2) * Validate --platform input * Add more test cases, and revert workflow definitions * fix typo in platform arg --------- Co-authored-by: Michael Long <mlongii@amazon.com> * Improve severity rating consistency (#112) * fix severity rating mismatch * temporarily add a test workflow * Fix type issue: float provided, expected string * Rename workflow / job name * Add severity comparison logic * Revise severity sorting and selection logic * return default values on error * skip EPSS ratings for severity column * debugging unknown ratings * fix ratings with unknown name * Verify AMAZON_INSPECTOR renders correctly * fix failing test * temporarily disable failing tests * pass unit test: test_parse_inspector_scan_result * pass unit tests * change '-f' to '--failfast' for clarity * Remove unused type cast * refactor csv test * severity is rendered as 'other' not 'unknown' * test build on all actions * normalize dockerfile findings severity rating * debugging dockerfile severity * debugging * Normalize Dockerfile severity 'info' to 'other' * restore test actions * minor comment update * Remove develop workflow * Address PR feedback * test workflows against refactor * handle edge case CVE-2025-22871 * fix missing severity edge case * debugging epss * debugging * fix flawed test * added test case for absent severity rating * revert workflows to v1 --------- Co-authored-by: Michael Long <mlongii@amazon.com> * v1.3.0 (#123) * Feature request 91 (#115) * FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts * Revert "FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts" This reverts commit bc532d4. * FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts * FR-91: Fix unit tests * FR-91: Fix typo in unit tests * Revert "FR-91: Fix typo in unit tests" This reverts commit e645542. * Revert "FR-91: Fix unit tests" This reverts commit f9157c9. * Revert "FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts" This reverts commit 812c685. * FR-91: Change orchestrator to only find fixed vulnerabilities if flag show-only-fixed-vulnerabilities is present * FR-91: Fixed missing variable * FR-91: Fixed typo * FR-91: Fixed typo * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * Add unit test for get_vuln_count * Fix unit test for get_vuln_count --------- Co-authored-by: Maria Carolina Conceição <carolina.bento@floy.com> * Clarify license of inspector-sbomgen dependency (#121) Co-authored-by: Michael Long <mlongii@amazon.com> * [v1.3.0] Only trigger vuln threshold on fixable vulns (#122) * Add --threshold-fixable-only to CLI * implemented business logic * changed 'threshold_fixable_only' from str to bool * Added more test coverage and CLI refinements * debugging failing unit test * test threshold-fixable-only in workflow * test threshold-fixable-only in workflow * debugging CI/CD * debugging CI/CD * debugging * debugging * debugging * debugging * removed debug log showing CLI arguments * add missing argument, fixed_vuln_counts * simplify get_fixed_vuln_counts() return values * refactor return types in get_scan_result() * refactor * refine get_fixed_vuln_counts() * update test_get_fixed_vuln_counts() * testing case sensitivity * revert 'TRUE' to 'true' * use debug log when vuln doesnt have rating * integrate --show-only-fixable-vulns (part 1) * integrate only show fixable vulns * test example workflows * fix CLI input arguments * remove leading '-' character for conditional inclusion * add a no-op CLI arg (workaround) * enable new arguments in workflows * fix failing test * update workflows for prod --------- Co-authored-by: Michael Long <mlongii@amazon.com> * set workflows to v1.3.0 for burn-in --------- Co-authored-by: CarolMebiom <59604360+CarolMebiom@users.noreply.github.com> Co-authored-by: Maria Carolina Conceição <carolina.bento@floy.com> Co-authored-by: Michael Long <mlongii@amazon.com> * Sync main to v1.3.0 (#126) * Feature request 91 (#115) * FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts * Revert "FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts" This reverts commit bc532d4. * FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts * FR-91: Fix unit tests * FR-91: Fix typo in unit tests * Revert "FR-91: Fix typo in unit tests" This reverts commit e645542. * Revert "FR-91: Fix unit tests" This reverts commit f9157c9. * Revert "FR-91: Add cli arg only fixable vulnerability; use the variable in get_vuln_counts" This reverts commit 812c685. * FR-91: Change orchestrator to only find fixed vulnerabilities if flag show-only-fixed-vulnerabilities is present * FR-91: Fixed missing variable * FR-91: Fixed typo * FR-91: Fixed typo * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * FR-91: Another fix * Add unit test for get_vuln_count * Fix unit test for get_vuln_count --------- Co-authored-by: Maria Carolina Conceição <carolina.bento@floy.com> * Clarify license of inspector-sbomgen dependency (#121) Co-authored-by: Michael Long <mlongii@amazon.com> * [v1.3.0] Only trigger vuln threshold on fixable vulns (#122) * Add --threshold-fixable-only to CLI * implemented business logic * changed 'threshold_fixable_only' from str to bool * Added more test coverage and CLI refinements * debugging failing unit test * test threshold-fixable-only in workflow * test threshold-fixable-only in workflow * debugging CI/CD * debugging CI/CD * debugging * debugging * debugging * debugging * removed debug log showing CLI arguments * add missing argument, fixed_vuln_counts * simplify get_fixed_vuln_counts() return values * refactor return types in get_scan_result() * refactor * refine get_fixed_vuln_counts() * update test_get_fixed_vuln_counts() * testing case sensitivity * revert 'TRUE' to 'true' * use debug log when vuln doesnt have rating * integrate --show-only-fixable-vulns (part 1) * integrate only show fixable vulns * test example workflows * fix CLI input arguments * remove leading '-' character for conditional inclusion * add a no-op CLI arg (workaround) * enable new arguments in workflows * fix failing test * update workflows for prod --------- Co-authored-by: Michael Long <mlongii@amazon.com> * set workflows to v1.3.0 for burn-in --------- Co-authored-by: CarolMebiom <59604360+CarolMebiom@users.noreply.github.com> Co-authored-by: Maria Carolina Conceição <carolina.bento@floy.com> Co-authored-by: Michael Long <mlongii@amazon.com> * Verify v1 tag works * Verify action against 1.x * v1.4.0 (#133) * Use aws-cli instead of amazonlinux to speed up container build time (#128) * Change Dockerfile source image to aws-cli * Set WORKDIR back to default value --------- Co-authored-by: Joshua-Grisham_SSCSpace <joshua.grisham@sscspace.com> * set workflows to develop for aws-cli runtime tests * add explicit permissions to GitHub Actions workflows (#130) * Measuring installation time (#131) (#132) * measuring installation time * Change workflows to point to v1.4.0 branch --------- Co-authored-by: Joshua Grisham <josh@joshuagrisham.com> Co-authored-by: Joshua-Grisham_SSCSpace <joshua.grisham@sscspace.com> --------- Co-authored-by: clueleaf <10379303+clueleaf@users.noreply.github.com> Co-authored-by: Michael Long <mlongii@amazon.com> Co-authored-by: CarolMebiom <59604360+CarolMebiom@users.noreply.github.com> Co-authored-by: Maria Carolina Conceição <carolina.bento@floy.com> Co-authored-by: Joshua Grisham <josh@joshuagrisham.com> Co-authored-by: Joshua-Grisham_SSCSpace <joshua.grisham@sscspace.com>
1 parent 8a46d20 commit 4239046

15 files changed

+69
-23
lines changed

.github/workflows/build_scan_container.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ on:
1212
branches: #
1313
- '*'
1414

15+
permissions:
16+
contents: read
17+
id-token: write
18+
actions: write # For uploading artifacts
19+
1520
jobs:
1621
build:
1722
name: Build docker image
@@ -47,7 +52,7 @@ jobs:
4752
role-to-assume: ${{ secrets.AWS_IAM_ROLE }}
4853

4954
- name: Scan built image with Inspector
50-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
55+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
5156
id: inspector
5257
with:
5358
artifact_type: 'container'

.github/workflows/example_display_findings.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ on:
88
branches: #
99
- '*'
1010

11+
permissions:
12+
contents: read
13+
id-token: write
14+
1115
jobs:
1216
daily_job:
1317
runs-on: ubuntu-latest
@@ -29,7 +33,7 @@ jobs:
2933
# modify this block to scan your intended artifact
3034
- name: Inspector Scan
3135
id: inspector
32-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
36+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
3337
with:
3438
# change artifact_type to either 'repository', 'container', 'binary', or 'archive'.
3539
# this example scans a container image

.github/workflows/example_vulnerability_threshold_exceeded.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848

4949
# Inspector scan
5050
- name: Scan container with Inspector
51-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
51+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
5252
id: inspector
5353
with:
5454
artifact_type: 'container' # configure Inspector for scanning a container

.github/workflows/run_unit_tests.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
branches: #
88
- '*'
99

10+
permissions:
11+
contents: read
12+
id-token: write
13+
1014
jobs:
1115
build:
1216
runs-on: ubuntu-latest

.github/workflows/scan_repo_with_semgrep.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ name: Semgrep Scan
22

33
on: [push]
44

5+
permissions:
6+
contents: read
7+
58
jobs:
69
semgrep:
710
runs-on: ubuntu-latest

.github/workflows/test_archive.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ on:
1111
branches: #
1212
- '*'
1313

14+
permissions:
15+
contents: read
16+
id-token: write
17+
1418
jobs:
1519
daily_job:
1620
runs-on: ubuntu-latest
@@ -32,7 +36,7 @@ jobs:
3236

3337
- name: Test archive scan
3438
id: inspector
35-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
39+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
3640
with:
3741
artifact_type: 'archive'
3842
artifact_path: 'entrypoint/tests/test_data/artifacts/archives/testData.zip'

.github/workflows/test_binary.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ on:
1111
branches: #
1212
- '*'
1313

14+
permissions:
15+
contents: read
16+
id-token: write
17+
1418
jobs:
1519
daily_job:
1620
runs-on: ubuntu-latest
@@ -32,7 +36,7 @@ jobs:
3236

3337
- name: Test binary scan
3438
id: inspector
35-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
39+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
3640
with:
3741
artifact_type: 'binary'
3842
artifact_path: 'entrypoint/tests/test_data/artifacts/binaries/inspector-sbomgen'

.github/workflows/test_containers.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ on:
1111
branches: #
1212
- '*'
1313

14+
permissions:
15+
contents: read
16+
id-token: write
17+
1418
jobs:
1519
daily_job:
1620
runs-on: ubuntu-latest
@@ -32,7 +36,7 @@ jobs:
3236

3337
- name: Test container scan
3438
id: inspector
35-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
39+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
3640
with:
3741
artifact_type: 'container'
3842
artifact_path: 'ubuntu:14.04'

.github/workflows/test_dockerfile_vulns.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ on:
1111
branches: #
1212
- '*'
1313

14+
permissions:
15+
contents: read
16+
id-token: write
17+
1418
jobs:
1519
daily_job:
1620
runs-on: ubuntu-latest
@@ -31,7 +35,7 @@ jobs:
3135

3236
- name: Scan Dockerfiles
3337
id: inspector
34-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
38+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
3539
with:
3640
artifact_type: 'repository'
3741
artifact_path: './'

.github/workflows/test_installation.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ on:
1111
branches:
1212
- '*'
1313

14+
permissions:
15+
contents: read
16+
id-token: write
17+
1418
jobs:
1519
daily_job:
1620
runs-on: ubuntu-latest
@@ -28,7 +32,7 @@ jobs:
2832
role-to-assume: ${{ secrets.AWS_IAM_ROLE }}
2933

3034
- name: Test Amazon Inspector GitHub Actions plugin
31-
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.3.0
35+
uses: aws-actions/vulnerability-scan-github-action-for-amazon-inspector@v1.4.0
3236
with:
3337
artifact_type: 'container'
3438
artifact_path: 'alpine:latest'
@@ -40,7 +44,4 @@ jobs:
4044
if: ${{ failure() }}
4145
run: echo "this feature is not implemented"
4246

43-
# TODO: update this to point to public v1.0.0 release
44-
# TODO: add steps to send notification to a Lambda to cut a ticket on job failure
45-
# TODO: delete on push condition when finished with development
46-
# TODO: use an IAM role
47+

0 commit comments

Comments
 (0)