-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(vex): VEX Repository support (#7206)
Signed-off-by: knqyf263 <knqyf263@gmail.com> Co-authored-by: DmitriyLewen <91113035+DmitriyLewen@users.noreply.github.com>
- Loading branch information
1 parent
174b1e3
commit 88ba460
Showing
77 changed files
with
3,497 additions
and
643 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
## trivy vex | ||
|
||
[EXPERIMENTAL] VEX utilities | ||
|
||
### Options | ||
|
||
``` | ||
-h, --help help for vex | ||
``` | ||
|
||
### Options inherited from parent commands | ||
|
||
``` | ||
--cache-dir string cache directory (default "/path/to/cache") | ||
-c, --config string config path (default "trivy.yaml") | ||
-d, --debug debug mode | ||
--generate-default-config write the default config to trivy-default.yaml | ||
--insecure allow insecure server connections | ||
-q, --quiet suppress progress bar and log output | ||
--timeout duration timeout (default 5m0s) | ||
-v, --version show version | ||
``` | ||
|
||
### SEE ALSO | ||
|
||
* [trivy](trivy.md) - Unified security scanner | ||
* [trivy vex repo](trivy_vex_repo.md) - Manage VEX repositories | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
## trivy vex repo | ||
|
||
Manage VEX repositories | ||
|
||
### Examples | ||
|
||
``` | ||
# Initialize the configuration file | ||
$ trivy vex repo init | ||
# List VEX repositories | ||
$ trivy vex repo list | ||
# Download the VEX repositories | ||
$ trivy vex repo download | ||
``` | ||
|
||
### Options | ||
|
||
``` | ||
-h, --help help for repo | ||
``` | ||
|
||
### Options inherited from parent commands | ||
|
||
``` | ||
--cache-dir string cache directory (default "/path/to/cache") | ||
-c, --config string config path (default "trivy.yaml") | ||
-d, --debug debug mode | ||
--generate-default-config write the default config to trivy-default.yaml | ||
--insecure allow insecure server connections | ||
-q, --quiet suppress progress bar and log output | ||
--timeout duration timeout (default 5m0s) | ||
-v, --version show version | ||
``` | ||
|
||
### SEE ALSO | ||
|
||
* [trivy vex](trivy_vex.md) - [EXPERIMENTAL] VEX utilities | ||
* [trivy vex repo download](trivy_vex_repo_download.md) - Download the VEX repositories | ||
* [trivy vex repo init](trivy_vex_repo_init.md) - Initialize a configuration file | ||
* [trivy vex repo list](trivy_vex_repo_list.md) - List VEX repositories | ||
|
35 changes: 35 additions & 0 deletions
35
docs/docs/references/configuration/cli/trivy_vex_repo_download.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
## trivy vex repo download | ||
|
||
Download the VEX repositories | ||
|
||
### Synopsis | ||
|
||
Downloads enabled VEX repositories. If specific repository names are provided as arguments, only those repositories will be downloaded. Otherwise, all enabled repositories are downloaded. | ||
|
||
``` | ||
trivy vex repo download [REPO_NAMES] [flags] | ||
``` | ||
|
||
### Options | ||
|
||
``` | ||
-h, --help help for download | ||
``` | ||
|
||
### Options inherited from parent commands | ||
|
||
``` | ||
--cache-dir string cache directory (default "/path/to/cache") | ||
-c, --config string config path (default "trivy.yaml") | ||
-d, --debug debug mode | ||
--generate-default-config write the default config to trivy-default.yaml | ||
--insecure allow insecure server connections | ||
-q, --quiet suppress progress bar and log output | ||
--timeout duration timeout (default 5m0s) | ||
-v, --version show version | ||
``` | ||
|
||
### SEE ALSO | ||
|
||
* [trivy vex repo](trivy_vex_repo.md) - Manage VEX repositories | ||
|
31 changes: 31 additions & 0 deletions
31
docs/docs/references/configuration/cli/trivy_vex_repo_init.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
## trivy vex repo init | ||
|
||
Initialize a configuration file | ||
|
||
``` | ||
trivy vex repo init [flags] | ||
``` | ||
|
||
### Options | ||
|
||
``` | ||
-h, --help help for init | ||
``` | ||
|
||
### Options inherited from parent commands | ||
|
||
``` | ||
--cache-dir string cache directory (default "/path/to/cache") | ||
-c, --config string config path (default "trivy.yaml") | ||
-d, --debug debug mode | ||
--generate-default-config write the default config to trivy-default.yaml | ||
--insecure allow insecure server connections | ||
-q, --quiet suppress progress bar and log output | ||
--timeout duration timeout (default 5m0s) | ||
-v, --version show version | ||
``` | ||
|
||
### SEE ALSO | ||
|
||
* [trivy vex repo](trivy_vex_repo.md) - Manage VEX repositories | ||
|
31 changes: 31 additions & 0 deletions
31
docs/docs/references/configuration/cli/trivy_vex_repo_list.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
## trivy vex repo list | ||
|
||
List VEX repositories | ||
|
||
``` | ||
trivy vex repo list [flags] | ||
``` | ||
|
||
### Options | ||
|
||
``` | ||
-h, --help help for list | ||
``` | ||
|
||
### Options inherited from parent commands | ||
|
||
``` | ||
--cache-dir string cache directory (default "/path/to/cache") | ||
-c, --config string config path (default "trivy.yaml") | ||
-d, --debug debug mode | ||
--generate-default-config write the default config to trivy-default.yaml | ||
--insecure allow insecure server connections | ||
-q, --quiet suppress progress bar and log output | ||
--timeout duration timeout (default 5m0s) | ||
-v, --version show version | ||
``` | ||
|
||
### SEE ALSO | ||
|
||
* [trivy vex repo](trivy_vex_repo.md) - Manage VEX repositories | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
docs/docs/supply-chain/vex.md → docs/docs/supply-chain/vex/file.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Vulnerability Exploitability Exchange (VEX) | ||
|
||
!!! warning "EXPERIMENTAL" | ||
This feature might change without preserving backwards compatibility. | ||
|
||
Trivy supports filtering detected vulnerabilities using the [Vulnerability Exploitability eXchange (VEX)](https://www.ntia.gov/files/ntia/publications/vex_one-page_summary.pdf), a standardized format for sharing and exchanging information about vulnerabilities. | ||
By providing VEX during scanning, it is possible to filter vulnerabilities based on their status. | ||
|
||
## VEX Usage Methods | ||
|
||
Trivy currently supports two methods for utilizing VEX: | ||
|
||
1. [VEX Repository](./repo.md) | ||
2. [Local VEX Files](./file.md) | ||
|
||
### Enabling VEX | ||
To enable VEX, use the `--vex` option. | ||
You can specify the method to use: | ||
|
||
- To enable the VEX Repository: `--vex repo` | ||
- To use a local VEX file: `--vex /path/to/vex-document.json` | ||
|
||
```bash | ||
$ trivy image ghcr.io/aquasecurity/trivy:0.52.0 --vex repo | ||
``` | ||
|
||
You can enable both methods simultaneously. | ||
The order of specification determines the priority: | ||
|
||
- `--vex repo --vex /path/to/vex-document.json`: VEX Repository has priority | ||
- `--vex /path/to/vex-document.json --vex repo`: Local file has priority | ||
|
||
For detailed information on each method, please refer to each page. |
Oops, something went wrong.