You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[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>
Copy file name to clipboardExpand all lines: action.yml
+14Lines changed: 14 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -110,6 +110,18 @@ inputs:
110
110
description: "Specifies the OS and CPU arch of the container image you wish to scan. Valid inputs are of the form 'os/cpu/variant' for example, 'linux/amd64', 'linux/arm64/v8', etc. If no platform is specified, the system will use the same platform as the host that is performing the scan. This argument only affects container image scans. Requires inspector-sbomgen 1.5.1 or later."
111
111
required: False
112
112
113
+
threshold_fixable_only:
114
+
description: 'If set to true, only count vulnerabilities with a fix towards threshold exceeded condition.'
115
+
required: False
116
+
default: false
117
+
type: boolean
118
+
119
+
show_only_fixable_vulns:
120
+
description: "If set to true, this action will show only fixed vulnerabilities in the GitHub Actions step summary page. All vulnerability metadata is still retained in the raw Inspector scan files."
121
+
required: False
122
+
default: false
123
+
type: boolean
124
+
113
125
outputs:
114
126
artifact_sbom:
115
127
description: "The filepath to the artifact's software bill of materials."
help="The amount of time in seconds that inspector-sbomgne will run. When this timeout is exceeded, sbomgen will gracefully conclude and present any findings discovered up to that point.")
53
-
parser.add_argument("--show-only-fixed-vulnerabilities", action="store_true", help="If set, this program will only show fixed vulnerabilities in the GitHub Actions job summary page.")
help="A no operation argument, used as the default from the GitHub Actions caller when boolean arguments are not set. This is a workaround because GitHub Actions doesn't have a clean way to invoke or not invoke action='store_true' arguments")
logging.fatal(f"received invalid container image platform: '{args.platform}'. Platform should be of the form 'os/cpu/variant' such as 'linux/amd64' or 'linux/arm64/v8'")
206
+
logging.fatal(
207
+
f"received invalid container image platform: '{args.platform}'. Platform should be of the form 'os/cpu/variant' such as 'linux/amd64' or 'linux/arm64/v8'")
0 commit comments