Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
1378342
Remove unneeded packages
0intro Aug 23, 2024
8f46b76
Disable all config analyzers
0intro Mar 17, 2025
f7d4dc1
Remove dependency on k8s.io/api
0intro Sep 4, 2024
044a7e1
Remove dependency on github.com/hashicorp/go-getter
0intro Jun 3, 2024
27e5ec2
feat: allow restricting filesystem walk to specific folders
lebauce Jan 13, 2023
5db8e07
Ignore permission errors when walking in dpkg post analyzer
lebauce Apr 25, 2024
89cca40
dpkg: split info and status walk and parsing
paulcacheux Jul 1, 2024
eb62546
feat: Add binary version parsing for nodejs, php and python
0intro Sep 2, 2024
886c825
executable: remove digest calculations from executable analyzer
0intro Oct 8, 2024
ef6cb52
perf(analyzers): various low hanging fruits to optimize profiler methods
jinroh Oct 14, 2024
2ea4154
pkg/fanal/walker: add AllFile option to Walker
0intro Nov 6, 2024
3a81ce9
pkg/fanal/artifact/container: implement container artifact
0intro Nov 6, 2024
7a2e991
Use index 0 when we fail to guess the base image index
lebauce Dec 20, 2024
ba8a175
add support for offline jar/javadb mode
paulcacheux Feb 18, 2025
fc94683
remove standalone and client/server scanners
paulcacheux Feb 21, 2025
18623f0
remove SBOM analyzer
paulcacheux Feb 21, 2025
d99b035
remove unpackaged
paulcacheux Feb 21, 2025
c488113
remove remote sbom
paulcacheux Feb 22, 2025
af13d97
force schema version
paulcacheux Feb 21, 2025
4a8570e
move `GuessBaseImageIndex` to reduce dependencies
paulcacheux Feb 22, 2025
815ef59
remove buildinfo analyzer
paulcacheux Feb 22, 2025
f0217e3
Re-use existing `ErrorCallback` WalkOption in post-analysis fs walks
YoannGh Nov 26, 2024
359ffe3
Don't trigger walk error on non-existing directories in dpkg analyzer
0intro Mar 18, 2025
58d200b
feat(fs): optimize scanning performance by direct file access for kno…
knqyf263 Mar 13, 2025
8e8e9d7
fix(fs): check postAnalyzers for StaticPaths (#8543)
DmitriyLewen Mar 13, 2025
17222a5
go.mod: use last commit of github.com/knqyf263/go-rpmdb
0intro Mar 21, 2025
9076e2a
go.mod: use Go 1.23
0intro Mar 21, 2025
5ffff1b
disable git hash query
paulcacheux Mar 24, 2025
09723d9
remove `github.com/xeipuuv/gojsonschema`
paulcacheux Mar 24, 2025
c4b7a5f
downgrade github.com/open-policy-agent/opa
paulcacheux Mar 24, 2025
bcaabb1
remove secret analyzer
paulcacheux Mar 25, 2025
af991af
remove more analyzers (config and imgconf)
paulcacheux Mar 25, 2025
263edee
pkg/fanal/artifact/image: disable checkImageSize
0intro Mar 26, 2025
1432642
remove javadb oci download
paulcacheux Mar 24, 2025
f10ab8a
pkg/fanal/analyzer/pkg/bottlerocket: add bottlerocket os package anal…
0intro Mar 27, 2025
bdbfe00
re-introduce default dpkg analyzer error handling behavior (#24)
YoannGh Mar 27, 2025
bd697b3
pkg/dependency/parser/executable/java: remove misleading comment
0intro Mar 28, 2025
40561b7
remove `rsc.io/binaryregexp` dependency
paulcacheux Mar 27, 2025
f6511a5
Revert "pkg/fanal/analyzer/pkg/bottlerocket: add bottlerocket os pack…
0intro May 26, 2025
ac597e6
feat: add Bottlerocket OS package analyzer (#8653)
0intro May 23, 2025
c6a94a4
pkg/fanal/artifact/container: don't modify SkipFiles, SkipDirs and On…
0intro Jun 5, 2025
37a8c6d
feat: pass context to WalkDirFunc
0intro Jun 5, 2025
fd5505b
feat: handle cancellation in WalkDir
0intro Jun 2, 2025
f3712b5
feat: return partial results on error in language analyzers
0intro Jun 6, 2025
e8702a2
feat: return partial result on timeout
0intro Jun 6, 2025
4c570d4
feat: implement timeout per PostAnalyzer
0intro Jun 6, 2025
409b579
feat: merge result only if the PostAnalyzer completed successfully
0intro Jun 16, 2025
49b2de2
feat: implement timeout on analyzeWithRootDir
0intro Jun 17, 2025
d64bd96
fix indentation of container AnalysisOptions structure
0intro Jul 9, 2025
e788758
feat: implement OfflineJar artifact option
0intro Jul 9, 2025
0ecdc33
feat: add support for RHEL 9 for Edge in RPM analyzer
0intro Jul 15, 2025
c6ac58f
do not crash when no partial result on deadline expired error
paulcacheux Jul 22, 2025
60ceeae
feat: implement FileChecksumJar artifact option
0intro Oct 17, 2025
4ca5284
fix(redhat): save contentSets for OS packages in fs/vm modes (#8820)
DmitriyLewen May 12, 2025
81178fc
fix(sbom): add `buildInfo` info as properties (#9683)
DmitriyLewen Oct 20, 2025
916430a
add buildinfo analyzer
0intro Oct 24, 2025
fd4d97d
pkg/fanal/artifact/container: handle BuildInfo in container artifact
0intro Oct 30, 2025
71c4dd0
cached_file: pre-alloc file buffer
jinroh Apr 8, 2025
5475cb2
container: takes a list of repository tags for container artifact
jinroh Oct 7, 2025
ba89a95
fix: increase the default buffer size for scanning dpkg status files …
0intro Nov 4, 2025
5f838ae
cached_file: fix using len instead of capa for pre-allocated buffer
jinroh Nov 4, 2025
c0a6cb9
cached_file: fix bad buffer pointer
jinroh Nov 6, 2025
aedf523
fix: pass OfflineJar and FileChecksumJar in image artifact options
paulcacheux Nov 6, 2025
81422df
Revert "add buildinfo analyzer"
paulcacheux Nov 6, 2025
dce2871
[VULN-59766] chore(deps): migrate from github.com/docker/docker to gi…
L3n41c Apr 7, 2026
6cf8ddc
[VULN-59766] fix: handle ENODATA when reading overlay xattrs via sysx
L3n41c Apr 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion docs/docs/advanced/container/unpacked-filesystem.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,4 +113,4 @@ Total: 20 (UNKNOWN: 0, LOW: 2, MEDIUM: 10, HIGH: 8, CRITICAL: 0)
+--------------+------------------+----------+-------------------+---------------+---------------------------------------+
```

</details>
</details>
15 changes: 15 additions & 0 deletions docs/docs/coverage/os/bottlerocket.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Bottlerocket
Trivy supports the following scanners for OS packages.

| Scanner | Supported |
| :-----------: | :-------: |
| SBOM | ✓ |
| Vulnerability | - |
| License | - |

Please see [here](index.md#supported-os) for supported versions.

## SBOM
Trivy detects packages that are listed in the [software inventory].

[software inventory]: https://bottlerocket.dev/en/os/1.37.x/concepts/variants/#software-inventory
1 change: 1 addition & 0 deletions docs/docs/coverage/os/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ Trivy supports operating systems for
| [Photon OS](photon.md) | 1.0, 2.0, 3.0, 4.0 | tndf/yum/rpm |
| [Debian GNU/Linux](debian.md) | 7, 8, 9, 10, 11, 12 | apt/dpkg |
| [Ubuntu](ubuntu.md) | All versions supported by Canonical | apt/dpkg |
| [Bottlerocket](bottlerocket.md) | 1.7.0 and upper | bottlerocket |
| [OSs with installed Conda](../others/conda.md) | - | conda |

## Supported container images
Expand Down
9 changes: 9 additions & 0 deletions docs/docs/coverage/os/rhel.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,13 @@ Trivy detects packages that have been installed through package managers such as
## Vulnerability
Red Hat offers its own security advisories, and these are utilized when scanning Red Hat Enterprise Linux (RHEL) for vulnerabilities.

### Content manifests
Red Hat’s security advisories use CPEs to identify product sets. For example, even packages installed in the same container image can have different CPEs.
For this reason, Red Hat’s container images include stored content manifests, which we convert to CPEs, and perform vulnerability scanning.

Since this system ties each content manifest to its packages on a per-layer basis,
if layers get merged (for instance, by using `docker run` or `docker export`) we can no longer determine the correct CPE, which may lead to false detection.

### Data Source
See [here](../../scanner/vulnerability.md#data-sources).

Expand Down Expand Up @@ -82,3 +89,5 @@ Trivy identifies licenses by examining the metadata of RPM packages.
[NVD]: https://nvd.nist.gov/vuln/detail/CVE-2023-0464

[vulnerability statuses]: ../../configuration/filtering.md#by-status

[content-set-default]: https://github.com/aquasecurity/trivy/blob/c80310d7690d8aeb7d3d77416c18c0c8b9aebe17/pkg/detector/ospkg/redhat/redhat.go#L25-L42
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ trivy config [flags] DIR
--k8s-version string specify k8s version to validate outdated api by it (example: 1.21.0)
--misconfig-scanners strings comma-separated list of misconfig scanners to use for misconfiguration scanning (default [azure-arm,cloudformation,dockerfile,helm,kubernetes,terraform,terraformplan-json,terraformplan-snapshot])
--module-dir string specify directory to the wasm modules that will be loaded (default "$HOME/.trivy/modules")
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--password strings password. Comma-separated passwords allowed. TRIVY_PASSWORD should be used for security reasons.
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_filesystem.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ trivy filesystem [flags] PATH
--module-dir string specify directory to the wasm modules that will be loaded (default "$HOME/.trivy/modules")
--no-progress suppress progress bar
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--parallel int number of goroutines enabled for parallel scanning, set 0 to auto-detect parallelism (default 5)
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_image.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ trivy image [flags] IMAGE_NAME
--module-dir string specify directory to the wasm modules that will be loaded (default "$HOME/.trivy/modules")
--no-progress suppress progress bar
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--parallel int number of goroutines enabled for parallel scanning, set 0 to auto-detect parallelism (default 5)
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_kubernetes.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ trivy kubernetes [flags] [CONTEXT]
--node-collector-imageref string indicate the image reference for the node-collector scan job (default "ghcr.io/aquasecurity/node-collector:0.3.1")
--node-collector-namespace string specify the namespace in which the node-collector job should be deployed (default "trivy-temp")
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--parallel int number of goroutines enabled for parallel scanning, set 0 to auto-detect parallelism (default 5)
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_repository.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ trivy repository [flags] (REPO_PATH | REPO_URL)
--module-dir string specify directory to the wasm modules that will be loaded (default "$HOME/.trivy/modules")
--no-progress suppress progress bar
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--parallel int number of goroutines enabled for parallel scanning, set 0 to auto-detect parallelism (default 5)
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_rootfs.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ trivy rootfs [flags] ROOTDIR
--module-dir string specify directory to the wasm modules that will be loaded (default "$HOME/.trivy/modules")
--no-progress suppress progress bar
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--parallel int number of goroutines enabled for parallel scanning, set 0 to auto-detect parallelism (default 5)
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_sbom.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ trivy sbom [flags] SBOM_PATH
--list-all-pkgs output all packages in the JSON report regardless of vulnerability
--no-progress suppress progress bar
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--password strings password. Comma-separated passwords allowed. TRIVY_PASSWORD should be used for security reasons.
Expand Down
1 change: 1 addition & 0 deletions docs/docs/references/configuration/cli/trivy_vm.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ trivy vm [flags] VM_IMAGE
--module-dir string specify directory to the wasm modules that will be loaded (default "$HOME/.trivy/modules")
--no-progress suppress progress bar
--offline-scan do not issue API requests to identify dependencies
--only-dirs strings specify the directories where the traversal is allowed
-o, --output string output file name
--output-plugin-arg string [EXPERIMENTAL] output plugin arguments
--parallel int number of goroutines enabled for parallel scanning, set 0 to auto-detect parallelism (default 5)
Expand Down
16 changes: 16 additions & 0 deletions docs/docs/target/rootfs.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,19 @@ $ trivy rootfs /path/to/rootfs
Rootfs scanning works differently from the Filesystem scanning.
You should use `trivy fs` to scan your local projects in CI/CD.
See [here](../scanner/vulnerability.md) for the differences.

!!! note
Scanning vulnerabilities for `Red Hat` has a limitation, see the [Red Hat](../coverage/os/rhel.md#content-manifests) page for details.

## Performance Optimization

By default, Trivy traverses all files from the specified root directory to find target files for scanning.
However, when you only need to scan specific files with absolute paths, you can avoid this traversal, which makes scanning faster.
For example, when scanning only OS packages, no full traversal is performed:

```bash
$ trivy rootfs --pkg-types os --scanners vuln /
```

When scanning language-specific packages or secrets, traversal is necessary because the location of these files is unknown.
If you want to exclude specific directories from scanning for better performance, you can use the [--skip-dirs](../configuration/skipping.md) option.
3 changes: 3 additions & 0 deletions docs/docs/target/vm.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,9 @@ See [here](../scanner/vulnerability.md) for the detail.
$ trivy vm [YOUR_VM_IMAGE]
```

!!! note
Scanning `Red Hat` has a limitation, see the [Red Hat](../coverage/os/rhel.md#content-manifests) page for details.

### Misconfigurations
It is supported, but it is not useful in most cases.
As mentioned [here](../scanner/misconfiguration/index.md), Trivy mainly supports Infrastructure as Code (IaC) files for misconfigurations.
Expand Down
Loading