diff --git a/latest/404.html b/latest/404.html index d96af32757..55b27d9bf1 100644 --- a/latest/404.html +++ b/latest/404.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../v0.25.3/404.html... + Redirecting to ../v0.25.4/404.html... \ No newline at end of file diff --git a/latest/community/cks/index.html b/latest/community/cks/index.html index c6cd1d19b3..f549b8f9b4 100644 --- a/latest/community/cks/index.html +++ b/latest/community/cks/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/community/cks/... + Redirecting to ../../../v0.25.4/community/cks/... \ No newline at end of file diff --git a/latest/community/contrib/help-wanted/index.html b/latest/community/contrib/help-wanted/index.html deleted file mode 100644 index cf006c3f39..0000000000 --- a/latest/community/contrib/help-wanted/index.html +++ /dev/null @@ -1,16 +0,0 @@ - - - - - Redirecting - - - - - Redirecting to ../../../../v0.25.3/community/contrib/help-wanted/... - - \ No newline at end of file diff --git a/latest/community/contrib/triage/index.html b/latest/community/contrib/triage/index.html deleted file mode 100644 index 132595703a..0000000000 --- a/latest/community/contrib/triage/index.html +++ /dev/null @@ -1,16 +0,0 @@ - - - - - Redirecting - - - - - Redirecting to ../../../../v0.25.3/community/contrib/triage/... - - \ No newline at end of file diff --git a/latest/community/contribute/issue/index.html b/latest/community/contribute/issue/index.html new file mode 100644 index 0000000000..16f29fc01c --- /dev/null +++ b/latest/community/contribute/issue/index.html @@ -0,0 +1,16 @@ + + + + + Redirecting + + + + + Redirecting to ../../../../v0.25.4/community/contribute/issue/... + + \ No newline at end of file diff --git a/latest/community/contribute/pr/index.html b/latest/community/contribute/pr/index.html new file mode 100644 index 0000000000..32909c0097 --- /dev/null +++ b/latest/community/contribute/pr/index.html @@ -0,0 +1,16 @@ + + + + + Redirecting + + + + + Redirecting to ../../../../v0.25.4/community/contribute/pr/... + + \ No newline at end of file diff --git a/latest/community/credit/index.html b/latest/community/credit/index.html index 5b0d21dfa7..eec9d34025 100644 --- a/latest/community/credit/index.html +++ b/latest/community/credit/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/community/credit/... + Redirecting to ../../../v0.25.4/community/credit/... \ No newline at end of file diff --git a/latest/community/maintainer/help-wanted/index.html b/latest/community/maintainer/help-wanted/index.html new file mode 100644 index 0000000000..ece9482e0f --- /dev/null +++ b/latest/community/maintainer/help-wanted/index.html @@ -0,0 +1,16 @@ + + + + + Redirecting + + + + + Redirecting to ../../../../v0.25.4/community/maintainer/help-wanted/... + + \ No newline at end of file diff --git a/latest/community/maintainer/triage/index.html b/latest/community/maintainer/triage/index.html new file mode 100644 index 0000000000..8b95e02ff9 --- /dev/null +++ b/latest/community/maintainer/triage/index.html @@ -0,0 +1,16 @@ + + + + + Redirecting + + + + + Redirecting to ../../../../v0.25.4/community/maintainer/triage/... + + \ No newline at end of file diff --git a/latest/community/references/index.html b/latest/community/references/index.html index 38e00e6735..48fcdb79e3 100644 --- a/latest/community/references/index.html +++ b/latest/community/references/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/community/references/... + Redirecting to ../../../v0.25.4/community/references/... \ No newline at end of file diff --git a/latest/community/tools/index.html b/latest/community/tools/index.html index ca0e836868..324b19b845 100644 --- a/latest/community/tools/index.html +++ b/latest/community/tools/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/community/tools/... + Redirecting to ../../../v0.25.4/community/tools/... \ No newline at end of file diff --git a/latest/docs/advanced/air-gap/index.html b/latest/docs/advanced/air-gap/index.html index 17bb169820..64cc8e4cef 100644 --- a/latest/docs/advanced/air-gap/index.html +++ b/latest/docs/advanced/air-gap/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/advanced/air-gap/... + Redirecting to ../../../../v0.25.4/docs/advanced/air-gap/... \ No newline at end of file diff --git a/latest/docs/advanced/container/embed-in-dockerfile/index.html b/latest/docs/advanced/container/embed-in-dockerfile/index.html index f9547b50c4..4eb1d08549 100644 --- a/latest/docs/advanced/container/embed-in-dockerfile/index.html +++ b/latest/docs/advanced/container/embed-in-dockerfile/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/container/embed-in-dockerfile/... + Redirecting to ../../../../../v0.25.4/docs/advanced/container/embed-in-dockerfile/... \ No newline at end of file diff --git a/latest/docs/advanced/container/oci/index.html b/latest/docs/advanced/container/oci/index.html index 22c1ec8f27..2a48399eec 100644 --- a/latest/docs/advanced/container/oci/index.html +++ b/latest/docs/advanced/container/oci/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/container/oci/... + Redirecting to ../../../../../v0.25.4/docs/advanced/container/oci/... \ No newline at end of file diff --git a/latest/docs/advanced/container/podman/index.html b/latest/docs/advanced/container/podman/index.html index c9f485ff86..a434397f88 100644 --- a/latest/docs/advanced/container/podman/index.html +++ b/latest/docs/advanced/container/podman/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/container/podman/... + Redirecting to ../../../../../v0.25.4/docs/advanced/container/podman/... \ No newline at end of file diff --git a/latest/docs/advanced/container/unpacked-filesystem/index.html b/latest/docs/advanced/container/unpacked-filesystem/index.html index e0434ef4e0..f36e3f720e 100644 --- a/latest/docs/advanced/container/unpacked-filesystem/index.html +++ b/latest/docs/advanced/container/unpacked-filesystem/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/container/unpacked-filesystem/... + Redirecting to ../../../../../v0.25.4/docs/advanced/container/unpacked-filesystem/... \ No newline at end of file diff --git a/latest/docs/advanced/plugins/index.html b/latest/docs/advanced/plugins/index.html index 6dd573ac3f..ceb83a4c02 100644 --- a/latest/docs/advanced/plugins/index.html +++ b/latest/docs/advanced/plugins/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/advanced/plugins/... + Redirecting to ../../../../v0.25.4/docs/advanced/plugins/... \ No newline at end of file diff --git a/latest/docs/advanced/private-registries/acr/index.html b/latest/docs/advanced/private-registries/acr/index.html index 461506230c..a9604f9ff9 100644 --- a/latest/docs/advanced/private-registries/acr/index.html +++ b/latest/docs/advanced/private-registries/acr/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/private-registries/acr/... + Redirecting to ../../../../../v0.25.4/docs/advanced/private-registries/acr/... \ No newline at end of file diff --git a/latest/docs/advanced/private-registries/docker-hub/index.html b/latest/docs/advanced/private-registries/docker-hub/index.html index 9e79c6f95c..ef17905504 100644 --- a/latest/docs/advanced/private-registries/docker-hub/index.html +++ b/latest/docs/advanced/private-registries/docker-hub/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/private-registries/docker-hub/... + Redirecting to ../../../../../v0.25.4/docs/advanced/private-registries/docker-hub/... \ No newline at end of file diff --git a/latest/docs/advanced/private-registries/ecr/index.html b/latest/docs/advanced/private-registries/ecr/index.html index 6a5215c915..7975cdfd7f 100644 --- a/latest/docs/advanced/private-registries/ecr/index.html +++ b/latest/docs/advanced/private-registries/ecr/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/private-registries/ecr/... + Redirecting to ../../../../../v0.25.4/docs/advanced/private-registries/ecr/... \ No newline at end of file diff --git a/latest/docs/advanced/private-registries/gcr/index.html b/latest/docs/advanced/private-registries/gcr/index.html index c384fbdc39..08d7ba1759 100644 --- a/latest/docs/advanced/private-registries/gcr/index.html +++ b/latest/docs/advanced/private-registries/gcr/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/private-registries/gcr/... + Redirecting to ../../../../../v0.25.4/docs/advanced/private-registries/gcr/... \ No newline at end of file diff --git a/latest/docs/advanced/private-registries/index.html b/latest/docs/advanced/private-registries/index.html index 5dffd7ee20..5074f0b5b7 100644 --- a/latest/docs/advanced/private-registries/index.html +++ b/latest/docs/advanced/private-registries/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/advanced/private-registries/... + Redirecting to ../../../../v0.25.4/docs/advanced/private-registries/... \ No newline at end of file diff --git a/latest/docs/advanced/private-registries/self/index.html b/latest/docs/advanced/private-registries/self/index.html index 31552089d0..59ed929440 100644 --- a/latest/docs/advanced/private-registries/self/index.html +++ b/latest/docs/advanced/private-registries/self/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/advanced/private-registries/self/... + Redirecting to ../../../../../v0.25.4/docs/advanced/private-registries/self/... \ No newline at end of file diff --git a/latest/docs/index.html b/latest/docs/index.html index 24deec7813..651ebc74ac 100644 --- a/latest/docs/index.html +++ b/latest/docs/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../v0.25.3/docs/... + Redirecting to ../../v0.25.4/docs/... \ No newline at end of file diff --git a/latest/docs/integrations/aws-codepipeline/index.html b/latest/docs/integrations/aws-codepipeline/index.html index f6798afc63..fb19a05acb 100644 --- a/latest/docs/integrations/aws-codepipeline/index.html +++ b/latest/docs/integrations/aws-codepipeline/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/aws-codepipeline/... + Redirecting to ../../../../v0.25.4/docs/integrations/aws-codepipeline/... \ No newline at end of file diff --git a/latest/docs/integrations/aws-security-hub/index.html b/latest/docs/integrations/aws-security-hub/index.html index 71456a9104..9192c3e1ea 100644 --- a/latest/docs/integrations/aws-security-hub/index.html +++ b/latest/docs/integrations/aws-security-hub/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/aws-security-hub/... + Redirecting to ../../../../v0.25.4/docs/integrations/aws-security-hub/... \ No newline at end of file diff --git a/latest/docs/integrations/bitbucket/index.html b/latest/docs/integrations/bitbucket/index.html index d84e8a0022..910ad6ead4 100644 --- a/latest/docs/integrations/bitbucket/index.html +++ b/latest/docs/integrations/bitbucket/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/bitbucket/... + Redirecting to ../../../../v0.25.4/docs/integrations/bitbucket/... \ No newline at end of file diff --git a/latest/docs/integrations/circleci/index.html b/latest/docs/integrations/circleci/index.html index 1e439bfc83..0ca788b842 100644 --- a/latest/docs/integrations/circleci/index.html +++ b/latest/docs/integrations/circleci/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/circleci/... + Redirecting to ../../../../v0.25.4/docs/integrations/circleci/... \ No newline at end of file diff --git a/latest/docs/integrations/github-actions/index.html b/latest/docs/integrations/github-actions/index.html index 358669dec5..a37c150a13 100644 --- a/latest/docs/integrations/github-actions/index.html +++ b/latest/docs/integrations/github-actions/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/github-actions/... + Redirecting to ../../../../v0.25.4/docs/integrations/github-actions/... \ No newline at end of file diff --git a/latest/docs/integrations/gitlab-ci/index.html b/latest/docs/integrations/gitlab-ci/index.html index 5a15b29639..57e21da5d1 100644 --- a/latest/docs/integrations/gitlab-ci/index.html +++ b/latest/docs/integrations/gitlab-ci/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/gitlab-ci/... + Redirecting to ../../../../v0.25.4/docs/integrations/gitlab-ci/... \ No newline at end of file diff --git a/latest/docs/integrations/index.html b/latest/docs/integrations/index.html index f462b91f38..4bcaeeef66 100644 --- a/latest/docs/integrations/index.html +++ b/latest/docs/integrations/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/docs/integrations/... + Redirecting to ../../../v0.25.4/docs/integrations/... \ No newline at end of file diff --git a/latest/docs/integrations/travis-ci/index.html b/latest/docs/integrations/travis-ci/index.html index e53ff17652..6f3d813d76 100644 --- a/latest/docs/integrations/travis-ci/index.html +++ b/latest/docs/integrations/travis-ci/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/integrations/travis-ci/... + Redirecting to ../../../../v0.25.4/docs/integrations/travis-ci/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/comparison/cfsec/index.html b/latest/docs/misconfiguration/comparison/cfsec/index.html index 443a33949b..9587a1fd2a 100644 --- a/latest/docs/misconfiguration/comparison/cfsec/index.html +++ b/latest/docs/misconfiguration/comparison/cfsec/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/comparison/cfsec/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/comparison/cfsec/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/comparison/conftest/index.html b/latest/docs/misconfiguration/comparison/conftest/index.html index f2e016ac04..b13f25cf27 100644 --- a/latest/docs/misconfiguration/comparison/conftest/index.html +++ b/latest/docs/misconfiguration/comparison/conftest/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/comparison/conftest/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/comparison/conftest/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/comparison/tfsec/index.html b/latest/docs/misconfiguration/comparison/tfsec/index.html index 900be588e2..886e9009b6 100644 --- a/latest/docs/misconfiguration/comparison/tfsec/index.html +++ b/latest/docs/misconfiguration/comparison/tfsec/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/comparison/tfsec/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/comparison/tfsec/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/custom/combine/index.html b/latest/docs/misconfiguration/custom/combine/index.html index a77cf5f420..a41c21bd23 100644 --- a/latest/docs/misconfiguration/custom/combine/index.html +++ b/latest/docs/misconfiguration/custom/combine/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/custom/combine/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/custom/combine/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/custom/data/index.html b/latest/docs/misconfiguration/custom/data/index.html index 1c7843b082..8f33c89e58 100644 --- a/latest/docs/misconfiguration/custom/data/index.html +++ b/latest/docs/misconfiguration/custom/data/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/custom/data/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/custom/data/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/custom/debug/index.html b/latest/docs/misconfiguration/custom/debug/index.html index b1e8ae59f3..ae8a8eb829 100644 --- a/latest/docs/misconfiguration/custom/debug/index.html +++ b/latest/docs/misconfiguration/custom/debug/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/custom/debug/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/custom/debug/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/custom/examples/index.html b/latest/docs/misconfiguration/custom/examples/index.html index 5d62f13785..29d649a065 100644 --- a/latest/docs/misconfiguration/custom/examples/index.html +++ b/latest/docs/misconfiguration/custom/examples/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/custom/examples/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/custom/examples/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/custom/index.html b/latest/docs/misconfiguration/custom/index.html index da9df74d8a..20a86676b7 100644 --- a/latest/docs/misconfiguration/custom/index.html +++ b/latest/docs/misconfiguration/custom/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/misconfiguration/custom/... + Redirecting to ../../../../v0.25.4/docs/misconfiguration/custom/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/custom/testing/index.html b/latest/docs/misconfiguration/custom/testing/index.html index 948afcba56..495c0216de 100644 --- a/latest/docs/misconfiguration/custom/testing/index.html +++ b/latest/docs/misconfiguration/custom/testing/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/custom/testing/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/custom/testing/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/filesystem/index.html b/latest/docs/misconfiguration/filesystem/index.html index fc90a5eaa0..0b0e0bea74 100644 --- a/latest/docs/misconfiguration/filesystem/index.html +++ b/latest/docs/misconfiguration/filesystem/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/misconfiguration/filesystem/... + Redirecting to ../../../../v0.25.4/docs/misconfiguration/filesystem/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/iac/index.html b/latest/docs/misconfiguration/iac/index.html index 58075d8421..16a4f00680 100644 --- a/latest/docs/misconfiguration/iac/index.html +++ b/latest/docs/misconfiguration/iac/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/misconfiguration/iac/... + Redirecting to ../../../../v0.25.4/docs/misconfiguration/iac/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/index.html b/latest/docs/misconfiguration/index.html index 0156b6f5fc..46f65c3adb 100644 --- a/latest/docs/misconfiguration/index.html +++ b/latest/docs/misconfiguration/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/docs/misconfiguration/... + Redirecting to ../../../v0.25.4/docs/misconfiguration/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/options/filter/index.html b/latest/docs/misconfiguration/options/filter/index.html index a9c26eb9fe..0d922c0b33 100644 --- a/latest/docs/misconfiguration/options/filter/index.html +++ b/latest/docs/misconfiguration/options/filter/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/options/filter/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/options/filter/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/options/others/index.html b/latest/docs/misconfiguration/options/others/index.html index 7bd771e647..26b4dec7ad 100644 --- a/latest/docs/misconfiguration/options/others/index.html +++ b/latest/docs/misconfiguration/options/others/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/options/others/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/options/others/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/options/policy/index.html b/latest/docs/misconfiguration/options/policy/index.html index 7741b905c7..01a4272b3b 100644 --- a/latest/docs/misconfiguration/options/policy/index.html +++ b/latest/docs/misconfiguration/options/policy/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/options/policy/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/options/policy/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/options/report/index.html b/latest/docs/misconfiguration/options/report/index.html index 3f4e7c7da6..7fba2fa602 100644 --- a/latest/docs/misconfiguration/options/report/index.html +++ b/latest/docs/misconfiguration/options/report/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/options/report/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/options/report/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/policy/builtin/index.html b/latest/docs/misconfiguration/policy/builtin/index.html index 9e8eb19aa3..cf80785382 100644 --- a/latest/docs/misconfiguration/policy/builtin/index.html +++ b/latest/docs/misconfiguration/policy/builtin/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/policy/builtin/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/policy/builtin/... \ No newline at end of file diff --git a/latest/docs/misconfiguration/policy/exceptions/index.html b/latest/docs/misconfiguration/policy/exceptions/index.html index 5d3e721d24..3ce6d579c8 100644 --- a/latest/docs/misconfiguration/policy/exceptions/index.html +++ b/latest/docs/misconfiguration/policy/exceptions/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/misconfiguration/policy/exceptions/... + Redirecting to ../../../../../v0.25.4/docs/misconfiguration/policy/exceptions/... \ No newline at end of file diff --git a/latest/docs/references/cli/client/index.html b/latest/docs/references/cli/client/index.html index 872f30d8bd..79dcd81c10 100644 --- a/latest/docs/references/cli/client/index.html +++ b/latest/docs/references/cli/client/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/client/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/client/... \ No newline at end of file diff --git a/latest/docs/references/cli/config/index.html b/latest/docs/references/cli/config/index.html index c6f7dc6c94..2914373dc3 100644 --- a/latest/docs/references/cli/config/index.html +++ b/latest/docs/references/cli/config/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/config/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/config/... \ No newline at end of file diff --git a/latest/docs/references/cli/fs/index.html b/latest/docs/references/cli/fs/index.html index 2156e2f2f6..22abe823ab 100644 --- a/latest/docs/references/cli/fs/index.html +++ b/latest/docs/references/cli/fs/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/fs/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/fs/... \ No newline at end of file diff --git a/latest/docs/references/cli/image/index.html b/latest/docs/references/cli/image/index.html index c5a02ee547..256f37b39b 100644 --- a/latest/docs/references/cli/image/index.html +++ b/latest/docs/references/cli/image/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/image/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/image/... \ No newline at end of file diff --git a/latest/docs/references/cli/index.html b/latest/docs/references/cli/index.html index 582e47824f..258ae0987d 100644 --- a/latest/docs/references/cli/index.html +++ b/latest/docs/references/cli/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/references/cli/... + Redirecting to ../../../../v0.25.4/docs/references/cli/... \ No newline at end of file diff --git a/latest/docs/references/cli/plugins/index.html b/latest/docs/references/cli/plugins/index.html index d61ad9604e..701723de2a 100644 --- a/latest/docs/references/cli/plugins/index.html +++ b/latest/docs/references/cli/plugins/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/plugins/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/plugins/... \ No newline at end of file diff --git a/latest/docs/references/cli/repo/index.html b/latest/docs/references/cli/repo/index.html index a88141a3e0..6229c4e07c 100644 --- a/latest/docs/references/cli/repo/index.html +++ b/latest/docs/references/cli/repo/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/repo/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/repo/... \ No newline at end of file diff --git a/latest/docs/references/cli/rootfs/index.html b/latest/docs/references/cli/rootfs/index.html index e220fb8ccd..efb64b14b1 100644 --- a/latest/docs/references/cli/rootfs/index.html +++ b/latest/docs/references/cli/rootfs/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/rootfs/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/rootfs/... \ No newline at end of file diff --git a/latest/docs/references/cli/sbom/index.html b/latest/docs/references/cli/sbom/index.html index 5a9a2448e1..0cd34e81fe 100644 --- a/latest/docs/references/cli/sbom/index.html +++ b/latest/docs/references/cli/sbom/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/sbom/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/sbom/... \ No newline at end of file diff --git a/latest/docs/references/cli/server/index.html b/latest/docs/references/cli/server/index.html index 8b86957cc5..161811a14f 100644 --- a/latest/docs/references/cli/server/index.html +++ b/latest/docs/references/cli/server/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/cli/server/... + Redirecting to ../../../../../v0.25.4/docs/references/cli/server/... \ No newline at end of file diff --git a/latest/docs/references/modes/client-server/index.html b/latest/docs/references/modes/client-server/index.html index 71a074b683..ba008f0564 100644 --- a/latest/docs/references/modes/client-server/index.html +++ b/latest/docs/references/modes/client-server/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/modes/client-server/... + Redirecting to ../../../../../v0.25.4/docs/references/modes/client-server/... \ No newline at end of file diff --git a/latest/docs/references/modes/standalone/index.html b/latest/docs/references/modes/standalone/index.html index d6910168a2..ce5a611a2a 100644 --- a/latest/docs/references/modes/standalone/index.html +++ b/latest/docs/references/modes/standalone/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/references/modes/standalone/... + Redirecting to ../../../../../v0.25.4/docs/references/modes/standalone/... \ No newline at end of file diff --git a/latest/docs/references/troubleshooting/index.html b/latest/docs/references/troubleshooting/index.html index fe2d2c25fe..e6c205c100 100644 --- a/latest/docs/references/troubleshooting/index.html +++ b/latest/docs/references/troubleshooting/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/references/troubleshooting/... + Redirecting to ../../../../v0.25.4/docs/references/troubleshooting/... \ No newline at end of file diff --git a/latest/docs/sbom/cyclonedx/index.html b/latest/docs/sbom/cyclonedx/index.html index 133ec050a7..5420dba60c 100644 --- a/latest/docs/sbom/cyclonedx/index.html +++ b/latest/docs/sbom/cyclonedx/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/sbom/cyclonedx/... + Redirecting to ../../../../v0.25.4/docs/sbom/cyclonedx/... \ No newline at end of file diff --git a/latest/docs/sbom/index.html b/latest/docs/sbom/index.html index 661c1472fe..d2439e52eb 100644 --- a/latest/docs/sbom/index.html +++ b/latest/docs/sbom/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/docs/sbom/... + Redirecting to ../../../v0.25.4/docs/sbom/... \ No newline at end of file diff --git a/latest/docs/vulnerability/detection/data-source/index.html b/latest/docs/vulnerability/detection/data-source/index.html index f1cfcb1125..d759bfafbf 100644 --- a/latest/docs/vulnerability/detection/data-source/index.html +++ b/latest/docs/vulnerability/detection/data-source/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/detection/data-source/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/detection/data-source/... \ No newline at end of file diff --git a/latest/docs/vulnerability/detection/language/index.html b/latest/docs/vulnerability/detection/language/index.html index 8234ccc39a..76baa4a471 100644 --- a/latest/docs/vulnerability/detection/language/index.html +++ b/latest/docs/vulnerability/detection/language/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/detection/language/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/detection/language/... \ No newline at end of file diff --git a/latest/docs/vulnerability/detection/os/index.html b/latest/docs/vulnerability/detection/os/index.html index 7fd07b12b9..3c9d3972c9 100644 --- a/latest/docs/vulnerability/detection/os/index.html +++ b/latest/docs/vulnerability/detection/os/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/detection/os/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/detection/os/... \ No newline at end of file diff --git a/latest/docs/vulnerability/detection/supported/index.html b/latest/docs/vulnerability/detection/supported/index.html index 0c2c3540ef..2e4b195498 100644 --- a/latest/docs/vulnerability/detection/supported/index.html +++ b/latest/docs/vulnerability/detection/supported/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/detection/supported/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/detection/supported/... \ No newline at end of file diff --git a/latest/docs/vulnerability/examples/cache/index.html b/latest/docs/vulnerability/examples/cache/index.html index b5b08205f0..2f26651fe4 100644 --- a/latest/docs/vulnerability/examples/cache/index.html +++ b/latest/docs/vulnerability/examples/cache/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/examples/cache/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/examples/cache/... \ No newline at end of file diff --git a/latest/docs/vulnerability/examples/db/index.html b/latest/docs/vulnerability/examples/db/index.html index 5affa9d1a3..e25676adb5 100644 --- a/latest/docs/vulnerability/examples/db/index.html +++ b/latest/docs/vulnerability/examples/db/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/examples/db/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/examples/db/... \ No newline at end of file diff --git a/latest/docs/vulnerability/examples/filter/index.html b/latest/docs/vulnerability/examples/filter/index.html index 1502e6129d..68daf17081 100644 --- a/latest/docs/vulnerability/examples/filter/index.html +++ b/latest/docs/vulnerability/examples/filter/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/examples/filter/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/examples/filter/... \ No newline at end of file diff --git a/latest/docs/vulnerability/examples/others/index.html b/latest/docs/vulnerability/examples/others/index.html index f408ddda82..42008bd0f3 100644 --- a/latest/docs/vulnerability/examples/others/index.html +++ b/latest/docs/vulnerability/examples/others/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/examples/others/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/examples/others/... \ No newline at end of file diff --git a/latest/docs/vulnerability/examples/report/index.html b/latest/docs/vulnerability/examples/report/index.html index 16af98da37..3d69b2c4b7 100644 --- a/latest/docs/vulnerability/examples/report/index.html +++ b/latest/docs/vulnerability/examples/report/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/examples/report/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/examples/report/... \ No newline at end of file diff --git a/latest/docs/vulnerability/scanning/filesystem/index.html b/latest/docs/vulnerability/scanning/filesystem/index.html index fb146ce281..8a6da85b67 100644 --- a/latest/docs/vulnerability/scanning/filesystem/index.html +++ b/latest/docs/vulnerability/scanning/filesystem/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/scanning/filesystem/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/scanning/filesystem/... \ No newline at end of file diff --git a/latest/docs/vulnerability/scanning/git-repository/index.html b/latest/docs/vulnerability/scanning/git-repository/index.html index 549d749ed6..cb137a106b 100644 --- a/latest/docs/vulnerability/scanning/git-repository/index.html +++ b/latest/docs/vulnerability/scanning/git-repository/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/scanning/git-repository/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/scanning/git-repository/... \ No newline at end of file diff --git a/latest/docs/vulnerability/scanning/image/index.html b/latest/docs/vulnerability/scanning/image/index.html index 5f16fb754d..893573ef97 100644 --- a/latest/docs/vulnerability/scanning/image/index.html +++ b/latest/docs/vulnerability/scanning/image/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/scanning/image/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/scanning/image/... \ No newline at end of file diff --git a/latest/docs/vulnerability/scanning/index.html b/latest/docs/vulnerability/scanning/index.html index 6788101e91..72769e92a8 100644 --- a/latest/docs/vulnerability/scanning/index.html +++ b/latest/docs/vulnerability/scanning/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../v0.25.3/docs/vulnerability/scanning/... + Redirecting to ../../../../v0.25.4/docs/vulnerability/scanning/... \ No newline at end of file diff --git a/latest/docs/vulnerability/scanning/rootfs/index.html b/latest/docs/vulnerability/scanning/rootfs/index.html index 17d3f4d112..a4cba82faf 100644 --- a/latest/docs/vulnerability/scanning/rootfs/index.html +++ b/latest/docs/vulnerability/scanning/rootfs/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../../../v0.25.3/docs/vulnerability/scanning/rootfs/... + Redirecting to ../../../../../v0.25.4/docs/vulnerability/scanning/rootfs/... \ No newline at end of file diff --git a/latest/getting-started/further/index.html b/latest/getting-started/further/index.html index 03ddd34799..bef2d686f1 100644 --- a/latest/getting-started/further/index.html +++ b/latest/getting-started/further/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/getting-started/further/... + Redirecting to ../../../v0.25.4/getting-started/further/... \ No newline at end of file diff --git a/latest/getting-started/installation/index.html b/latest/getting-started/installation/index.html index 19d3688925..6c711132bf 100644 --- a/latest/getting-started/installation/index.html +++ b/latest/getting-started/installation/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/getting-started/installation/... + Redirecting to ../../../v0.25.4/getting-started/installation/... \ No newline at end of file diff --git a/latest/getting-started/overview/index.html b/latest/getting-started/overview/index.html index 5f8e5e417d..e79b84e932 100644 --- a/latest/getting-started/overview/index.html +++ b/latest/getting-started/overview/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/getting-started/overview/... + Redirecting to ../../../v0.25.4/getting-started/overview/... \ No newline at end of file diff --git a/latest/getting-started/quickstart/index.html b/latest/getting-started/quickstart/index.html index fbf1004608..873e3534ea 100644 --- a/latest/getting-started/quickstart/index.html +++ b/latest/getting-started/quickstart/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../../../v0.25.3/getting-started/quickstart/... + Redirecting to ../../../v0.25.4/getting-started/quickstart/... \ No newline at end of file diff --git a/latest/index.html b/latest/index.html index 7be495318d..e350bca119 100644 --- a/latest/index.html +++ b/latest/index.html @@ -4,13 +4,13 @@ Redirecting - Redirecting to ../v0.25.3/... + Redirecting to ../v0.25.4/... \ No newline at end of file diff --git a/v0.25.4/404.html b/v0.25.4/404.html new file mode 100644 index 0000000000..74e92ad4fe --- /dev/null +++ b/v0.25.4/404.html @@ -0,0 +1,2966 @@ + + + + + + + + + + + + + + + + + + + + + Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ +

404 - Not found

+ +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/assets/images/favicon.png b/v0.25.4/assets/images/favicon.png new file mode 100644 index 0000000000..1cf13b9f9d Binary files /dev/null and b/v0.25.4/assets/images/favicon.png differ diff --git a/v0.25.4/assets/javascripts/bundle.c07a5e79.min.js b/v0.25.4/assets/javascripts/bundle.c07a5e79.min.js new file mode 100644 index 0000000000..7caca0014f --- /dev/null +++ b/v0.25.4/assets/javascripts/bundle.c07a5e79.min.js @@ -0,0 +1,3 @@ +(()=>{var aa=Object.create;var wr=Object.defineProperty;var sa=Object.getOwnPropertyDescriptor;var ca=Object.getOwnPropertyNames,At=Object.getOwnPropertySymbols,ua=Object.getPrototypeOf,Er=Object.prototype.hasOwnProperty,cn=Object.prototype.propertyIsEnumerable;var sn=(e,t,r)=>t in e?wr(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,H=(e,t)=>{for(var r in t||(t={}))Er.call(t,r)&&sn(e,r,t[r]);if(At)for(var r of At(t))cn.call(t,r)&&sn(e,r,t[r]);return e};var un=(e,t)=>{var r={};for(var n in e)Er.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&At)for(var n of At(e))t.indexOf(n)<0&&cn.call(e,n)&&(r[n]=e[n]);return r};var vt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var fa=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of ca(t))!Er.call(e,o)&&o!==r&&wr(e,o,{get:()=>t[o],enumerable:!(n=sa(t,o))||n.enumerable});return e};var et=(e,t,r)=>(r=e!=null?aa(ua(e)):{},fa(t||!e||!e.__esModule?wr(r,"default",{value:e,enumerable:!0}):r,e));var pn=vt((Sr,fn)=>{(function(e,t){typeof Sr=="object"&&typeof fn!="undefined"?t():typeof define=="function"&&define.amd?define(t):t()})(Sr,function(){"use strict";function e(r){var n=!0,o=!1,i=null,a={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function c(_){return!!(_&&_!==document&&_.nodeName!=="HTML"&&_.nodeName!=="BODY"&&"classList"in _&&"contains"in _.classList)}function s(_){var Ue=_.type,be=_.tagName;return!!(be==="INPUT"&&a[Ue]&&!_.readOnly||be==="TEXTAREA"&&!_.readOnly||_.isContentEditable)}function u(_){_.classList.contains("focus-visible")||(_.classList.add("focus-visible"),_.setAttribute("data-focus-visible-added",""))}function f(_){!_.hasAttribute("data-focus-visible-added")||(_.classList.remove("focus-visible"),_.removeAttribute("data-focus-visible-added"))}function p(_){_.metaKey||_.altKey||_.ctrlKey||(c(r.activeElement)&&u(r.activeElement),n=!0)}function l(_){n=!1}function d(_){!c(_.target)||(n||s(_.target))&&u(_.target)}function h(_){!c(_.target)||(_.target.classList.contains("focus-visible")||_.target.hasAttribute("data-focus-visible-added"))&&(o=!0,window.clearTimeout(i),i=window.setTimeout(function(){o=!1},100),f(_.target))}function b(_){document.visibilityState==="hidden"&&(o&&(n=!0),F())}function F(){document.addEventListener("mousemove",U),document.addEventListener("mousedown",U),document.addEventListener("mouseup",U),document.addEventListener("pointermove",U),document.addEventListener("pointerdown",U),document.addEventListener("pointerup",U),document.addEventListener("touchmove",U),document.addEventListener("touchstart",U),document.addEventListener("touchend",U)}function Y(){document.removeEventListener("mousemove",U),document.removeEventListener("mousedown",U),document.removeEventListener("mouseup",U),document.removeEventListener("pointermove",U),document.removeEventListener("pointerdown",U),document.removeEventListener("pointerup",U),document.removeEventListener("touchmove",U),document.removeEventListener("touchstart",U),document.removeEventListener("touchend",U)}function U(_){_.target.nodeName&&_.target.nodeName.toLowerCase()==="html"||(n=!1,Y())}document.addEventListener("keydown",p,!0),document.addEventListener("mousedown",l,!0),document.addEventListener("pointerdown",l,!0),document.addEventListener("touchstart",l,!0),document.addEventListener("visibilitychange",b,!0),F(),r.addEventListener("focus",d,!0),r.addEventListener("blur",h,!0),r.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&r.host?r.host.setAttribute("data-js-focus-visible",""):r.nodeType===Node.DOCUMENT_NODE&&(document.documentElement.classList.add("js-focus-visible"),document.documentElement.setAttribute("data-js-focus-visible",""))}if(typeof window!="undefined"&&typeof document!="undefined"){window.applyFocusVisiblePolyfill=e;var t;try{t=new CustomEvent("focus-visible-polyfill-ready")}catch(r){t=document.createEvent("CustomEvent"),t.initCustomEvent("focus-visible-polyfill-ready",!1,!1,{})}window.dispatchEvent(t)}typeof document!="undefined"&&e(document)})});var ln=vt(Or=>{(function(e){var t=function(){try{return!!Symbol.iterator}catch(u){return!1}},r=t(),n=function(u){var f={next:function(){var p=u.shift();return{done:p===void 0,value:p}}};return r&&(f[Symbol.iterator]=function(){return f}),f},o=function(u){return encodeURIComponent(u).replace(/%20/g,"+")},i=function(u){return decodeURIComponent(String(u).replace(/\+/g," "))},a=function(){var u=function(p){Object.defineProperty(this,"_entries",{writable:!0,value:{}});var l=typeof p;if(l!=="undefined")if(l==="string")p!==""&&this._fromString(p);else if(p instanceof u){var d=this;p.forEach(function(Y,U){d.append(U,Y)})}else if(p!==null&&l==="object")if(Object.prototype.toString.call(p)==="[object Array]")for(var h=0;hd[0]?1:0}),u._entries&&(u._entries={});for(var p=0;p1?i(d[1]):"")}})})(typeof global!="undefined"?global:typeof window!="undefined"?window:typeof self!="undefined"?self:Or);(function(e){var t=function(){try{var o=new e.URL("b","http://a");return o.pathname="c d",o.href==="http://a/c%20d"&&o.searchParams}catch(i){return!1}},r=function(){var o=e.URL,i=function(s,u){typeof s!="string"&&(s=String(s)),u&&typeof u!="string"&&(u=String(u));var f=document,p;if(u&&(e.location===void 0||u!==e.location.href)){u=u.toLowerCase(),f=document.implementation.createHTMLDocument(""),p=f.createElement("base"),p.href=u,f.head.appendChild(p);try{if(p.href.indexOf(u)!==0)throw new Error(p.href)}catch(_){throw new Error("URL unable to set base "+u+" due to "+_)}}var l=f.createElement("a");l.href=s,p&&(f.body.appendChild(l),l.href=l.href);var d=f.createElement("input");if(d.type="url",d.value=s,l.protocol===":"||!/:/.test(l.href)||!d.checkValidity()&&!u)throw new TypeError("Invalid URL");Object.defineProperty(this,"_anchorElement",{value:l});var h=new e.URLSearchParams(this.search),b=!0,F=!0,Y=this;["append","delete","set"].forEach(function(_){var Ue=h[_];h[_]=function(){Ue.apply(h,arguments),b&&(F=!1,Y.search=h.toString(),F=!0)}}),Object.defineProperty(this,"searchParams",{value:h,enumerable:!0});var U=void 0;Object.defineProperty(this,"_updateSearchParams",{enumerable:!1,configurable:!1,writable:!1,value:function(){this.search!==U&&(U=this.search,F&&(b=!1,this.searchParams._fromString(this.search),b=!0))}})},a=i.prototype,c=function(s){Object.defineProperty(a,s,{get:function(){return this._anchorElement[s]},set:function(u){this._anchorElement[s]=u},enumerable:!0})};["hash","host","hostname","port","protocol"].forEach(function(s){c(s)}),Object.defineProperty(a,"search",{get:function(){return this._anchorElement.search},set:function(s){this._anchorElement.search=s,this._updateSearchParams()},enumerable:!0}),Object.defineProperties(a,{toString:{get:function(){var s=this;return function(){return s.href}}},href:{get:function(){return this._anchorElement.href.replace(/\?$/,"")},set:function(s){this._anchorElement.href=s,this._updateSearchParams()},enumerable:!0},pathname:{get:function(){return this._anchorElement.pathname.replace(/(^\/?)/,"/")},set:function(s){this._anchorElement.pathname=s},enumerable:!0},origin:{get:function(){var s={"http:":80,"https:":443,"ftp:":21}[this._anchorElement.protocol],u=this._anchorElement.port!=s&&this._anchorElement.port!=="";return this._anchorElement.protocol+"//"+this._anchorElement.hostname+(u?":"+this._anchorElement.port:"")},enumerable:!0},password:{get:function(){return""},set:function(s){},enumerable:!0},username:{get:function(){return""},set:function(s){},enumerable:!0}}),i.createObjectURL=function(s){return o.createObjectURL.apply(o,arguments)},i.revokeObjectURL=function(s){return o.revokeObjectURL.apply(o,arguments)},e.URL=i};if(t()||r(),e.location!==void 0&&!("origin"in e.location)){var n=function(){return e.location.protocol+"//"+e.location.hostname+(e.location.port?":"+e.location.port:"")};try{Object.defineProperty(e.location,"origin",{get:n,enumerable:!0})}catch(o){setInterval(function(){e.location.origin=n()},100)}}})(typeof global!="undefined"?global:typeof window!="undefined"?window:typeof self!="undefined"?self:Or)});var Hn=vt((Qs,kt)=>{var mn,dn,hn,bn,vn,gn,yn,xn,wn,Ct,_r,En,Sn,On,tt,_n,Tn,Mn,Ln,An,Cn,Rn,kn,Rt;(function(e){var t=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(n){e(r(t,r(n)))}):typeof kt=="object"&&typeof kt.exports=="object"?e(r(t,r(kt.exports))):e(r(t));function r(n,o){return n!==t&&(typeof Object.create=="function"?Object.defineProperty(n,"__esModule",{value:!0}):n.__esModule=!0),function(i,a){return n[i]=o?o(i,a):a}}})(function(e){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var i in o)Object.prototype.hasOwnProperty.call(o,i)&&(n[i]=o[i])};mn=function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");t(n,o);function i(){this.constructor=n}n.prototype=o===null?Object.create(o):(i.prototype=o.prototype,new i)},dn=Object.assign||function(n){for(var o,i=1,a=arguments.length;i=0;f--)(u=n[f])&&(s=(c<3?u(s):c>3?u(o,i,s):u(o,i))||s);return c>3&&s&&Object.defineProperty(o,i,s),s},vn=function(n,o){return function(i,a){o(i,a,n)}},gn=function(n,o){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(n,o)},yn=function(n,o,i,a){function c(s){return s instanceof i?s:new i(function(u){u(s)})}return new(i||(i=Promise))(function(s,u){function f(d){try{l(a.next(d))}catch(h){u(h)}}function p(d){try{l(a.throw(d))}catch(h){u(h)}}function l(d){d.done?s(d.value):c(d.value).then(f,p)}l((a=a.apply(n,o||[])).next())})},xn=function(n,o){var i={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},a,c,s,u;return u={next:f(0),throw:f(1),return:f(2)},typeof Symbol=="function"&&(u[Symbol.iterator]=function(){return this}),u;function f(l){return function(d){return p([l,d])}}function p(l){if(a)throw new TypeError("Generator is already executing.");for(;i;)try{if(a=1,c&&(s=l[0]&2?c.return:l[0]?c.throw||((s=c.return)&&s.call(c),0):c.next)&&!(s=s.call(c,l[1])).done)return s;switch(c=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,c=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(s=i.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){i=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]=n.length&&(n=void 0),{value:n&&n[a++],done:!n}}};throw new TypeError(o?"Object is not iterable.":"Symbol.iterator is not defined.")},_r=function(n,o){var i=typeof Symbol=="function"&&n[Symbol.iterator];if(!i)return n;var a=i.call(n),c,s=[],u;try{for(;(o===void 0||o-- >0)&&!(c=a.next()).done;)s.push(c.value)}catch(f){u={error:f}}finally{try{c&&!c.done&&(i=a.return)&&i.call(a)}finally{if(u)throw u.error}}return s},En=function(){for(var n=[],o=0;o1||f(b,F)})})}function f(b,F){try{p(a[b](F))}catch(Y){h(s[0][3],Y)}}function p(b){b.value instanceof tt?Promise.resolve(b.value.v).then(l,d):h(s[0][2],b)}function l(b){f("next",b)}function d(b){f("throw",b)}function h(b,F){b(F),s.shift(),s.length&&f(s[0][0],s[0][1])}},Tn=function(n){var o,i;return o={},a("next"),a("throw",function(c){throw c}),a("return"),o[Symbol.iterator]=function(){return this},o;function a(c,s){o[c]=n[c]?function(u){return(i=!i)?{value:tt(n[c](u)),done:c==="return"}:s?s(u):u}:s}},Mn=function(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var o=n[Symbol.asyncIterator],i;return o?o.call(n):(n=typeof Ct=="function"?Ct(n):n[Symbol.iterator](),i={},a("next"),a("throw"),a("return"),i[Symbol.asyncIterator]=function(){return this},i);function a(s){i[s]=n[s]&&function(u){return new Promise(function(f,p){u=n[s](u),c(f,p,u.done,u.value)})}}function c(s,u,f,p){Promise.resolve(p).then(function(l){s({value:l,done:f})},u)}},Ln=function(n,o){return Object.defineProperty?Object.defineProperty(n,"raw",{value:o}):n.raw=o,n};var r=Object.create?function(n,o){Object.defineProperty(n,"default",{enumerable:!0,value:o})}:function(n,o){n.default=o};An=function(n){if(n&&n.__esModule)return n;var o={};if(n!=null)for(var i in n)i!=="default"&&Object.prototype.hasOwnProperty.call(n,i)&&Rt(o,n,i);return r(o,n),o},Cn=function(n){return n&&n.__esModule?n:{default:n}},Rn=function(n,o,i,a){if(i==="a"&&!a)throw new TypeError("Private accessor was defined without a getter");if(typeof o=="function"?n!==o||!a:!o.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?a:i==="a"?a.call(n):a?a.value:o.get(n)},kn=function(n,o,i,a,c){if(a==="m")throw new TypeError("Private method is not writable");if(a==="a"&&!c)throw new TypeError("Private accessor was defined without a setter");if(typeof o=="function"?n!==o||!c:!o.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return a==="a"?c.call(n,i):c?c.value=i:o.set(n,i),i},e("__extends",mn),e("__assign",dn),e("__rest",hn),e("__decorate",bn),e("__param",vn),e("__metadata",gn),e("__awaiter",yn),e("__generator",xn),e("__exportStar",wn),e("__createBinding",Rt),e("__values",Ct),e("__read",_r),e("__spread",En),e("__spreadArrays",Sn),e("__spreadArray",On),e("__await",tt),e("__asyncGenerator",_n),e("__asyncDelegator",Tn),e("__asyncValues",Mn),e("__makeTemplateObject",Ln),e("__importStar",An),e("__importDefault",Cn),e("__classPrivateFieldGet",Rn),e("__classPrivateFieldSet",kn)})});var Xr=vt((Tt,Jr)=>{(function(t,r){typeof Tt=="object"&&typeof Jr=="object"?Jr.exports=r():typeof define=="function"&&define.amd?define([],r):typeof Tt=="object"?Tt.ClipboardJS=r():t.ClipboardJS=r()})(Tt,function(){return function(){var e={686:function(n,o,i){"use strict";i.d(o,{default:function(){return ia}});var a=i(279),c=i.n(a),s=i(370),u=i.n(s),f=i(817),p=i.n(f);function l(I){try{return document.execCommand(I)}catch(A){return!1}}var d=function(A){var O=p()(A);return l("cut"),O},h=d;function b(I){var A=document.documentElement.getAttribute("dir")==="rtl",O=document.createElement("textarea");O.style.fontSize="12pt",O.style.border="0",O.style.padding="0",O.style.margin="0",O.style.position="absolute",O.style[A?"right":"left"]="-9999px";var W=window.pageYOffset||document.documentElement.scrollTop;return O.style.top="".concat(W,"px"),O.setAttribute("readonly",""),O.value=I,O}var F=function(A){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body},W="";if(typeof A=="string"){var k=b(A);O.container.appendChild(k),W=p()(k),l("copy"),k.remove()}else W=p()(A),l("copy");return W},Y=F;function U(I){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?U=function(O){return typeof O}:U=function(O){return O&&typeof Symbol=="function"&&O.constructor===Symbol&&O!==Symbol.prototype?"symbol":typeof O},U(I)}var _=function(){var A=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},O=A.action,W=O===void 0?"copy":O,k=A.container,z=A.target,Te=A.text;if(W!=="copy"&&W!=="cut")throw new Error('Invalid "action" value, use either "copy" or "cut"');if(z!==void 0)if(z&&U(z)==="object"&&z.nodeType===1){if(W==="copy"&&z.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if(W==="cut"&&(z.hasAttribute("readonly")||z.hasAttribute("disabled")))throw new Error(`Invalid "target" attribute. You can't cut text from elements with "readonly" or "disabled" attributes`)}else throw new Error('Invalid "target" value, use a valid Element');if(Te)return Y(Te,{container:k});if(z)return W==="cut"?h(z):Y(z,{container:k})},Ue=_;function be(I){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?be=function(O){return typeof O}:be=function(O){return O&&typeof Symbol=="function"&&O.constructor===Symbol&&O!==Symbol.prototype?"symbol":typeof O},be(I)}function Ze(I,A){if(!(I instanceof A))throw new TypeError("Cannot call a class as a function")}function an(I,A){for(var O=0;O0&&arguments[0]!==void 0?arguments[0]:{};this.action=typeof k.action=="function"?k.action:this.defaultAction,this.target=typeof k.target=="function"?k.target:this.defaultTarget,this.text=typeof k.text=="function"?k.text:this.defaultText,this.container=be(k.container)==="object"?k.container:document.body}},{key:"listenClick",value:function(k){var z=this;this.listener=u()(k,"click",function(Te){return z.onClick(Te)})}},{key:"onClick",value:function(k){var z=k.delegateTarget||k.currentTarget,Te=this.action(z)||"copy",Lt=Ue({action:Te,container:this.container,target:this.target(z),text:this.text(z)});this.emit(Lt?"success":"error",{action:Te,text:Lt,trigger:z,clearSelection:function(){z&&z.focus(),document.activeElement.blur(),window.getSelection().removeAllRanges()}})}},{key:"defaultAction",value:function(k){return xr("action",k)}},{key:"defaultTarget",value:function(k){var z=xr("target",k);if(z)return document.querySelector(z)}},{key:"defaultText",value:function(k){return xr("text",k)}},{key:"destroy",value:function(){this.listener.destroy()}}],[{key:"copy",value:function(k){var z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body};return Y(k,z)}},{key:"cut",value:function(k){return h(k)}},{key:"isSupported",value:function(){var k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:["copy","cut"],z=typeof k=="string"?[k]:k,Te=!!document.queryCommandSupported;return z.forEach(function(Lt){Te=Te&&!!document.queryCommandSupported(Lt)}),Te}}]),O}(c()),ia=oa},828:function(n){var o=9;if(typeof Element!="undefined"&&!Element.prototype.matches){var i=Element.prototype;i.matches=i.matchesSelector||i.mozMatchesSelector||i.msMatchesSelector||i.oMatchesSelector||i.webkitMatchesSelector}function a(c,s){for(;c&&c.nodeType!==o;){if(typeof c.matches=="function"&&c.matches(s))return c;c=c.parentNode}}n.exports=a},438:function(n,o,i){var a=i(828);function c(f,p,l,d,h){var b=u.apply(this,arguments);return f.addEventListener(l,b,h),{destroy:function(){f.removeEventListener(l,b,h)}}}function s(f,p,l,d,h){return typeof f.addEventListener=="function"?c.apply(null,arguments):typeof l=="function"?c.bind(null,document).apply(null,arguments):(typeof f=="string"&&(f=document.querySelectorAll(f)),Array.prototype.map.call(f,function(b){return c(b,p,l,d,h)}))}function u(f,p,l,d){return function(h){h.delegateTarget=a(h.target,p),h.delegateTarget&&d.call(f,h)}}n.exports=s},879:function(n,o){o.node=function(i){return i!==void 0&&i instanceof HTMLElement&&i.nodeType===1},o.nodeList=function(i){var a=Object.prototype.toString.call(i);return i!==void 0&&(a==="[object NodeList]"||a==="[object HTMLCollection]")&&"length"in i&&(i.length===0||o.node(i[0]))},o.string=function(i){return typeof i=="string"||i instanceof String},o.fn=function(i){var a=Object.prototype.toString.call(i);return a==="[object Function]"}},370:function(n,o,i){var a=i(879),c=i(438);function s(l,d,h){if(!l&&!d&&!h)throw new Error("Missing required arguments");if(!a.string(d))throw new TypeError("Second argument must be a String");if(!a.fn(h))throw new TypeError("Third argument must be a Function");if(a.node(l))return u(l,d,h);if(a.nodeList(l))return f(l,d,h);if(a.string(l))return p(l,d,h);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function u(l,d,h){return l.addEventListener(d,h),{destroy:function(){l.removeEventListener(d,h)}}}function f(l,d,h){return Array.prototype.forEach.call(l,function(b){b.addEventListener(d,h)}),{destroy:function(){Array.prototype.forEach.call(l,function(b){b.removeEventListener(d,h)})}}}function p(l,d,h){return c(document.body,l,d,h)}n.exports=s},817:function(n){function o(i){var a;if(i.nodeName==="SELECT")i.focus(),a=i.value;else if(i.nodeName==="INPUT"||i.nodeName==="TEXTAREA"){var c=i.hasAttribute("readonly");c||i.setAttribute("readonly",""),i.select(),i.setSelectionRange(0,i.value.length),c||i.removeAttribute("readonly"),a=i.value}else{i.hasAttribute("contenteditable")&&i.focus();var s=window.getSelection(),u=document.createRange();u.selectNodeContents(i),s.removeAllRanges(),s.addRange(u),a=s.toString()}return a}n.exports=o},279:function(n){function o(){}o.prototype={on:function(i,a,c){var s=this.e||(this.e={});return(s[i]||(s[i]=[])).push({fn:a,ctx:c}),this},once:function(i,a,c){var s=this;function u(){s.off(i,u),a.apply(c,arguments)}return u._=a,this.on(i,u,c)},emit:function(i){var a=[].slice.call(arguments,1),c=((this.e||(this.e={}))[i]||[]).slice(),s=0,u=c.length;for(s;s{"use strict";var Ms=/["'&<>]/;Oi.exports=Ls;function Ls(e){var t=""+e,r=Ms.exec(t);if(!r)return t;var n,o="",i=0,a=0;for(i=r.index;i{function e(o,i){parent.postMessage(o,i||"*")}function t(...o){return o.reduce((i,a)=>i.then(()=>new Promise(c=>{let s=document.createElement("script");s.src=a,s.addEventListener("load",()=>c()),document.body.appendChild(s)})),Promise.resolve())}function r(){let o=document.createElement("iframe");return o.width=o.height=o.frameBorder="0",o}var n=class{constructor(o,i){if(this.url=o,this.onerror=null,this.onmessage=null,this.onmessageerror=null,this.handleMessage=c=>{c.source===this.worker&&(c.stopImmediatePropagation(),this.dispatchEvent(new MessageEvent("message",{data:c.data})),this.onmessage&&this.onmessage(c))},this.handleError=(c,s,u,f,p)=>{if(s===this.url.toString()){let l=new ErrorEvent("error",{message:c,filename:s,lineno:u,colno:f,error:p});this.dispatchEvent(l),this.onerror&&this.onerror(l)}},typeof i!="undefined")throw new TypeError("Options are not supported for iframe workers");let a=new EventTarget;this.addEventListener=a.addEventListener.bind(a),this.removeEventListener=a.removeEventListener.bind(a),this.dispatchEvent=a.dispatchEvent.bind(a),document.body.appendChild(this.iframe=r()),this.worker.document.open(),this.worker.document.write(` + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+ + +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/contribute/issue/index.html b/v0.25.4/community/contribute/issue/index.html new file mode 100644 index 0000000000..52c1690627 --- /dev/null +++ b/v0.25.4/community/contribute/issue/index.html @@ -0,0 +1,3032 @@ + + + + + + + + + + + + + + + + + + + + + + + Issues - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Issues

+ +

Thank you for taking interest in contributing to Trivy!

+
    +
  • Feel free to open issues for any reason. When you open a new issue, you'll have to select an issue kind: bug/feature/support and fill the required information based on the selected template.
  • +
  • Please spend a small amount of time giving due diligence to the issue tracker. Your issue might be a duplicate. If it is, please add your comment to the existing issue.
  • +
  • Remember that users might search for your issue in the future, so please give it a meaningful title to help others.
  • +
  • The issue should clearly explain the reason for opening, the proposal if you have any, and any relevant technical information.
  • +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/contribute/pr/index.html b/v0.25.4/community/contribute/pr/index.html new file mode 100644 index 0000000000..1a46acfea5 --- /dev/null +++ b/v0.25.4/community/contribute/pr/index.html @@ -0,0 +1,3277 @@ + + + + + + + + + + + + + + + + + + + + + + + Pull Requests - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Pull Requests

+ +

Thank you for taking interest in contributing to Trivy!

+
    +
  1. Every Pull Request should have an associated bug or feature issue unless you are fixing a trivial documentation issue.
  2. +
  3. Please add the associated Issue link in the PR description.
  4. +
  5. Your PR is more likely to be accepted if it focuses on just one change.
  6. +
  7. There's no need to add or tag reviewers.
  8. +
  9. If a reviewer commented on your code or asked for changes, please remember to respond with comment. Do not mark discussion as resolved. It's up to reviewer to mark it resolved (in case if suggested fix addresses problem properly). PRs with unresolved issues should not be merged (even if the comment is unclear or requires no action from your side).
  10. +
  11. Please include a comment with the results before and after your change.
  12. +
  13. Your PR is more likely to be accepted if it includes tests (We have not historically been very strict about tests, but we would like to improve this!).
  14. +
  15. If your PR affects the user experience in some way, please update the README.md and the CLI help accordingly.
  16. +
+

Title

+

It is not that strict, but we use the title conventions in this repository. +Each commit message doesn't have to follow the conventions as long as it is clear and descriptive since it will be squashed and merged.

+

Format of the title

+
<type>(<scope>): <subject>
+
+

The type and scope should always be lowercase as shown below.

+

Allowed <type> values:

+
    +
  • feat for a new feature for the user, not a new feature for build script. Such commit will trigger a release bumping a MINOR version.
  • +
  • fix for a bug fix for the user, not a fix to a build script. Such commit will trigger a release bumping a PATCH version.
  • +
  • perf for performance improvements. Such commit will trigger a release bumping a PATCH version.
  • +
  • docs for changes to the documentation.
  • +
  • style for formatting changes, missing semicolons, etc.
  • +
  • refactor for refactoring production code, e.g. renaming a variable.
  • +
  • test for adding missing tests, refactoring tests; no production code change.
  • +
  • build for updating build configuration, development tools or other changes irrelevant to the user.
  • +
  • chore for updates that do not apply to the above, such as dependency updates.
  • +
+

Example <scope> values:

+
    +
  • alpine
  • +
  • redhat
  • +
  • ruby
  • +
  • python
  • +
  • terraform
  • +
  • report
  • +
  • etc.
  • +
+

The <scope> can be empty (e.g. if the change is a global or difficult to assign to a single component), in which case the parentheses are omitted.

+

Example titles

+
feat(alma): add support for AlmaLinux
+
+
fix(oracle): handle advisories with ksplice versions
+
+
docs(misconf): add comparison with Conftest and TFsec
+
+
chore(deps): bump go.uber.org/zap from 1.19.1 to 1.20.0
+
+

NOTE: please do not use chore(deps): update fanal and something like that if you add new features or fix bugs in Trivy-related projects. +The PR title should describe what the PR adds or fixes even though it just updates the dependency in Trivy.

+

Unit tests

+

Your PR must pass all the unit tests. You can test it as below.

+
$ make test
+
+

Integration tests

+

Your PR must pass all the integration tests. You can test it as below.

+
$ make test-integration
+
+

Documentation

+

You can build the documents as below and view it at http://localhost:8000.

+
$ make mkdocs-serve
+
+

Understand where your pull request belongs

+

Trivy is composed of several repositories that work together:

+
    +
  • Trivy is the client-side, user-facing, command line tool.
  • +
  • vuln-list is a vulnerabilities database, aggregated from different sources, and normalized for easy consumption. Think of this as the "server" side of the trivy command line tool. There should be no pull requests to this repo
  • +
  • vuln-list-update is the code that maintains the vuln-list database.
  • +
  • trivy-db maintains the vulnerability database pulled by Trivy CLI.
  • +
  • fanal is a library for extracting system information from containers. It is being used by Trivy to find testable subjects in the container image.
  • +
  • go-dep-parser is a library for parsing lock files such as package-lock.json and Gemfile.lock.
  • +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/credit/index.html b/v0.25.4/community/credit/index.html new file mode 100644 index 0000000000..bdd3f2dcba --- /dev/null +++ b/v0.25.4/community/credit/index.html @@ -0,0 +1,3034 @@ + + + + + + + + + + + + + + + + + + + + + + + Credits - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+ + +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/maintainer/help-wanted/index.html b/v0.25.4/community/maintainer/help-wanted/index.html new file mode 100644 index 0000000000..950e30875a --- /dev/null +++ b/v0.25.4/community/maintainer/help-wanted/index.html @@ -0,0 +1,3174 @@ + + + + + + + + + + + + + + + + + + + + + + + Help Wanted - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Overview

+

We use two labels help wanted and good first +issue to identify issues that have been specially groomed +for new contributors. The good first issue label is a subset of help wanted +label, indicating that members have committed to providing extra assistance for +new contributors. All good first issue items also have the help wanted +label.

+

Help Wanted

+

Items marked with the help wanted label need to ensure that they are:

+
    +
  • Low Barrier to Entry
  • +
+

It should be tractable for new contributors. Documentation on how that type of + change should be made should already exist.

+
    +
  • Clear Task
  • +
+

The task is agreed upon and does not require further discussions in the + community. Call out if that area of code is untested and requires new + fixtures.

+

API / CLI behavior is decided and included in the OP issue, for example: "The + new command syntax is trivy --format yaml IMAGE_NAME"_ with + expected validations called out.

+
    +
  • Goldilocks priority
  • +
+

Not too high that a core contributor should do it, but not too low that it + isn't useful enough for a core contributor to spend time to review it, answer + questions, help get it into a release, etc.

+
    +
  • Up-To-Date
  • +
+

Often these issues become obsolete and have already been done, are no longer + desired, no longer make sense, have changed priority or difficulty , etc.

+

Good First Issue

+

Items marked with the good first issue label are intended for first-time +contributors. It indicates that members will keep an eye out for these pull +requests and shepherd it through our processes.

+

These items need to ensure that they follow the guidelines for help wanted +labels (above) in addition to meeting the following criteria:

+
    +
  • No Barrier to Entry
  • +
+

The task is something that a new contributor can tackle without advanced + setup, or domain knowledge.

+
    +
  • Solution Explained
  • +
+

The recommended solution is clearly described in the issue.

+
    +
  • Provides Context
  • +
+

If background knowledge is required, this should be explicitly mentioned and a + list of suggested readings included.

+
    +
  • Gives Examples
  • +
+

Link to examples of similar implementations so new contributors have a + reference guide for their changes.

+
    +
  • Identifies Relevant Code
  • +
+

The relevant code and tests to be changed should be linked in the issue.

+
    +
  • Ready to Test
  • +
+

There should be existing tests that can be modified, or existing test cases + fit to be copied. If the area of code doesn't have tests, before labeling the + issue, add a test fixture. This prep often makes a great help wanted task!

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/maintainer/triage/index.html b/v0.25.4/community/maintainer/triage/index.html new file mode 100644 index 0000000000..4faca70297 --- /dev/null +++ b/v0.25.4/community/maintainer/triage/index.html @@ -0,0 +1,3165 @@ + + + + + + + + + + + + + + + + + + + + + + + Triage - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Triage

+

Triage is an important part of maintaining the health of the trivy repo. +A well organized repo allows maintainers to prioritize feature requests, fix bugs, and respond to users facing difficulty with the tool as quickly as possible.

+

Triage includes:

+
    +
  • Labeling issues
  • +
  • Responding to issues
  • +
  • Closing issues
  • +
+

Daily Triage

+

Daily triage has two goals:

+
    +
  1. Responsiveness for new issues
  2. +
  3. Responsiveness when explicitly requested information was provided
  4. +
+

It covers:

+
    +
  1. Issues without a kind/ or triage/ label
  2. +
  3. Issues without a priority/ label
  4. +
  5. triage/needs-information issues which the user has followed up on, and now require a response.
  6. +
+

Categorization

+

The most important level of categorizing the issue is defining what type it is. +We typically want at least one of the following labels on every issue, and some issues may fall into multiple categories:

+
    +
  • triage/support - The default for most incoming issues
  • +
  • kind/bug - When it’s a bug or we aren’t delivering the best user experience
  • +
+

Other possibilities: +- kind/feature- Identify new feature requests +- kind/testing - Update or fix unit/integration tests +- kind/cleanup - Cleaning up/refactoring the codebase +- kind/documentation - Updates or additions to trivy documentation

+

If the issue is specific to a driver for OS packages or libraries:

+

co/[driver for OS packages]

+
    +
  • co/alpine
  • +
  • co/amazon
  • +
  • co/debian
  • +
  • co/oracle
  • +
  • co/photon
  • +
  • co/redhat
  • +
  • co/suse
  • +
  • co/ubuntu
  • +
+

co/[driver for libraries of programming languages]

+
    +
  • co/bundler
  • +
  • co/cargo
  • +
  • co/composer
  • +
  • co/npm
  • +
  • co/yarn
  • +
  • co/pipenv
  • +
  • co/poetry
  • +
+

Help wanted?

+

Good First Issue - bug has a proposed solution, can be implemented w/o further discussion.

+

Help wanted - if the bug could use help from a contributor

+

Prioritization

+

If the issue is not triage/support, it needs a priority label.

+

priority/critical-urgent - someones top priority ASAP, such as security issue, user-visible bug, or build breakage. Rarely used.

+

priority/important-soon: in time for the next two releases. It should be attached to a milestone.

+

priority/important-longterm: 2-4 releases from now

+

priority/backlog: agreed that this would be good to have, but no one is available at the moment. Consider tagging as help wanted

+

priority/awaiting-more-evidence: may be useful, but there is not yet enough support.

+

Weekly Triage

+

Weekly triage has three goals:

+
    +
  1. Catching up on unresponded issues
  2. +
  3. Reviewing and closing PR’s
  4. +
  5. Closing stale issues
  6. +
+

Post-Release Triage

+

Post-release triage occurs after a major release (around every 4-6 weeks). +It focuses on:

+
    +
  1. Closing bugs that have been resolved by the release
  2. +
  3. Reprioritizing bugs that have not been resolved by the release
  4. +
  5. Letting users know if we believe that there is still an issue
  6. +
+

This includes reviewing:

+
    +
  1. Every issue that hasn’t been touched in the last 2 days
  2. +
  3. Re-evaluation of long-term issues
  4. +
  5. Re-evaluation of short-term issues
  6. +
+

Responding to Issues

+

Needs More Information

+

A sample response to ask for more info:

+
+

I don’t yet have a clear way to replicate this issue. Do you mind adding some additional details. Here is additional information that would be helpful:

+

* The exact trivy command line used

+

* The exact image you want to scan

+

* The full output of the trivy command, preferably with --debug for extra logging.

+

Thank you for sharing your experience!

+
+

Then: Label with triage/needs-information.

+

Issue might be resolved

+

If you think a release may have resolved an issue, ask the author to see if their issue has been resolved:

+
+

Could you please check to see if trivy addresses this issue? We've made some changes with how this is handled, and improved the trivy logs output to help us debug tricky cases like this.

+
+

Then: Label with triage/needs-information.

+

Closing with Care

+

Issues typically need to be closed for the following reasons:

+
    +
  • The issue has been addressed
  • +
  • The issue is a duplicate of an existing issue
  • +
  • There has been a lack of information over a long period of time
  • +
+

In any of these situations, we aim to be kind when closing the issue, and offer the author action items should they need to reopen their issue or still require a solution.

+

Samples responses for these situations include:

+

Issue has been addressed

+
+

@author: I believe this issue is now addressed by trivy v1.0.0, as it . If you still see this issue with trivy v1.0 or higher, please reopen this issue.

+

Thank you for reporting this issue!

+
+

Then: Close the issue

+

Duplicate Issue

+
+

This issue appears to be a duplicate of #X, do you mind if we move the conversation there?

+

This way we can centralize the content relating to the issue. If you feel that this issue is not in fact a duplicate, please re-open it. If you have additional information to share, please add it to the new issue.

+

Thank you for reporting this!

+
+

Then: Label with triage/duplicate and close the issue.

+

Lack of Information

+

If an issue hasn't been active for more than four weeks, and the author has been pinged at least once, then the issue can be closed.

+
+

Hey @author -- hopefully it's OK if I close this - there wasn't enough information to make it actionable, and some time has already passed. If you are able to provide additional details, you may reopen it at any point.

+

Here is additional information that may be helpful to us:

+

* Whether the issue occurs with the latest trivy release

+

* The exact trivy command line used

+

* The exact image you want to scan

+

* The full output of the trivy command, preferably with --debug for extra logging.

+

Thank you for sharing your experience!

+
+

Then: Close the issue.

+

Help Wanted issues

+

We use two labels help wanted +and good first issue +to identify issues that have been specially groomed for new contributors.

+

We have specific guidelines +for how to use these labels. If you see an issue that satisfies these +guidelines, you can add the help wanted label and the good first issue label. +Please note that adding the good first issue label must also +add the help wanted label.

+

If an issue has these labels but does not satisfy the guidelines, please +ask for more details to be added to the issue or remove the labels.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/references/index.html b/v0.25.4/community/references/index.html new file mode 100644 index 0000000000..1e10599542 --- /dev/null +++ b/v0.25.4/community/references/index.html @@ -0,0 +1,3158 @@ + + + + + + + + + + + + + + + + + + + + + + + References - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + + +
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/community/tools/index.html b/v0.25.4/community/tools/index.html new file mode 100644 index 0000000000..91631a8efb --- /dev/null +++ b/v0.25.4/community/tools/index.html @@ -0,0 +1,3206 @@ + + + + + + + + + + + + + + + + + + + + + + + Tools - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Community Tools

+

The open source community has been hard at work developing new tools for Trivy. You can check out some of them here.

+

Have you created a tool that’s not listed? Add the name and description of your integration and open a pull request in the GitHub repository to get your change merged.

+

GitHub Actions

+ + + + + + + + + + + + + + + + + +
ActionsDescription
gitrivyGitHub Issue + Trivy
trivy-github-issuesGitHub Actions for creating GitHub Issues according to the Trivy scanning result
+

Semaphore

+ + + + + + + + + + + + + +
NameDescription
Continuous Vulnerability Testing with TrivyTutorial on scanning code, containers, infrastructure, and Kubernetes with Semaphore CI/CD.
+

CircleCI

+ + + + + + + + + + + + + +
OrbDescription
fifteen5/trivy-orbOrb for running Trivy, a security scanner
+

Others

+ + + + + + + + + + + + + +
NameDescription
Trivy Vulnerability ExplorerExplore trivy vulnerability reports in your browser and create .trivyignore files interactively. Can be integrated in your CI/CD tooling with deep links.
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/air-gap/index.html b/v0.25.4/docs/advanced/air-gap/index.html new file mode 100644 index 0000000000..2a374b7ac2 --- /dev/null +++ b/v0.25.4/docs/advanced/air-gap/index.html @@ -0,0 +1,3343 @@ + + + + + + + + + + + + + + + + + + + + + + + Air-Gapped Environment - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + + + + +
+
+ + + + +

Air-Gapped Environment

+

Trivy can be used in air-gapped environments. Note that an allowlist is here.

+

Air-Gapped Environment for vulnerabilities

+

Download the vulnerability database

+

At first, you need to download the vulnerability database for use in air-gapped environments. +Please follow oras installation instruction.

+

Download db.tar.gz:

+
$ oras pull ghcr.io/aquasecurity/trivy-db:2 -a
+
+

Transfer the DB file into the air-gapped environment

+

The way of transfer depends on the environment.

+
$ rsync -av -e ssh /path/to/db.tar.gz [user]@[host]:dst
+
+

Put the DB file in Trivy's cache directory

+

You have to know where to put the DB file. The following command shows the default cache directory.

+
$ ssh user@host
+$ trivy -h | grep cache
+   --cache-dir value  cache directory (default: "/home/myuser/.cache/trivy") [$TRIVY_CACHE_DIR]
+
+

Put the DB file in the cache directory + /db.

+
$ mkdir -p /home/myuser/.cache/trivy/db
+$ cd /home/myuser/.cache/trivy/db
+$ tar xvf /path/to/db.tar.gz -C /home/myuser/.cache/trivy/db
+x trivy.db
+x metadata.json
+$ rm /path/to/db.tar.gz
+
+

In an air-gapped environment it is your responsibility to update the Trivy database on a regular basis, so that the scanner can detect recently-identified vulnerabilities.

+

Run Trivy with --skip-update and --offline-scan option

+

In an air-gapped environment, specify --skip-update so that Trivy doesn't attempt to download the latest database file. +In addition, if you want to scan Java dependencies such as JAR and pom.xml, you need to specify --offline-scan since Trivy tries to issue API requests for scanning Java applications by default.

+
$ trivy image --skip-update --offline-scan alpine:3.12
+
+

Air-Gapped Environment for misconfigurations

+

Download misconfiguration policies

+

At first, you need to download misconfiguration policies for use in air-gapped environments. +Please follow oras installation instruction.

+

Download bundle.tar.gz:

+
$ oras pull ghcr.io/aquasecurity/appshield:latest -a
+
+

Transfer misconfiguration policies into the air-gapped environment

+

The way of transfer depends on the environment.

+
$ rsync -av -e ssh /path/to/bundle.tar.gz [user]@[host]:dst
+
+

Put the misconfiguration policies in Trivy's cache directory

+

You have to know where to put the misconfiguration policies file. The following command shows the default cache directory.

+
$ ssh user@host
+$ trivy -h | grep cache
+   --cache-dir value  cache directory (default: "/home/myuser/.cache/trivy") [$TRIVY_CACHE_DIR]
+
+

Put the misconfiguration policies file in the cache directory + /policy/content.

+
$ mkdir -p /home/myuser/.cache/trivy/policy/content
+$ cd /home/myuser/.cache/trivy/policy/content
+$ mv /path/to/bundle.tar.gz .
+
+

Then, decompress it. +bundle.tar.gz file includes two folders: docker, kubernetes and file: .manifest.

+
$ tar xvf bundle.tar.gz 
+x ./docker/
+...
+x ./kubernetes/
+...
+x ./.manifest
+$ rm bundle.tar.gz
+
+

In an air-gapped environment it is your responsibility to update policies on a regular basis, so that the scanner can detect recently-identified misconfigurations.

+

Run Trivy with --skip-policy-update option

+

In an air-gapped environment, specify --skip-policy-update so that Trivy doesn't attempt to download the latest misconfiguration policies.

+
$ trivy conf --skip-policy-update /path/to/conf
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/container/embed-in-dockerfile/index.html b/v0.25.4/docs/advanced/container/embed-in-dockerfile/index.html new file mode 100644 index 0000000000..dbc4e1d2c7 --- /dev/null +++ b/v0.25.4/docs/advanced/container/embed-in-dockerfile/index.html @@ -0,0 +1,3056 @@ + + + + + + + + + + + + + + + + + + + + + + + Embed in Dockerfile - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Embed in Dockerfile

+

Scan your image as part of the build process by embedding Trivy in the +Dockerfile. This approach can be used to update Dockerfiles currently using +Aqua’s Microscanner.

+

$ cat Dockerfile
+FROM alpine:3.7
+
+RUN apk add curl \
+    && curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin \
+    && trivy rootfs --exit-code 1 --no-progress /
+
+$ docker build -t vulnerable-image .
+
+Alternatively you can use Trivy in a multistage build. Thus avoiding the +insecure curl | sh. Also the image is not changed. +
[...]
+# Run vulnerability scan on build image
+FROM build AS vulnscan
+COPY --from=aquasec/trivy:latest /usr/local/bin/trivy /usr/local/bin/trivy
+RUN trivy rootfs --exit-code 1 --no-progress /
+[...]
+

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/container/oci/index.html b/v0.25.4/docs/advanced/container/oci/index.html new file mode 100644 index 0000000000..2c3bbc1332 --- /dev/null +++ b/v0.25.4/docs/advanced/container/oci/index.html @@ -0,0 +1,3044 @@ + + + + + + + + + + + + + + + + + + + + + + + OCI Image - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

OCI Image Layout

+

An image directory compliant with Open Container Image Layout Specification.

+

Buildah:

+
$ buildah push docker.io/library/alpine:3.11 oci:/path/to/alpine
+$ trivy image --input /path/to/alpine
+
+

Skopeo:

+
$ skopeo copy docker-daemon:alpine:3.11 oci:/path/to/alpine
+$ trivy image --input /path/to/alpine
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/container/podman/index.html b/v0.25.4/docs/advanced/container/podman/index.html new file mode 100644 index 0000000000..4bfb9e38fd --- /dev/null +++ b/v0.25.4/docs/advanced/container/podman/index.html @@ -0,0 +1,3054 @@ + + + + + + + + + + + + + + + + + + + + + + + Podman - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Podman

+
+

EXPERIMENTAL

+

This feature might change without preserving backwards compatibility.

+
+

Scan your image in Podman (>=2.0) running locally. The remote Podman is not supported. +Before performing Trivy commands, you must enable the podman.sock systemd service on your machine. +For more details, see here.

+
$ systemctl --user enable --now podman.socket
+
+

Then, you can scan your image in Podman.

+
$ cat Dockerfile
+FROM alpine:3.12
+RUN apk add --no-cache bash
+$ podman build -t test .
+$ podman images
+REPOSITORY                TAG     IMAGE ID      CREATED      SIZE
+localhost/test            latest  efc372d4e0de  About a minute ago  7.94 MB
+$ trivy image test
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/container/unpacked-filesystem/index.html b/v0.25.4/docs/advanced/container/unpacked-filesystem/index.html new file mode 100644 index 0000000000..5dcb466210 --- /dev/null +++ b/v0.25.4/docs/advanced/container/unpacked-filesystem/index.html @@ -0,0 +1,3144 @@ + + + + + + + + + + + + + + + + + + + + + + + Unpacked container image filesystem - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Unpacked Filesystem

+

Scan an unpacked container image filesystem.

+

In this case, Trivy works the same way when scanning containers

+
$ docker export $(docker create alpine:3.10.2) | tar -C /tmp/rootfs -xvf -
+$ trivy rootfs /tmp/rootfs
+
+
+Result + +
2021-03-08T05:22:26.378Z        INFO    Need to update DB
+2021-03-08T05:22:26.380Z        INFO    Downloading DB...
+20.37 MiB / 20.37 MiB [-------------------------------------------------------------------------------------------------------------------------------------] 100.00% 8.24 MiB p/s 2s
+2021-03-08T05:22:30.134Z        INFO    Detecting Alpine vulnerabilities...
+
+/tmp/rootfs (alpine 3.10.2)
+===========================
+Total: 20 (UNKNOWN: 0, LOW: 2, MEDIUM: 10, HIGH: 8, CRITICAL: 0)
+
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+|   LIBRARY    | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+| libcrypto1.1 | CVE-2020-1967    | HIGH     | 1.1.1c-r0         | 1.1.1g-r0     | openssl: Segmentation                 |
+|              |                  |          |                   |               | fault in SSL_check_chain              |
+|              |                  |          |                   |               | causes denial of service              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1967  |
++              +------------------+          +                   +---------------+---------------------------------------+
+|              | CVE-2021-23839   |          |                   | 1.1.1j-r0     | openssl: incorrect SSLv2              |
+|              |                  |          |                   |               | rollback protection                   |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |
+|              |                  |          |                   |               | overflow in CipherUpdate              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |
+|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |
++              +------------------+----------+                   +---------------+---------------------------------------+
+|              | CVE-2019-1547    | MEDIUM   |                   | 1.1.1d-r0     | openssl: side-channel weak            |
+|              |                  |          |                   |               | encryption vulnerability              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1547  |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2019-1549    |          |                   |               | openssl: information                  |
+|              |                  |          |                   |               | disclosure in fork()                  |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1549  |
++              +------------------+          +                   +---------------+---------------------------------------+
+|              | CVE-2019-1551    |          |                   | 1.1.1d-r2     | openssl: Integer overflow in RSAZ     |
+|              |                  |          |                   |               | modular exponentiation on x86_64      |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1551  |
++              +------------------+          +                   +---------------+---------------------------------------+
+|              | CVE-2020-1971    |          |                   | 1.1.1i-r0     | openssl: EDIPARTYNAME                 |
+|              |                  |          |                   |               | NULL pointer de-reference             |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1971  |
++              +------------------+----------+                   +---------------+---------------------------------------+
+|              | CVE-2019-1563    | LOW      |                   | 1.1.1d-r0     | openssl: information                  |
+|              |                  |          |                   |               | disclosure in PKCS7_dataDecode        |
+|              |                  |          |                   |               | and CMS_decrypt_set1_pkey             |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1563  |
++--------------+------------------+----------+                   +---------------+---------------------------------------+
+| libssl1.1    | CVE-2020-1967    | HIGH     |                   | 1.1.1g-r0     | openssl: Segmentation                 |
+|              |                  |          |                   |               | fault in SSL_check_chain              |
+|              |                  |          |                   |               | causes denial of service              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1967  |
++              +------------------+          +                   +---------------+---------------------------------------+
+|              | CVE-2021-23839   |          |                   | 1.1.1j-r0     | openssl: incorrect SSLv2              |
+|              |                  |          |                   |               | rollback protection                   |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |
+|              |                  |          |                   |               | overflow in CipherUpdate              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |
+|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |
++              +------------------+----------+                   +---------------+---------------------------------------+
+|              | CVE-2019-1547    | MEDIUM   |                   | 1.1.1d-r0     | openssl: side-channel weak            |
+|              |                  |          |                   |               | encryption vulnerability              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1547  |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2019-1549    |          |                   |               | openssl: information                  |
+|              |                  |          |                   |               | disclosure in fork()                  |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1549  |
++              +------------------+          +                   +---------------+---------------------------------------+
+|              | CVE-2019-1551    |          |                   | 1.1.1d-r2     | openssl: Integer overflow in RSAZ     |
+|              |                  |          |                   |               | modular exponentiation on x86_64      |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1551  |
++              +------------------+          +                   +---------------+---------------------------------------+
+|              | CVE-2020-1971    |          |                   | 1.1.1i-r0     | openssl: EDIPARTYNAME                 |
+|              |                  |          |                   |               | NULL pointer de-reference             |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1971  |
++              +------------------+----------+                   +---------------+---------------------------------------+
+|              | CVE-2019-1563    | LOW      |                   | 1.1.1d-r0     | openssl: information                  |
+|              |                  |          |                   |               | disclosure in PKCS7_dataDecode        |
+|              |                  |          |                   |               | and CMS_decrypt_set1_pkey             |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1563  |
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+| musl         | CVE-2020-28928   | MEDIUM   | 1.1.22-r3         | 1.1.22-r4     | In musl libc through 1.2.1,           |
+|              |                  |          |                   |               | wcsnrtombs mishandles particular      |
+|              |                  |          |                   |               | combinations of destination buffer... |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-28928 |
++--------------+                  +          +                   +               +                                       +
+| musl-utils   |                  |          |                   |               |                                       |
+|              |                  |          |                   |               |                                       |
+|              |                  |          |                   |               |                                       |
+|              |                  |          |                   |               |                                       |
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+
+ +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/plugins/index.html b/v0.25.4/docs/advanced/plugins/index.html new file mode 100644 index 0000000000..1861564383 --- /dev/null +++ b/v0.25.4/docs/advanced/plugins/index.html @@ -0,0 +1,3334 @@ + + + + + + + + + + + + + + + + + + + + + + + Plugins - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + + + + +
+
+ + + + +

Plugins

+

Trivy provides a plugin feature to allow others to extend the Trivy CLI without the need to change the Trivycode base. +This plugin system was inspired by the plugin system used in kubectl, Helm, and Conftest.

+

Overview

+

Trivy plugins are add-on tools that integrate seamlessly with Trivy. +They provide a way to extend the core feature set of Trivy, but without requiring every new feature to be written in Go and added to the core tool.

+
    +
  • They can be added and removed from a Trivy installation without impacting the core Trivy tool.
  • +
  • They can be written in any programming language.
  • +
  • They integrate with Trivy, and will show up in Trivy help and subcommands.
  • +
+
+

Warning

+

Trivy plugins available in public are not audited for security. +You should install and run third-party plugins at your own risk, since they are arbitrary programs running on your machine.

+
+

Installing a Plugin

+

A plugin can be installed using the trivy plugin install command. +This command takes a url and will download the plugin and install it in the plugin cache.

+

Trivy adheres to the XDG specification, so the location depends on whether XDG_DATA_HOME is set. +Trivy will now search XDG_DATA_HOME for the location of the Trivy plugins cache. +The preference order is as follows:

+
    +
  • XDG_DATA_HOME if set and .trivy/plugins exists within the XDG_DATA_HOME dir
  • +
  • ~/.trivy/plugins
  • +
+

Under the hood Trivy leverages go-getter to download plugins. +This means the following protocols are supported for downloading plugins:

+
    +
  • OCI Registries
  • +
  • Local Files
  • +
  • Git
  • +
  • HTTP/HTTPS
  • +
  • Mercurial
  • +
  • Amazon S3
  • +
  • Google Cloud Storage
  • +
+

For example, to download the Kubernetes Trivy plugin you can execute the following command:

+
$ trivy plugin install github.com/aquasecurity/trivy-plugin-kubectl
+
+

Using Plugins

+

Once the plugin is installed, Trivy will load all available plugins in the cache on the start of the next Trivy execution. +A plugin will be made in the Trivy CLI based on the plugin name. +To display all plugins, you can list them by trivy --help

+
$ trivy --help
+NAME:
+   trivy - A simple and comprehensive vulnerability scanner for containers
+
+USAGE:
+   trivy [global options] command [command options] target
+
+VERSION:
+   dev
+
+COMMANDS:
+   image, i          scan an image
+   filesystem, fs    scan local filesystem
+   repository, repo  scan remote repository
+   client, c         client mode
+   server, s         server mode
+   plugin, p         manage plugins
+   kubectl           scan kubectl resources
+   help, h           Shows a list of commands or help for one command
+
+

As shown above, kubectl subcommand exists in the COMMANDS section. +To call the kubectl plugin and scan existing Kubernetes deployments, you can execute the following command:

+
$ trivy kubectl deployment <deployment-id> -- --ignore-unfixed --severity CRITICAL
+
+

Internally the kubectl plugin calls the kubectl binary to fetch information about that deployment and passes the using images to Trivy. +You can see the detail here.

+

If you want to omit even the subcommand, you can use TRIVY_RUN_AS_PLUGIN environment variable.

+
$ TRIVY_RUN_AS_PLUGIN=kubectl trivy job your-job -- --format json
+
+

Installing and Running Plugins on the fly

+

trivy plugin run installs a plugin and runs it on the fly. +If the plugin is already present in the cache, the installation is skipped.

+
trivy plugin run github.com/aquasecurity/trivy-plugin-kubectl pod your-pod -- --exit-code 1
+
+

Uninstalling Plugins

+

Specify a plugin name with trivy plugin uninstall command.

+
$ trivy plugin uninstall kubectl
+
+

Building Plugins

+

Each plugin has a top-level directory, and then a plugin.yaml file.

+
your-plugin/
+  |
+  |- plugin.yaml
+  |- your-plugin.sh
+
+

In the example above, the plugin is contained inside of a directory named your-plugin. +It has two files: plugin.yaml (required) and an executable script, your-plugin.sh (optional).

+

The core of a plugin is a simple YAML file named plugin.yaml. +Here is an example YAML of trivy-plugin-kubectl plugin that adds support for Kubernetes scanning.

+
name: "kubectl"
+repository: github.com/aquasecurity/trivy-plugin-kubectl
+version: "0.1.0"
+usage: scan kubectl resources
+description: |-
+  A Trivy plugin that scans the images of a kubernetes resource.
+  Usage: trivy kubectl TYPE[.VERSION][.GROUP] NAME
+platforms:
+  - selector: # optional
+      os: darwin
+      arch: amd64
+    uri: ./trivy-kubectl # where the execution file is (local file, http, git, etc.)
+    bin: ./trivy-kubectl # path to the execution file
+  - selector: # optional
+      os: linux
+      arch: amd64
+    uri: https://github.com/aquasecurity/trivy-plugin-kubectl/releases/download/v0.1.0/trivy-kubectl.tar.gz
+    bin: ./trivy-kubectl
+
+

The plugin.yaml field should contain the following information:

+
    +
  • name: The name of the plugin. This also determines how the plugin will be made available in the Trivy CLI. For example, if the plugin is named kubectl, you can call the plugin with trivy kubectl. (required)
  • +
  • version: The version of the plugin. (required)
  • +
  • usage: A short usage description. (required)
  • +
  • description: A long description of the plugin. This is where you could provide a helpful documentation of your plugin. (required)
  • +
  • platforms: (required)
  • +
  • selector: The OS/Architecture specific variations of a execution file. (optional)
      +
    • os: OS information based on GOOS (linux, darwin, etc.) (optional)
    • +
    • arch: The architecture information based on GOARCH (amd64, arm64, etc.) (optional)
    • +
    +
  • +
  • uri: Where the executable file is. Relative path from the root directory of the plugin or remote URL such as HTTP and S3. (required)
  • +
  • bin: Which file to call when the plugin is executed. Relative path from the root directory of the plugin. (required)
  • +
+

The following rules will apply in deciding which platform to select:

+
    +
  • If both os and arch under selector match the current platform, search will stop and the platform will be used.
  • +
  • If selector is not present, the platform will be used.
  • +
  • If os matches and there is no more specific arch match, the platform will be used.
  • +
  • If no platform match is found, Trivy will exit with an error.
  • +
+

After determining platform, Trivy will download the execution file from uri and store it in the plugin cache. +When the plugin is called via Trivy CLI, bin command will be executed.

+

The plugin is responsible for handling flags and arguments. Any arguments are passed to the plugin from the trivy command.

+

Example

+

https://github.com/aquasecurity/trivy-plugin-kubectl

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/private-registries/acr/index.html b/v0.25.4/docs/advanced/private-registries/acr/index.html new file mode 100644 index 0000000000..c325ba350f --- /dev/null +++ b/v0.25.4/docs/advanced/private-registries/acr/index.html @@ -0,0 +1,3055 @@ + + + + + + + + + + + + + + + + + + + + + + + ACR (Azure Container Registry) - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Requirements

+

None, Trivy uses Azure SDK for Go. You don't need to install az command.

+

Privileges

+

Service principal must have the AcrPull permissions.

+

Creation of a service principal

+
export SP_DATA=$(az ad sp create-for-rbac --name TrivyTest --role AcrPull --scope "/subscriptions/<subscription_id>/resourceGroups/<resource_group>/providers/Microsoft.ContainerRegistry/registries/<registry_name>")
+
+

Usage

+
# must set TRIVY_USERNAME empty char
+export AZURE_CLIENT_ID$(echo $SP_DATA | jq -r .appId)
+export AZURE_CLIENT_SECRET$(echo $SP_DATA | jq -r .password)
+export AZURE_TENANT_ID$(echo $SP_DATA | jq -r .tenant)
+
+

Testing

+

You can test credentials in the following manner.

+
docker run -it --rm -v /tmp:/tmp\
+  -e AZURE_CLIENT_ID=${AZURE_CLIENT_ID} -e AZURE_CLIENT_SECRET=${AZURE_CLIENT_SECRET} \
+  -e AZURE_TENANT_ID=${AZURE_TENANT_ID} aquasec/trivy image your_special_project.azurecr.io/your_special_image:your_special_tag
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/private-registries/docker-hub/index.html b/v0.25.4/docs/advanced/private-registries/docker-hub/index.html new file mode 100644 index 0000000000..922ae157f0 --- /dev/null +++ b/v0.25.4/docs/advanced/private-registries/docker-hub/index.html @@ -0,0 +1,3034 @@ + + + + + + + + + + + + + + + + + + + + + + + Docker Hub - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Docker Hub

+ +

Docker Hub needs TRIVY_USERNAME and TRIVY_PASSWORD. +You don't need to set ENV vars when download from public repository.

+
export TRIVY_USERNAME={DOCKERHUB_USERNAME}
+export TRIVY_PASSWORD={DOCKERHUB_PASSWORD}
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/private-registries/ecr/index.html b/v0.25.4/docs/advanced/private-registries/ecr/index.html new file mode 100644 index 0000000000..bf7487f6f0 --- /dev/null +++ b/v0.25.4/docs/advanced/private-registries/ecr/index.html @@ -0,0 +1,3031 @@ + + + + + + + + + + + + + + + + + + + + + + + AWS ECR (Elastic Container Registry) - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

AWS ECR (Elastic Container Registry)

+ +

Trivy uses AWS SDK. You don't need to install aws CLI tool. +You can use AWS CLI's ENV Vars.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/private-registries/gcr/index.html b/v0.25.4/docs/advanced/private-registries/gcr/index.html new file mode 100644 index 0000000000..762918fdb6 --- /dev/null +++ b/v0.25.4/docs/advanced/private-registries/gcr/index.html @@ -0,0 +1,3067 @@ + + + + + + + + + + + + + + + + + + + + + + + GCR (Google Container Registry) - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Requirements

+

None, Trivy uses Google Cloud SDK. You don't need to install gcloud command.

+

Privileges

+

Credential file must have the roles/storage.objectViewer permissions. +More information can be found in Google's documentation

+

JSON File Format

+

The JSON file specified should have the following format provided by google's service account mechanisms:

+
{
+  "type": "service_account",
+  "project_id": "your_special_project",
+  "private_key_id": "XXXXXXXXXXXXXXXXXXXXxx",
+  "private_key": "-----BEGIN PRIVATE KEY-----\nNONONONO\n-----END PRIVATE KEY-----\n",
+  "client_email": "somedude@your_special_project.iam.gserviceaccount.com",
+  "client_id": "1234567890",
+  "auth_uri": "https://accounts.google.com/o/oauth2/auth",
+  "token_uri": "https://oauth2.googleapis.com/token",
+  "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
+  "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/somedude%40your_special_project.iam.gserviceaccount.com"
+}
+
+

Usage

+

If you want to use target project's repository, you can set them via GOOGLE_APPLICATION_CREDENTIALS. +

# must set TRIVY_USERNAME empty char
+export GOOGLE_APPLICATION_CREDENTIALS=/path/to/credential.json
+

+

Testing

+

You can test credentials in the following manner (assuming they are in /tmp on host machine).

+
docker run -it --rm -v /tmp:/tmp\
+  -e GOOGLE_APPLICATION_CREDENTIALS=/tmp/service_account.json\
+  aquasec/trivy image gcr.io/your_special_project/your_special_image:your_special_tag
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/private-registries/index.html b/v0.25.4/docs/advanced/private-registries/index.html new file mode 100644 index 0000000000..a811f75f56 --- /dev/null +++ b/v0.25.4/docs/advanced/private-registries/index.html @@ -0,0 +1,3032 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Overview

+ +

Trivy can download images from a private registry, without installing Docker or any other 3rd party tools. +That's because it's easy to run in a CI process.

+

All you have to do is install Trivy and set ENV vars.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/advanced/private-registries/self/index.html b/v0.25.4/docs/advanced/private-registries/self/index.html new file mode 100644 index 0000000000..658055f3ba --- /dev/null +++ b/v0.25.4/docs/advanced/private-registries/self/index.html @@ -0,0 +1,3036 @@ + + + + + + + + + + + + + + + + + + + + + + + Self-Hosted - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Self-Hosted

+ +

BasicAuth server needs TRIVY_USERNAME and TRIVY_PASSWORD.

+
export TRIVY_USERNAME={USERNAME}
+export TRIVY_PASSWORD={PASSWORD}
+
+# if you want to use 80 port, use NonSSL
+export TRIVY_NON_SSL=true
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/index.html b/v0.25.4/docs/index.html new file mode 100644 index 0000000000..4a33eda601 --- /dev/null +++ b/v0.25.4/docs/index.html @@ -0,0 +1,3166 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Docs

+

Trivy detects two types of security issues:

+ +

Trivy can scan three different artifacts:

+ +

Trivy can be run in two different modes:

+ +

It is designed to be used in CI. Before pushing to a container registry or deploying your application, you can scan your local container image and other artifacts easily. +See Integrations for details.

+

Features

+
    +
  • Comprehensive vulnerability detection
      +
    • OS packages (Alpine, Red Hat Universal Base Image, Red Hat Enterprise Linux, CentOS, AlmaLinux, Rocky Linux, CBL-Mariner, Oracle Linux, Debian, Ubuntu, Amazon Linux, openSUSE Leap, SUSE Enterprise Linux, Photon OS and Distroless)
    • +
    • Language-specific packages (Bundler, Composer, Pipenv, Poetry, npm, yarn, Cargo, NuGet, Maven, and Go)
    • +
    +
  • +
  • Detect IaC misconfigurations
      +
    • A wide variety of built-in policies are provided out of the box:
        +
      • Kubernetes
      • +
      • Docker
      • +
      • Terraform
      • +
      • more coming soon
      • +
      +
    • +
    • Support custom policies
    • +
    +
  • +
  • Simple
      +
    • Specify only an image name, a directory containing IaC configs, or an artifact name
    • +
    • See Quick Start
    • +
    +
  • +
  • Fast
      +
    • The first scan will finish within 10 seconds (depending on your network). Consequent scans will finish in single seconds.
    • +
    • Unlike other scanners that take long to fetch vulnerability information (~10 minutes) on the first run, and encourage you to maintain a durable vulnerability database, Trivy is stateless and requires no maintenance or preparation.
    • +
    +
  • +
  • Easy installation
      +
    • apt-get install, yum install and brew install is possible (See Installation)
    • +
    • No pre-requisites such as installation of DB, libraries, etc.
    • +
    +
  • +
  • High accuracy
      +
    • Especially Alpine Linux and RHEL/CentOS
    • +
    • Other OSes are also high
    • +
    +
  • +
  • DevSecOps
      +
    • Suitable for CI such as Travis CI, CircleCI, Jenkins, GitLab CI, etc.
    • +
    • See CI Example
    • +
    +
  • +
  • Support multiple formats
      +
    • container image
        +
      • A local image in Docker Engine which is running as a daemon
      • +
      • A local image in Podman (>=2.0) which is exposing a socket
      • +
      • A remote image in Docker Registry such as Docker Hub, ECR, GCR and ACR
      • +
      • A tar archive stored in the docker save / podman save formatted file
      • +
      • An image directory compliant with OCI Image Format
      • +
      +
    • +
    • local filesystem and rootfs
    • +
    • remote git repository
    • +
    +
  • +
  • SBOM (Software Bill of Materials) support
      +
    • CycloneDX
    • +
    +
  • +
+

Please see LICENSE for Trivy licensing information.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/aws-codepipeline/index.html b/v0.25.4/docs/integrations/aws-codepipeline/index.html new file mode 100644 index 0000000000..a71e9de118 --- /dev/null +++ b/v0.25.4/docs/integrations/aws-codepipeline/index.html @@ -0,0 +1,3034 @@ + + + + + + + + + + + + + + + + + + + + + + + AWS CodePipeline - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

AWS CodePipeline

+

See this blog post for an example of using Trivy within AWS CodePipeline.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/aws-security-hub/index.html b/v0.25.4/docs/integrations/aws-security-hub/index.html new file mode 100644 index 0000000000..2eac16a2d2 --- /dev/null +++ b/v0.25.4/docs/integrations/aws-security-hub/index.html @@ -0,0 +1,3140 @@ + + + + + + + + + + + + + + + + + + + + + + + AWS Security Hub - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

AWS Security Hub

+

Upload findings to Security Hub

+

In the following example using the template asff.tpl, ASFF file can be generated.

+
$ AWS_REGION=us-west-1 AWS_ACCOUNT_ID=123456789012 trivy image --format template --template "@contrib/asff.tpl" -o report.asff golang:1.12-alpine
+
+

ASFF template needs AWS_REGION and AWS_ACCOUNT_ID from environment variables.

+

Then, you can upload it with AWS CLI.

+
$ aws securityhub batch-import-findings --findings file://report.asff
+
+

Customize

+

You can customize asff.tpl

+
$ export AWS_REGION=us-west-1
+$ export AWS_ACCOUNT_ID=123456789012
+$ trivy image --format template --template "@your-asff.tpl" -o report.asff golang:1.12-alpine
+
+

Reference

+

https://aws.amazon.com/blogs/security/how-to-build-ci-cd-pipeline-container-vulnerability-scanning-trivy-and-aws-security-hub/

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/bitbucket/index.html b/v0.25.4/docs/integrations/bitbucket/index.html new file mode 100644 index 0000000000..ed4d63d37a --- /dev/null +++ b/v0.25.4/docs/integrations/bitbucket/index.html @@ -0,0 +1,3034 @@ + + + + + + + + + + + + + + + + + + + + + + + Bitbucket Pipelines - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Bitbucket Pipelines

+

See trivy-pipe for the details.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/circleci/index.html b/v0.25.4/docs/integrations/circleci/index.html new file mode 100644 index 0000000000..36fef4dad5 --- /dev/null +++ b/v0.25.4/docs/integrations/circleci/index.html @@ -0,0 +1,3060 @@ + + + + + + + + + + + + + + + + + + + + + + + CircleCI - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

CircleCI

+
$ cat .circleci/config.yml
+jobs:
+  build:
+    docker:
+      - image: docker:stable-git
+    steps:
+      - checkout
+      - setup_remote_docker
+      - run:
+          name: Build image
+          command: docker build -t trivy-ci-test:${CIRCLE_SHA1} .
+      - run:
+          name: Install trivy
+          command: |
+            apk add --update-cache --upgrade curl
+            curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin
+      - run:
+          name: Scan the local image with trivy
+          command: trivy image --exit-code 0 --no-progress trivy-ci-test:${CIRCLE_SHA1}
+workflows:
+  version: 2
+  release:
+    jobs:
+      - build
+
+

Example +Repository

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/github-actions/index.html b/v0.25.4/docs/integrations/github-actions/index.html new file mode 100644 index 0000000000..d5c10ebba4 --- /dev/null +++ b/v0.25.4/docs/integrations/github-actions/index.html @@ -0,0 +1,3038 @@ + + + + + + + + + + + + + + + + + + + + + + + GitHub Actions - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

GitHub Actions

+
    +
  • Here is the Trivy Github Action
  • +
  • The Microsoft Azure team have written a container-scan action that uses Trivy and Dockle
  • +
  • For full control over the options specified to Trivy, this blog post describes adding Trivy into your own GitHub action workflows
  • +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/gitlab-ci/index.html b/v0.25.4/docs/integrations/gitlab-ci/index.html new file mode 100644 index 0000000000..5aa58dc486 --- /dev/null +++ b/v0.25.4/docs/integrations/gitlab-ci/index.html @@ -0,0 +1,3276 @@ + + + + + + + + + + + + + + + + + + + + + + + GitLab CI - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+ +
+ + +
+
+ + + + +

GitLab CI

+

If you're a GitLab Ultimate customer, GitLab 14.0 and above include out-of-the-box integration with Trivy. To enable it for your project, simply add the container scanning template to your .gitlab-ci.yml file. For more details, please refer to GitLab's documentation.

+

If you're using an earlier version of GitLab, you can still use the new integration by copying the contents of the 14.0 template to your configuration.

+

Alternatively, you can always use the example configurations below.

+
stages:
+  - test
+
+trivy:
+  stage: test
+  image: docker:stable
+  services:
+    - name: docker:dind
+      entrypoint: ["env", "-u", "DOCKER_HOST"]
+      command: ["dockerd-entrypoint.sh"]
+  variables:
+    DOCKER_HOST: tcp://docker:2375/
+    DOCKER_DRIVER: overlay2
+    # See https://github.com/docker-library/docker/pull/166
+    DOCKER_TLS_CERTDIR: ""
+    IMAGE: trivy-ci-test:$CI_COMMIT_SHA
+    TRIVY_NO_PROGRESS: "true"
+    TRIVY_CACHE_DIR: ".trivycache/"
+  before_script:
+    - export TRIVY_VERSION=$(wget -qO - "https://api.github.com/repos/aquasecurity/trivy/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
+    - echo $TRIVY_VERSION
+    - wget --no-verbose https://github.com/aquasecurity/trivy/releases/download/v${TRIVY_VERSION}/trivy_${TRIVY_VERSION}_Linux-64bit.tar.gz -O - | tar -zxvf -
+  allow_failure: true
+  script:
+    # Build image
+    - docker build -t $IMAGE .
+    # Build report
+    - ./trivy image --exit-code 0 --format template --template "@contrib/gitlab.tpl" -o gl-container-scanning-report.json $IMAGE
+    # Print report
+    - ./trivy image --exit-code 0 --severity HIGH $IMAGE
+    # Fail on severe vulnerabilities
+    - ./trivy image --exit-code 1 --severity CRITICAL $IMAGE
+  cache:
+    paths:
+      - .trivycache/
+  # Enables https://docs.gitlab.com/ee/user/application_security/container_scanning/ (Container Scanning report is available on GitLab EE Ultimate or GitLab.com Gold)
+  artifacts:
+    reports:
+      container_scanning: gl-container-scanning-report.json
+
+

Example +Repository

+

GitLab CI using Trivy container

+

To scan a previously built image that has already been pushed into the +GitLab container registry the following CI job manifest can be used. +Note that entrypoint needs to be unset for the script section to work. +In case of a non-public GitLab project Trivy additionally needs to +authenticate to the registry to be able to pull your application image. +Finally, it is not necessary to clone the project repo as we only work +with the container image.

+
container_scanning:
+  image:
+    name: docker.io/aquasec/trivy:latest
+    entrypoint: [""]
+  variables:
+    # No need to clone the repo, we exclusively work on artifacts.  See
+    # https://docs.gitlab.com/ee/ci/runners/README.html#git-strategy
+    GIT_STRATEGY: none
+    TRIVY_USERNAME: "$CI_REGISTRY_USER"
+    TRIVY_PASSWORD: "$CI_REGISTRY_PASSWORD"
+    TRIVY_AUTH_URL: "$CI_REGISTRY"
+    TRIVY_NO_PROGRESS: "true"
+    TRIVY_CACHE_DIR: ".trivycache/"
+    FULL_IMAGE_NAME: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG
+  script:
+    - trivy --version
+    # cache cleanup is needed when scanning images with the same tags, it does not remove the database
+    - time trivy image --clear-cache
+    # update vulnerabilities db
+    - time trivy image --download-db-only
+    # Builds report and puts it in the default workdir $CI_PROJECT_DIR, so `artifacts:` can take it from there
+    - time trivy image --exit-code 0 --format template --template "@/contrib/gitlab.tpl"
+        --output "$CI_PROJECT_DIR/gl-container-scanning-report.json" "$FULL_IMAGE_NAME"
+    # Prints full report
+    - time trivy image --exit-code 0 "$FULL_IMAGE_NAME"
+    # Fail on critical vulnerabilities
+    - time trivy image --exit-code 1 --severity CRITICAL "$FULL_IMAGE_NAME"
+  cache:
+    paths:
+      - .trivycache/
+  # Enables https://docs.gitlab.com/ee/user/application_security/container_scanning/ (Container Scanning report is available on GitLab EE Ultimate or GitLab.com Gold)
+  artifacts:
+    when:                          always
+    reports:
+      container_scanning:          gl-container-scanning-report.json
+  tags:
+    - docker-runner
+
+

Gitlab CI alternative template

+

Depending on the edition of gitlab you have or your desired workflow, the +container scanning template may not meet your needs. As an addition to the +above container scanning template, a template for +code climate +has been included. The key things to update from the above examples are +the template and report type. An updated example is below.

+
stages:
+  - test
+
+trivy:
+  stage: test
+  image: docker:stable
+  services:
+    - name: docker:dind
+      entrypoint: ["env", "-u", "DOCKER_HOST"]
+      command: ["dockerd-entrypoint.sh"]
+  variables:
+    DOCKER_HOST: tcp://docker:2375/
+    DOCKER_DRIVER: overlay2
+    # See https://github.com/docker-library/docker/pull/166
+    DOCKER_TLS_CERTDIR: ""
+    IMAGE: trivy-ci-test:$CI_COMMIT_SHA
+    TRIVY_NO_PROGRESS: "true"
+    TRIVY_CACHE_DIR: ".trivycache/"
+  before_script:
+    - export TRIVY_VERSION=$(wget -qO - "https://api.github.com/repos/aquasecurity/trivy/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
+    - echo $TRIVY_VERSION
+    - wget --no-verbose https://github.com/aquasecurity/trivy/releases/download/v${TRIVY_VERSION}/trivy_${TRIVY_VERSION}_Linux-64bit.tar.gz -O - | tar -zxvf -
+  allow_failure: true
+  script:
+    # Build image
+    - docker build -t $IMAGE .
+    # Image report
+    - ./trivy image --exit-code 0 --format template --template "@contrib/gitlab-codequality.tpl" -o gl-codeclimate-image.json $IMAGE
+    # Filesystem report
+    - ./trivy filesystem --security-checks config,vuln --exit-code 0 --format template --template "@contrib/gitlab-codequality.tpl" -o gl-codeclimate-fs.json .
+    # Combine report
+    - apk update && apk add jq
+    - jq -s 'add' gl-codeclimate-image.json gl-codeclimate-fs.json > gl-codeclimate.json
+  cache:
+    paths:
+      - .trivycache/
+  # Enables https://docs.gitlab.com/ee/user/application_security/container_scanning/ (Container Scanning report is available on GitLab EE Ultimate or GitLab.com Gold)
+  artifacts:
+    paths:
+      - gl-codeclimate.json
+    reports:
+      codequality: gl-codeclimate.json
+
+

Currently gitlab only supports a single code quality report. There is an +open feature request +to support multiple reports. Until this has been implemented, if you +already have a code quality report in your pipeline, you can use +jq to combine reports. Depending on how you name your artifacts, it may +be necessary to rename the artifact if you want to reuse the name. To then +combine the previous artifact with the output of trivy, the following jq +command can be used, jq -s 'add' prev-codeclimate.json trivy-codeclimate.json > gl-codeclimate.json.

+

Gitlab CI alternative template example report

+

You'll be able to see a full report in the Gitlab pipeline code quality UI, where filesystem vulnerabilities and misconfigurations include links to the flagged files and image vulnerabilities report the image/os or runtime/library that the vulnerability originates from instead.

+

codequality

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/index.html b/v0.25.4/docs/integrations/index.html new file mode 100644 index 0000000000..37de75b9b5 --- /dev/null +++ b/v0.25.4/docs/integrations/index.html @@ -0,0 +1,3034 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Integrations

+

Scan your image automatically as part of your CI workflow, failing the workflow if a vulnerability is found. When you don't want to fail the test, specify --exit-code 0.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/integrations/travis-ci/index.html b/v0.25.4/docs/integrations/travis-ci/index.html new file mode 100644 index 0000000000..59e99f20e9 --- /dev/null +++ b/v0.25.4/docs/integrations/travis-ci/index.html @@ -0,0 +1,3055 @@ + + + + + + + + + + + + + + + + + + + + + + + Travis CI - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Travis CI

+
$ cat .travis.yml
+services:
+  - docker
+
+env:
+  global:
+    - COMMIT=${TRAVIS_COMMIT::8}
+
+before_install:
+  - docker build -t trivy-ci-test:${COMMIT} .
+  - export VERSION=$(curl --silent "https://api.github.com/repos/aquasecurity/trivy/releases/latest" | grep '"tag_name":' | sed -E 's/.*"v([^"]+)".*/\1/')
+  - wget https://github.com/aquasecurity/trivy/releases/download/v${VERSION}/trivy_${VERSION}_Linux-64bit.tar.gz
+  - tar zxvf trivy_${VERSION}_Linux-64bit.tar.gz
+script:
+  - ./trivy image --exit-code 0 --severity HIGH --no-progress trivy-ci-test:${COMMIT}
+  - ./trivy image --exit-code 1 --severity CRITICAL --no-progress trivy-ci-test:${COMMIT}
+cache:
+  directories:
+    - $HOME/.cache/trivy
+
+

Example +Repository

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/comparison/cfsec/index.html b/v0.25.4/docs/misconfiguration/comparison/cfsec/index.html new file mode 100644 index 0000000000..c80994e226 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/comparison/cfsec/index.html @@ -0,0 +1,3108 @@ + + + + + + + + + + + + + + + + + + + + + + + vs cfsec - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

vs cfsec

+

cfsec uses static analysis of your CloudFormation templates to spot potential security issues. +Trivy uses cfsec internally to scan both JSON and YAML configuration files, but Trivy doesn't support some features provided by cfsec. +This section describes the differences between Trivy and cfsec.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FeatureTrivycfsec
Built-in Policies
Custom PoliciesRego1
Policy Metadata2
Show Successes
Disable Policies
Show Issue Lines
View Statistics
Filtering by Severity
Supported FormatsDockerfile, JSON, YAML, Terraform, etc.CloudFormation JSON and YAML
+

cfsec is designed for CloudFormation. +People who use only want to scan their CloudFormation templates should use cfsec. +People who want to scan a wide range of configuration files should use Trivy.

+
+
+
    +
  1. +

    CloudFormation files are not supported 

    +
  2. +
  3. +

    To enrich the results such as ID, Title, Description, Severity, etc. 

    +
  4. +
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/comparison/conftest/index.html b/v0.25.4/docs/misconfiguration/comparison/conftest/index.html new file mode 100644 index 0000000000..f8fea161ab --- /dev/null +++ b/v0.25.4/docs/misconfiguration/comparison/conftest/index.html @@ -0,0 +1,3167 @@ + + + + + + + + + + + + + + + + + + + + + + + vs Conftest - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

vs Conftest

+

Conftest is a really nice tool to help you write tests against structured configuration data. +Misconfiguration detection in Trivy is heavily inspired by Conftest and provides similar features Conftest has. +This section describes the differences between Trivy and Conftest.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FeatureTrivyConftest
Support Rego Language
Built-in Policies
Custom Policies
Custom Data
Combine
Combine per Policy
Policy Input Selector1
Policy Metadata23
Filtering by Severity
Rule-based Exceptions
Namespace-based Exceptions
Sharing Policies
Show Successes
Flexible Exit Code
Rego Unit Tests4
Go Testing
Verbose Trace
Supported Formats6 formats514 formats6
+

Trivy offers built-in policies and a variety of options, while Conftest only supports custom policies. +In other words, Conftest is simpler and lighter.

+

Conftest is a general testing tool for configuration files, and Trivy is more security-focused. +People who need an out-of-the-box misconfiguration scanner should use Trivy. +People who don't need built-in policies and write your policies should use Conftest.

+
+
+
    +
  1. +

    Pass only the types of configuration file as input, specified in selector 

    +
  2. +
  3. +

    To enrich the results such as ID, Title, Description, etc. 

    +
  4. +
  5. +

    Conftest supports structured errors in rules, but they are free format and not natively supported by Conftest. 

    +
  6. +
  7. +

    Trivy is not able to run *_test.rego like conftest verify

    +
  8. +
  9. +

    Dockerfile, HCL, HCL2, JSON, TOML, and YAML 

    +
  10. +
  11. +

    CUE, Dockerfile, EDN, HCL, HCL2, HOCON, Ignore files, INI, JSON, Jsonnet, TOML, VCL, XML, and YAML 

    +
  12. +
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/comparison/tfsec/index.html b/v0.25.4/docs/misconfiguration/comparison/tfsec/index.html new file mode 100644 index 0000000000..3c7e71e8c1 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/comparison/tfsec/index.html @@ -0,0 +1,3113 @@ + + + + + + + + + + + + + + + + + + + + + + + vs tfsec - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

vs tfsec

+

tfsec uses static analysis of your Terraform templates to spot potential security issues. +Trivy uses tfsec internally to scan Terraform HCL files, but Trivy doesn't support some features provided by tfsec. +This section describes the differences between Trivy and tfsec.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FeatureTrivytfsec
Built-in Policies
Custom PoliciesRego1JSON and YAML
Policy Metadata2
Show Successes
Disable Policies
Show Issue Lines
Support .tfvars
View Statistics
Filtering by Severity
Supported FormatsDockerfile, JSON, YAML, Terraform, etc.Terraform
+

tfsec is designed for Terraform. +People who use only Terraform should use tfsec. +People who want to scan a wide range of configuration files should use Trivy.

+
+
+
    +
  1. +

    Terraform HCL files are not supported. 

    +
  2. +
  3. +

    To enrich the results such as ID, Title, Description, Severity, etc. 

    +
  4. +
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/custom/combine/index.html b/v0.25.4/docs/misconfiguration/custom/combine/index.html new file mode 100644 index 0000000000..c90500e1a8 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/custom/combine/index.html @@ -0,0 +1,3146 @@ + + + + + + + + + + + + + + + + + + + + + + + Combine - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Combined input

+

Overview

+

Trivy usually scans each configuration file individually. +Sometimes it might be useful to compare values from different configuration files simultaneously.

+

When combine is set to true, all config files under the specified directory are combined into one input data structure.

+
+

Example

+
__rego_input__ := {
+    "combine": false,
+}
+
+
+

In "combine" mode, the input document becomes an array, where each element is an object with two fields:

+
    +
  • "path": "path/to/file": the relative file path of the respective file
  • +
  • "contents": ...: the parsed content of the respective file
  • +
+

Now you can ensure that duplicate values match across the entirety of your configuration files.

+

Return value

+

In "combine" mode, the deny entrypoint must return an object with two keys

+
+
filepath (required)
+
the relative file path of the file being evaluated
+
msg (required)
+
the message describing an issue
+
+
+

Example

+
deny[res] {
+    resource := input[i].contents
+    ... some logic ...
+
+    res := {
+        "filepath": input[i].path,
+        "msg": "something bad",
+    }
+}
+
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/custom/data/index.html b/v0.25.4/docs/misconfiguration/custom/data/index.html new file mode 100644 index 0000000000..509ef6e2da --- /dev/null +++ b/v0.25.4/docs/misconfiguration/custom/data/index.html @@ -0,0 +1,3058 @@ + + + + + + + + + + + + + + + + + + + + + + + Data - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Custom Data

+

Custom policies may require additional data in order to determine an answer.

+

For example, an allowed list of resources that can be created. +Instead of hardcoding this information inside of your policy, Trivy allows passing paths to data files with the --data flag.

+

Given the following yaml file:

+
$ cd examples/misconf/custom-data
+$ cat data/ports.yaml                                                                                                                                                                      [~/src/github.com/aquasecurity/trivy/examples/misconf/custom-data]
+services:
+  ports:
+    - "20"
+    - "20/tcp"
+    - "20/udp"
+    - "23"
+    - "23/tcp"
+
+

This can be imported into your policy:

+
import data.services
+
+ports := services.ports
+
+

Then, you need to pass data paths through --data option. +Trivy recursively searches the specified paths for JSON (*.json) and YAML (*.yaml) files.

+
$ trivy conf --policy ./policy --data data --namespaces user ./configs
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/custom/debug/index.html b/v0.25.4/docs/misconfiguration/custom/debug/index.html new file mode 100644 index 0000000000..4ef0c675b2 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/custom/debug/index.html @@ -0,0 +1,3258 @@ + + + + + + + + + + + + + + + + + + + + + + + Debugging Policies - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Debugging policies

+

When working on more complex queries (or when learning Rego), it's useful to see exactly how the policy is applied. +For this purpose you can use the --trace flag. +This will output a large trace from Open Policy Agent like the following:

+
+

Tip

+

Only failed policies show traces. If you want to debug a passed policy, you need to make it fail on purpose.

+
+
$ trivy conf --trace configs/
+2021-07-11T16:45:58.493+0300    INFO    Detected config files: 1
+
+Dockerfile (dockerfile)
+=======================
+Tests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)
+Failures: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |
+|                           |            |                      |          | Dockerfile should not be 'root'          |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+ID: DS002
+File: Dockerfile
+Namespace: appshield.dockerfile.DS002
+Query: data.appshield.dockerfile.DS002.deny
+Message: Last USER command in Dockerfile should not be 'root'
+TRACE  Enter data.appshield.dockerfile.DS002.deny = _
+TRACE  | Eval data.appshield.dockerfile.DS002.deny = _
+TRACE  | Index data.appshield.dockerfile.DS002.deny matched 2 rules)
+TRACE  | Enter data.appshield.dockerfile.DS002.deny
+TRACE  | | Eval data.appshield.dockerfile.DS002.fail_user_count
+TRACE  | | Index data.appshield.dockerfile.DS002.fail_user_count (matched 1 rule)
+TRACE  | | Enter data.appshield.dockerfile.DS002.fail_user_count
+TRACE  | | | Eval __local559__ = data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Index data.appshield.dockerfile.DS002.get_user (matched 1 rule)
+TRACE  | | | Enter data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Eval user = data.lib.docker.user[_]
+TRACE  | | | | Index data.lib.docker.user (matched 1 rule)
+TRACE  | | | | Enter data.lib.docker.user
+TRACE  | | | | | Eval instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Exit data.lib.docker.user
+TRACE  | | | | Eval username = user.Value[_]
+TRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Redo username = user.Value[_]
+TRACE  | | | | Redo user = data.lib.docker.user[_]
+TRACE  | | | | Redo data.lib.docker.user
+TRACE  | | | | | Redo instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Exit data.lib.docker.user
+TRACE  | | | | Eval username = user.Value[_]
+TRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Redo username = user.Value[_]
+TRACE  | | | | Redo user = data.lib.docker.user[_]
+TRACE  | | | | Redo data.lib.docker.user
+TRACE  | | | | | Redo instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | Eval count(__local559__, __local391__)
+TRACE  | | | Eval lt(__local391__, 1)
+TRACE  | | | Fail lt(__local391__, 1)
+TRACE  | | | Redo count(__local559__, __local391__)
+TRACE  | | | Redo __local559__ = data.appshield.dockerfile.DS002.get_user
+TRACE  | | Fail data.appshield.dockerfile.DS002.fail_user_count
+TRACE  | Enter data.appshield.dockerfile.DS002.deny
+TRACE  | | Eval data.appshield.dockerfile.DS002.fail_last_user_root
+TRACE  | | Index data.appshield.dockerfile.DS002.fail_last_user_root (matched 1 rule)
+TRACE  | | Enter data.appshield.dockerfile.DS002.fail_last_user_root
+TRACE  | | | Eval __local560__ = data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Index data.appshield.dockerfile.DS002.get_user (matched 1 rule)
+TRACE  | | | Enter data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Eval user = data.lib.docker.user[_]
+TRACE  | | | | Index data.lib.docker.user (matched 1 rule)
+TRACE  | | | | Enter data.lib.docker.user
+TRACE  | | | | | Eval instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Exit data.lib.docker.user
+TRACE  | | | | Eval username = user.Value[_]
+TRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Redo username = user.Value[_]
+TRACE  | | | | Redo user = data.lib.docker.user[_]
+TRACE  | | | | Redo data.lib.docker.user
+TRACE  | | | | | Redo instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Exit data.lib.docker.user
+TRACE  | | | | Eval username = user.Value[_]
+TRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Redo username = user.Value[_]
+TRACE  | | | | Redo user = data.lib.docker.user[_]
+TRACE  | | | | Redo data.lib.docker.user
+TRACE  | | | | | Redo instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | Eval cast_array(__local560__, __local392__)
+TRACE  | | | Eval user = __local392__
+TRACE  | | | Eval __local561__ = data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Index data.appshield.dockerfile.DS002.get_user (matched 1 rule)
+TRACE  | | | Enter data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Eval user = data.lib.docker.user[_]
+TRACE  | | | | Index data.lib.docker.user (matched 1 rule)
+TRACE  | | | | Enter data.lib.docker.user
+TRACE  | | | | | Eval instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Exit data.lib.docker.user
+TRACE  | | | | Eval username = user.Value[_]
+TRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Redo username = user.Value[_]
+TRACE  | | | | Redo user = data.lib.docker.user[_]
+TRACE  | | | | Redo data.lib.docker.user
+TRACE  | | | | | Redo instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Exit data.lib.docker.user
+TRACE  | | | | Eval username = user.Value[_]
+TRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo data.appshield.dockerfile.DS002.get_user
+TRACE  | | | | Redo username = user.Value[_]
+TRACE  | | | | Redo user = data.lib.docker.user[_]
+TRACE  | | | | Redo data.lib.docker.user
+TRACE  | | | | | Redo instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | | | Eval instruction.Cmd = "user"
+TRACE  | | | | | Fail instruction.Cmd = "user"
+TRACE  | | | | | Redo instruction = input.stages[_][_]
+TRACE  | | | Eval count(__local561__, __local393__)
+TRACE  | | | Eval len = __local393__
+TRACE  | | | Eval minus(len, 1, __local394__)
+TRACE  | | | Eval user[__local394__] = "root"
+TRACE  | | | Exit data.appshield.dockerfile.DS002.fail_last_user_root
+TRACE  | | Eval res = "Last USER command in Dockerfile should not be 'root'"
+TRACE  | | Exit data.appshield.dockerfile.DS002.deny
+TRACE  | Redo data.appshield.dockerfile.DS002.deny
+TRACE  | | Redo res = "Last USER command in Dockerfile should not be 'root'"
+TRACE  | | Redo data.appshield.dockerfile.DS002.fail_last_user_root
+TRACE  | | Redo data.appshield.dockerfile.DS002.fail_last_user_root
+TRACE  | | | Redo user[__local394__] = "root"
+TRACE  | | | Redo minus(len, 1, __local394__)
+TRACE  | | | Redo len = __local393__
+TRACE  | | | Redo count(__local561__, __local393__)
+TRACE  | | | Redo __local561__ = data.appshield.dockerfile.DS002.get_user
+TRACE  | | | Redo user = __local392__
+TRACE  | | | Redo cast_array(__local560__, __local392__)
+TRACE  | | | Redo __local560__ = data.appshield.dockerfile.DS002.get_user
+TRACE  | Exit data.appshield.dockerfile.DS002.deny = _
+TRACE  Redo data.appshield.dockerfile.DS002.deny = _
+TRACE  | Redo data.appshield.dockerfile.DS002.deny = _
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/custom/examples/index.html b/v0.25.4/docs/misconfiguration/custom/examples/index.html new file mode 100644 index 0000000000..96c18b536c --- /dev/null +++ b/v0.25.4/docs/misconfiguration/custom/examples/index.html @@ -0,0 +1,3569 @@ + + + + + + + + + + + + + + + + + + + + + + + Examples - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Examples

+

Custom Policy

+

Kubernetes

+

See here.

+

The custom policy is defined in user.kubernetes.ID001 package. +You need to pass the package prefix you want to evaluate through --namespaces option. +In this case, the package prefix should be user, user.kuberntes, or user.kubernetes.ID001.

+

Dockerfile

+

See here.

+

The input will be a dictionary of stages.

+

Single Stage

+
+Example +

Dockerfile +

FROM foo
+COPY . /
+RUN echo hello
+

+

Rego Input +

{
+    "stages": {
+        "foo": [
+            {
+                "Cmd": "from",
+                "EndLine": 1,
+                "Flags": [],
+                "JSON": false,
+                "Original": "FROM foo",
+                "Stage": 0,
+                "StartLine": 1,
+                "SubCmd": "",
+                "Value": [
+                    "foo"
+                ]
+            },
+            {
+                "Cmd": "copy",
+                "EndLine": 2,
+                "Flags": [],
+                "JSON": false,
+                "Original": "COPY . /",
+                "Stage": 0,
+                "StartLine": 2,
+                "SubCmd": "",
+                "Value": [
+                    ".",
+                    "/"
+                ]
+            },
+            {
+                "Cmd": "run",
+                "EndLine": 3,
+                "Flags": [],
+                "JSON": false,
+                "Original": "RUN echo hello",
+                "Stage": 0,
+                "StartLine": 3,
+                "SubCmd": "",
+                "Value": [
+                    "echo hello"
+                ]
+            }
+        ]
+    }
+}
+

+
+

Multi Stage

+
+Example +

Dockerfile +

FROM golang:1.16 AS builder
+WORKDIR /go/src/github.com/alexellis/href-counter/
+RUN go get -d -v golang.org/x/net/html
+COPY app.go .
+RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o app .
+
+FROM alpine:latest
+RUN apk --no-cache add ca-certificates \
+&& apk add --no-cache bash
+WORKDIR /root/
+COPY --from=builder /go/src/github.com/alexellis/href-counter/app .
+CMD ["./app"]
+

+

Rego Input +

{
+    "stages": {
+        "alpine:latest": [
+            {
+                "Cmd": "from",
+                "EndLine": 7,
+                "Flags": [],
+                "JSON": false,
+                "Original": "FROM alpine:latest",
+                "Stage": 1,
+                "StartLine": 7,
+                "SubCmd": "",
+                "Value": [
+                    "alpine:latest"
+                ]
+            },
+            {
+                "Cmd": "run",
+                "EndLine": 9,
+                "Flags": [],
+                "JSON": false,
+                "Original": "RUN apk --no-cache add ca-certificates     \u0026\u0026 apk add --no-cache bash",
+                "Stage": 1,
+                "StartLine": 8,
+                "SubCmd": "",
+                "Value": [
+                    "apk --no-cache add ca-certificates     \u0026\u0026 apk add --no-cache bash"
+                ]
+            },
+            {
+                "Cmd": "workdir",
+                "EndLine": 10,
+                "Flags": [],
+                "JSON": false,
+                "Original": "WORKDIR /root/",
+                "Stage": 1,
+                "StartLine": 10,
+                "SubCmd": "",
+                "Value": [
+                    "/root/"
+                ]
+            },
+            {
+                "Cmd": "copy",
+                "EndLine": 11,
+                "Flags": [
+                    "--from=builder"
+                ],
+                "JSON": false,
+                "Original": "COPY --from=builder /go/src/github.com/alexellis/href-counter/app .",
+                "Stage": 1,
+                "StartLine": 11,
+                "SubCmd": "",
+                "Value": [
+                    "/go/src/github.com/alexellis/href-counter/app",
+                    "."
+                ]
+            },
+            {
+                "Cmd": "cmd",
+                "EndLine": 12,
+                "Flags": [],
+                "JSON": true,
+                "Original": "CMD [\"./app\"]",
+                "Stage": 1,
+                "StartLine": 12,
+                "SubCmd": "",
+                "Value": [
+                    "./app"
+                ]
+            }
+        ],
+        "golang:1.16 AS builder": [
+            {
+                "Cmd": "from",
+                "EndLine": 1,
+                "Flags": [],
+                "JSON": false,
+                "Original": "FROM golang:1.16 AS builder",
+                "Stage": 0,
+                "StartLine": 1,
+                "SubCmd": "",
+                "Value": [
+                    "golang:1.16",
+                    "AS",
+                    "builder"
+                ]
+            },
+            {
+                "Cmd": "workdir",
+                "EndLine": 2,
+                "Flags": [],
+                "JSON": false,
+                "Original": "WORKDIR /go/src/github.com/alexellis/href-counter/",
+                "Stage": 0,
+                "StartLine": 2,
+                "SubCmd": "",
+                "Value": [
+                    "/go/src/github.com/alexellis/href-counter/"
+                ]
+                },
+            {
+                "Cmd": "run",
+                "EndLine": 3,
+                "Flags": [],
+                "JSON": false,
+                "Original": "RUN go get -d -v golang.org/x/net/html",
+                "Stage": 0,
+                "StartLine": 3,
+                "SubCmd": "",
+                "Value": [
+                    "go get -d -v golang.org/x/net/html"
+                ]
+            },
+            {
+                "Cmd": "copy",
+                "EndLine": 4,
+                "Flags": [],
+                "JSON": false,
+                "Original": "COPY app.go .",
+                "Stage": 0,
+                "StartLine": 4,
+                "SubCmd": "",
+                "Value": [
+                    "app.go",
+                    "."
+                ]
+            },
+            {
+                "Cmd": "run",
+                "EndLine": 5,
+                "Flags": [],
+                "JSON": false,
+                "Original": "RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o app .",
+                "Stage": 0,
+                "StartLine": 5,
+                "SubCmd": "",
+                "Value": [
+                    "CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o app ."
+                ]
+            }
+        ]
+    }
+}
+

+
+

Docker Compose

+

See here.

+

Docker Compose uses YAML format for configurations. You can apply your Rego policies to docker-compose.yml.

+

HCL

+

See here.

+

Trivy parses HCL files and converts into structured data.

+
+

Warning

+

Terraform HCL files are not supported yet.

+
+

Terraform Plan

+

See here.

+

Use the command terraform show to convert the Terraform plan into JSON so that OPA can read the plan.

+
$ terraform init
+$ terraform plan --out tfplan.binary
+$ terraform show -json tfplan.binary > tfplan.json
+
+

For more details, see also OPA document.

+

Serverless Framework

+

See here.

+

Server Framework uses YAML format for configurations. You can apply your Rego policies to serverless.yaml.

+

Custom Data

+

See here.

+

Combined Input

+

See here.

+

Go Testing

+

See here.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/custom/index.html b/v0.25.4/docs/misconfiguration/custom/index.html new file mode 100644 index 0000000000..937b46aae0 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/custom/index.html @@ -0,0 +1,3494 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Custom Policies

+

Overview

+

You can write custom policies in Rego. +Once you finish writing custom policies, you can pass the directory where those policies are stored with --policy option.

+
trivy conf --policy /path/to/custom_policies --namespaces user /path/to/config_dir
+
+

As for --namespaces option, the detail is described as below.

+

File formats

+

If a file name matches the following file patterns, Trivy will parse the file and pass it as input to your Rego policy.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
File formatFile pattern
JSON*.json
YAML*.yaml
TOML*.toml
HCL*.hcl, *.hcl1, and *.hcl2
DockerfileDockerfile, Dockerfile.*, and *.Dockerfile
+

Configuration languages

+

In the above general file formats, Trivy automatically identifies the following types of configuration files:

+
    +
  • Ansible (YAML)
  • +
  • CloudFormation (JSON/YAML)
  • +
  • Kubernetes (JSON/YAML)
  • +
+

This is useful for filtering inputs, as described below.

+
+

Warning

+

Custom policies do not support Terraform at the moment.

+
+

Rego format

+

A single package must contain only one policy.

+
+

Example

+
package user.kubernetes.ID001
+
+__rego_metadata__ := {
+    "id": "ID001",
+    "title": "Deployment not allowed",
+    "severity": "LOW",
+    "type": "Custom Kubernetes Check",
+    "description": "Deployments are not allowed because of some reasons.",
+}
+
+__rego_input__ := {
+    "selector": [
+        {"type": "kubernetes"},
+    ],
+}
+
+deny[msg] {
+    input.kind == "Deployment"
+    msg = sprintf("Found deployment '%s' but deployments are not allowed", [input.metadata.name])
+}
+
+
+

In this example, ID001 "Deployment not allowed" is defined under user.kubernetes.ID001. +If you add a new custom policy, it must be defined under a new package like user.kubernetes.ID002.

+

Policy structure

+
+
package (required)
+
+
    +
  • MUST follow the Rego's specification
  • +
  • MUST be unique per policy
  • +
  • SHOULD include policy id for uniqueness
  • +
  • MAY include the group name such as kubernetes for clarity
      +
    • Group name has no effect on policy evaluation
    • +
    +
  • +
+
+
__rego_metadata__ (optional)
+
+
    +
  • SHOULD be defined for clarity since these values will be displayed in the scan results
  • +
+
+
__rego_input__ (optional)
+
+
    +
  • MAY be defined when you want to specify input format
  • +
+
+
deny (required)
+
+
    +
  • SHOULD be deny or start with deny_
      +
    • Although warn, warn_*, violation, violation_ also work for compatibility, deny is recommended as severity can be defined in __rego_metadata__.
    • +
    +
  • +
  • SHOULD return string
      +
    • Although object with msg field is accepted, other fields are dropped and string is recommended.
    • +
    • e.g. {"msg": "deny message", "details": "something"}
    • +
    +
  • +
+
+
+

Package

+

A package name must be unique per policy.

+
+

Example

+
package user.kubernetes.ID001
+
+
+

By default, only appshield.* packages will be evaluated. +If you define custom packages, you have to specify the package prefix via --namespaces option.

+
trivy conf --policy /path/to/custom_policies --namespaces user /path/to/config_dir
+
+

In this case, user.* will be evaluated. +Any package prefixes such as main and user are allowed.

+

Metadata

+

Metadata helps enrich Trivy's scan results with useful information.

+
+

Example

+
__rego_metadata__ := {
+    "id": "ID001",
+    "title": "Deployment not allowed",
+    "severity": "LOW",
+    "type": "Custom Kubernetes Check",
+    "description": "Deployments are not allowed because of some reasons.",
+    "recommended_actions": "Remove Deployment",
+    "url": "https://cloud.google.com/blog/products/containers-kubernetes/kubernetes-best-practices-resource-requests-and-limits",
+}
+
+
+

All fields under __rego_metadata__ are optional.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Field nameAllowed valuesDefault valueIn tableIn JSON
idAny charactersN/A
titleAny charactersN/A
severityLOW, MEDIUM, HIGH, CRITICALUNKNOWN
typeAny charactersN/A
descriptionAny characters
recommended_actionsAny characters
urlAny characters
+

Some fields are displayed in scan results.

+
deployment.yaml (kubernetes)
+============================
+Tests: 28 (SUCCESSES: 14, FAILURES: 14, EXCEPTIONS: 0)
+Failures: 14 (HIGH: 1)
+
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |                CHECK                | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+| Custom Kubernetes Check   |   ID001    | Deployment not allowed              |   LOW    | Found deployment 'test' but deployments  |
+|                           |            |                                     |          | are not allowed                          |
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+
+

Input

+

You can specify input format via __rego_input__. +All fields under __rego_input are optional.

+
+

Example

+
__rego_input__ := {
+    "combine": false,
+    "selector": [
+        {"type": "kubernetes"},
+    ],
+}
+
+
+
+
combine (boolean)
+
The details is here.
+
selector (array)
+
+

This option filters the input by file formats or configuration languages. +In the above example, Trivy passes only Kubernetes files to this policy. +Even if Dockerfile exists in the specified directory, it will not be passed to the policy as input.

+

When configuration language such as Kubernetes is not identified, file format such as JSON will be used as type. +When configuration language is identified, it will overwrite type.

+
+

Example

+

pod.yaml including Kubernetes Pod will be handled as kubernetes, not yaml. +type is overwritten by kubernetes from yaml.

+
+

type accepts kubernetes, dockerfile, ansible, cloudformation, json, yaml, toml, or hcl.

+
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/custom/testing/index.html b/v0.25.4/docs/misconfiguration/custom/testing/index.html new file mode 100644 index 0000000000..ff64747424 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/custom/testing/index.html @@ -0,0 +1,3184 @@ + + + + + + + + + + + + + + + + + + + + + + + Testing - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Testing

+

It is highly recommended to write tests for your custom policies.

+

Rego testing

+

To help you verify the correctness of your custom policies, OPA gives you a framework that you can use to write tests for your policies. +By writing tests for your custom policies you can speed up the development process of new rules and reduce the amount of time it takes to modify rules as requirements evolve.

+

For more details, see Policy Testing.

+
+

Example

+
package user.dockerfile.ID002
+
+test_add_denied {
+    r := deny with input as {"stages": {"alpine:3.13": [
+        {"Cmd": "add", "Value": ["/target/resources.tar.gz", "resources.jar"]},
+        {"Cmd": "add", "Value": ["/target/app.jar", "app.jar"]},
+    ]}}
+
+    count(r) == 1
+    r[_] == "Consider using 'COPY /target/app.jar app.jar' command instead of 'ADD /target/app.jar app.jar'"
+}
+
+
+

To write tests for custom policies, you can refer to existing tests under AppShield.

+

Go testing

+

Fanal which is a core library of Trivy can be imported as a Go library. +You can scan config files in Go and test your custom policies using Go's testing methods, such as table-driven tests. +This allows you to use the actual configuration file as input, making it easy to prepare test data and ensure that your custom policies work in practice.

+

In particular, Dockerfile and HCL need to be converted to structural data as input, which may be different from the expected input format.

+
+

Tip

+

We recommend writing OPA and Go tests both since they have different roles, like unit tests and integration tests.

+
+

The following example stores allowed and denied configuration files in a directory. +Successes contains the result of successes, and Failures contains the result of failures.

+
{
+    name:  "disallowed ports",
+    input: "configs/",
+    fields: fields{
+        policyPaths: []string{"policy"},
+        dataPaths:   []string{"data"},
+        namespaces:  []string{"user"},
+    },
+    want: []types.Misconfiguration{
+        {
+            FileType: types.Dockerfile,
+            FilePath: "Dockerfile.allowed",
+            Successes: types.MisconfResults{
+                {
+                    Namespace: "user.dockerfile.ID002",
+                    PolicyMetadata: types.PolicyMetadata{
+                        ID:          "ID002",
+                        Type:        "Docker Custom Check",
+                        Title:       "Disallowed ports exposed",
+                        Severity:    "HIGH",
+                    },
+                },
+            },
+        },
+        {
+            FileType: types.Dockerfile,
+            FilePath: "Dockerfile.denied",
+            Failures: types.MisconfResults{
+                {
+                    Namespace: "user.dockerfile.ID002",
+                    Message:   "Port 23 should not be exposed",
+                    PolicyMetadata: types.PolicyMetadata{
+                        ID:          "ID002",
+                        Type:        "Docker Custom Check",
+                        Title:       "Disallowed ports exposed",
+                        Severity:    "HIGH",
+                    },
+                },
+            },
+        },
+    },
+},
+
+

Dockerfile.allowed has one successful result in Successes, while Dockerfile.denied has one failure result in Failures.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/filesystem/index.html b/v0.25.4/docs/misconfiguration/filesystem/index.html new file mode 100644 index 0000000000..f63956aecd --- /dev/null +++ b/v0.25.4/docs/misconfiguration/filesystem/index.html @@ -0,0 +1,3152 @@ + + + + + + + + + + + + + + + + + + + + + + + Filesystem - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Filesystem

+

Quick start

+

Trivy scans a filesystem such as a virtual machine to detect misconfigurations.

+

You have to specify --security-checks config to enable misconfiguration detection.

+
$ trivy fs --security-checks config /path/to/dir
+
+

Internally, it is the same as config subcommand.

+

Vulnerability and Misconfiguration scanning

+

The difference between fs and config subcommand is that fs can detect both vulnerabilities and misconfiguration at the same time.

+

You have to specify --security-checks vuln,config to enable vulnerability and misconfiguration detection.

+
$ ls myapp/
+Dockerfile Pipfile.lock
+$ trivy fs --security-checks vuln,config --severity HIGH,CRITICAL myapp/
+2021-07-09T12:03:27.564+0300    INFO    Detected OS: unknown
+2021-07-09T12:03:27.564+0300    INFO    Number of language-specific files: 1
+2021-07-09T12:03:27.564+0300    INFO    Detecting pipenv vulnerabilities...
+2021-07-09T12:03:27.566+0300    INFO    Detected config files: 1
+
+Pipfile.lock (pipenv)
+=====================
+Total: 1 (HIGH: 1, CRITICAL: 0)
+
++----------+------------------+----------+-------------------+---------------+---------------------------------------+
+| LIBRARY  | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |
++----------+------------------+----------+-------------------+---------------+---------------------------------------+
+| httplib2 | CVE-2021-21240   | HIGH     | 0.12.1            | 0.19.0        | python-httplib2: Regular              |
+|          |                  |          |                   |               | expression denial of                  |
+|          |                  |          |                   |               | service via malicious header          |
+|          |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-21240 |
++----------+------------------+----------+-------------------+---------------+---------------------------------------+
+
+Dockerfile (dockerfile)
+=======================
+Tests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)
+Failures: 1 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |
+|                           |            |                      |          | Dockerfile should not be 'root'          |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+

In the above example, Trivy detected vulnerabilities of Python dependencies and misconfigurations in Dockerfile.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/iac/index.html b/v0.25.4/docs/misconfiguration/iac/index.html new file mode 100644 index 0000000000..e1f1b1af8f --- /dev/null +++ b/v0.25.4/docs/misconfiguration/iac/index.html @@ -0,0 +1,3275 @@ + + + + + + + + + + + + + + + + + + + + + + + Infrastructure as Code - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Infrastructure as Code (IaC)

+

Quick start

+

Simply specify a directory containing IaC files such as Terraform, CloudFormation and Dockerfile.

+
$ trivy config [YOUR_IaC_DIRECTORY]
+
+

Trivy will automatically fetch the managed policies and will keep them up-to-date in future scans.

+
+

Example

+
$ ls build/
+Dockerfile
+$ trivy config ./build
+2021-07-09T10:06:29.188+0300    INFO    Need to update the built-in policies
+2021-07-09T10:06:29.188+0300    INFO    Downloading the built-in policies...
+2021-07-09T10:06:30.520+0300    INFO    Detected config files: 1
+
+Dockerfile (dockerfile)
+=======================
+Tests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)
+Failures: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |
+|                           |            |                      |          | Dockerfile should not be 'root'          |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+
+

Type detection

+

The specified directory can contain mixed types of IaC files. +Trivy automatically detects config types and applies relevant policies.

+

For example, the following example holds IaC files for Terraform, CloudFormation, Kubernetes, and Dockerfile in the same directory.

+
$ ls iac/
+Dockerfile  deployment.yaml  main.tf
+$ trivy conf --severity HIGH,CRITICAL ./iac
+
+
+Result + +
2021-07-09T11:51:08.212+0300    INFO    Need to update the built-in policies
+2021-07-09T11:51:08.212+0300    INFO    Downloading the built-in policies...
+2021-07-09T11:51:09.527+0300    INFO    Detected config files: 3
+
+Dockerfile (dockerfile)
+=======================
+Tests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)
+Failures: 1 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |
+|                           |            |                      |          | Dockerfile should not be 'root'          |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+deployment.yaml (kubernetes)
+============================
+Tests: 28 (SUCCESSES: 15, FAILURES: 13, EXCEPTIONS: 0)
+Failures: 13 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |           CHECK            | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------------+----------+------------------------------------------+
+| Kubernetes Security Check |   KSV005   | SYS_ADMIN capability added |   HIGH   | Container 'hello-kubernetes' of          |
+|                           |            |                            |          | Deployment 'hello-kubernetes'            |
+|                           |            |                            |          | should not include 'SYS_ADMIN' in        |
+|                           |            |                            |          | 'securityContext.capabilities.add'       |
+|                           |            |                            |          | -->avd.aquasec.com/appshield/ksv005      |
++---------------------------+------------+----------------------------+----------+------------------------------------------+
+
+main.tf (terraform)
+===================
+Tests: 23 (SUCCESSES: 14, FAILURES: 9, EXCEPTIONS: 0)
+Failures: 9 (HIGH: 6, CRITICAL: 1)
+
++------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+
+|                   TYPE                   | MISCONF ID |                  CHECK                   | SEVERITY |                        MESSAGE                         |
++------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+
+|   Terraform Security Check powered by    |   AWS003   | AWS Classic resource usage.              |   HIGH   | Resource                                               |
+|                  tfsec                   |            |                                          |          | 'aws_db_security_group.my-group'                       |
+|                                          |            |                                          |          | uses EC2 Classic. Use a VPC instead.                   |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS003/                          |
++                                          +------------+------------------------------------------+----------+--------------------------------------------------------+
+|                                          |   AWS004   | Use of plain HTTP.                       | CRITICAL | Resource                                               |
+|                                          |            |                                          |          | 'aws_alb_listener.my-alb-listener'                     |
+|                                          |            |                                          |          | uses plain HTTP instead of HTTPS.                      |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS004/                          |
++                                          +------------+------------------------------------------+----------+--------------------------------------------------------+
+|                                          |   AWS018   | Missing description for security         |   HIGH   | Resource                                               |
+|                                          |            | group/security group rule.               |          | 'aws_security_group_rule.my-rule' should               |
+|                                          |            |                                          |          | include a description for auditing                     |
+|                                          |            |                                          |          | purposes. -->tfsec.dev/docs/aws/AWS018/                |
++                                          +------------+------------------------------------------+          +--------------------------------------------------------+
+|                                          |   AWS025   | API Gateway domain name uses outdated    |          | Resource                                               |
+|                                          |            | SSL/TLS protocols.                       |          | 'aws_api_gateway_domain_name.empty_security_policy'    |
+|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using           |
+|                                          |            |                                          |          | TLS_1_2). -->tfsec.dev/docs/aws/AWS025/                |
++                                          +            +                                          +          +--------------------------------------------------------+
+|                                          |            |                                          |          | Resource                                               |
+|                                          |            |                                          |          | 'aws_api_gateway_domain_name.missing_security_policy'  |
+|                                          |            |                                          |          | should include security_policy (defaults to outdated   |
+|                                          |            |                                          |          | SSL/TLS policy). -->tfsec.dev/docs/aws/AWS025/         |
++                                          +            +                                          +          +--------------------------------------------------------+
+|                                          |            |                                          |          | Resource                                               |
+|                                          |            |                                          |          | 'aws_api_gateway_domain_name.outdated_security_policy' |
+|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using TLS_1_2). |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS025/                          |
++                                          +------------+------------------------------------------+          +--------------------------------------------------------+
+|                                          |   AZU003   | Unencrypted managed disk.                |          | Resource 'azurerm_managed_disk.source'                 |
+|                                          |            |                                          |          | defines an unencrypted managed disk.                   |
+|                                          |            |                                          |          | -->tfsec.dev/docs/azure/AZU003/                        |
++------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+
+
+ +
+ +

You can see the config type next to each file name.

+
+

Example

+
Dockerfile (dockerfile)
+=======================
+Tests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)
+Failures: 1 (HIGH: 1, CRITICAL: 0)
+
+...
+
+deployment.yaml (kubernetes)
+============================
+Tests: 28 (SUCCESSES: 15, FAILURES: 13, EXCEPTIONS: 0)
+Failures: 13 (HIGH: 1, CRITICAL: 0)
+
+...
+
+main.tf (terraform)
+===================
+Tests: 23 (SUCCESSES: 14, FAILURES: 9, EXCEPTIONS: 0)
+Failures: 9 (HIGH: 6, CRITICAL: 1)
+
+...
+
+bucket.yaml (cloudformation)
+============================
+Tests: 9 (SUCCESSES: 3, FAILURES: 6, EXCEPTIONS: 0)
+Failures: 6 (UNKNOWN: 0, LOW: 0, MEDIUM: 2, HIGH: 4, CRITICAL: 0)
+
+
+

Example

+

See here

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/index.html b/v0.25.4/docs/misconfiguration/index.html new file mode 100644 index 0000000000..caad299ece --- /dev/null +++ b/v0.25.4/docs/misconfiguration/index.html @@ -0,0 +1,3038 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Misconfiguration Scanning

+

Trivy provides built-in policies to detect configuration issues in Docker, Kubernetes and Terraform. +Also, you can write your own policies in Rego to scan JSON, YAML, HCL, etc, like Conftest.

+

misconf

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/options/filter/index.html b/v0.25.4/docs/misconfiguration/options/filter/index.html new file mode 100644 index 0000000000..860e5bfa26 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/options/filter/index.html @@ -0,0 +1,3339 @@ + + + + + + + + + + + + + + + + + + + + + + + Filtering - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Filter Misconfigurations

+

By Severity

+

Use --severity option.

+
trivy conf --severity HIGH,CRITICAL examples/misconf/mixed
+
+
+Result + +
2021-07-10T17:37:13.267+0300    INFO    Detected config files: 4
+
+configs/Dockerfile (dockerfile)
+===============================
+Tests: 23 (SUCCESSES: 21, FAILURES: 2, EXCEPTIONS: 0)
+Failures: 2 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Specify at least 1 USER                  |
+|                           |            |                      |          | command in Dockerfile with               |
+|                           |            |                      |          | non-root user as argument                |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+configs/deployment.yaml (kubernetes)
+====================================
+Tests: 28 (SUCCESSES: 14, FAILURES: 14, EXCEPTIONS: 0)
+Failures: 14 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |                CHECK                | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+| Kubernetes Security Check |   KSV006   | docker.sock is mounted to container |   HIGH   | Deployment 'hello-kubernetes' should     |
+|                           |            |                                     |          | not specify '/var/run/docker.socker' in  |
+|                           |            |                                     |          | 'spec.template.volumes.hostPath.path'    |
+|                           |            |                                     |          | -->avd.aquasec.com/appshield/ksv006      |
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+
+configs/main.tf (terraform)
+===========================
+Tests: 19 (SUCCESSES: 11, FAILURES: 8, EXCEPTIONS: 0)
+Failures: 8 (HIGH: 6, CRITICAL: 1)
+
++------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+
+|                   TYPE                   | MISCONF ID |                  CHECK                   | SEVERITY |                        MESSAGE                         |
++------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+
+|   Terraform Security Check powered by    |   AWS003   | AWS Classic resource usage.              |   HIGH   | Resource                                               |
+|                  tfsec                   |            |                                          |          | 'aws_db_security_group.my-group'                       |
+|                                          |            |                                          |          | uses EC2 Classic. Use a VPC instead.                   |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS003/                          |
++                                          +------------+------------------------------------------+----------+--------------------------------------------------------+
+|                                          |   AWS004   | Use of plain HTTP.                       | CRITICAL | Resource                                               |
+|                                          |            |                                          |          | 'aws_alb_listener.my-alb-listener'                     |
+|                                          |            |                                          |          | uses plain HTTP instead of HTTPS.                      |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS004/                          |
++                                          +------------+------------------------------------------+----------+--------------------------------------------------------+
+|                                          |   AWS018   | Missing description for security         |   HIGH   | Resource                                               |
+|                                          |            | group/security group rule.               |          | 'aws_security_group_rule.my-rule' should               |
+|                                          |            |                                          |          | include a description for auditing                     |
+|                                          |            |                                          |          | purposes. -->tfsec.dev/docs/aws/AWS018/                |
++                                          +------------+------------------------------------------+          +--------------------------------------------------------+
+|                                          |   AWS025   | API Gateway domain name uses outdated    |          | Resource                                               |
+|                                          |            | SSL/TLS protocols.                       |          | 'aws_api_gateway_domain_name.empty_security_policy'    |
+|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using           |
+|                                          |            |                                          |          | TLS_1_2). -->tfsec.dev/docs/aws/AWS025/                |
++                                          +            +                                          +          +--------------------------------------------------------+
+|                                          |            |                                          |          | Resource                                               |
+|                                          |            |                                          |          | 'aws_api_gateway_domain_name.missing_security_policy'  |
+|                                          |            |                                          |          | should include security_policy (defaults to outdated   |
+|                                          |            |                                          |          | SSL/TLS policy). -->tfsec.dev/docs/aws/AWS025/         |
++                                          +            +                                          +          +--------------------------------------------------------+
+|                                          |            |                                          |          | Resource                                               |
+|                                          |            |                                          |          | 'aws_api_gateway_domain_name.outdated_security_policy' |
+|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using TLS_1_2). |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS025/                          |
++                                          +------------+------------------------------------------+          +--------------------------------------------------------+
+|                                          |   AZU003   | Unencrypted managed disk.                |          | Resource 'azurerm_managed_disk.source'                 |
+|                                          |            |                                          |          | defines an unencrypted managed disk.                   |
+|                                          |            |                                          |          | -->tfsec.dev/docs/azure/AZU003/                        |
++------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+
+
+configs/variables.tf (terraform)
+================================
+Tests: 1 (SUCCESSES: 1, FAILURES: 0, EXCEPTIONS: 0)
+Failures: 0 (HIGH: 0, CRITICAL: 0)
+
+ +
+ +

By Misconfiguration IDs

+

Use .trivyignore.

+
$ cat .trivyignore
+# Accept the risk
+AWS003
+AWS018
+AWS025
+
+$ trivy conf --severity HIGH,CRITICAL examples/misconf/mixed
+
+
+Result + +
2021-07-10T17:38:51.306+0300    INFO    Detected config files: 4
+
+configs/Dockerfile (dockerfile)
+===============================
+Tests: 23 (SUCCESSES: 21, FAILURES: 2, EXCEPTIONS: 0)
+Failures: 2 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Specify at least 1 USER                  |
+|                           |            |                      |          | command in Dockerfile with               |
+|                           |            |                      |          | non-root user as argument                |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+configs/deployment.yaml (kubernetes)
+====================================
+Tests: 28 (SUCCESSES: 14, FAILURES: 14, EXCEPTIONS: 0)
+Failures: 14 (HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |                CHECK                | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+| Kubernetes Security Check |   KSV006   | docker.sock is mounted to container |   HIGH   | Deployment 'hello-kubernetes' should     |
+|                           |            |                                     |          | not specify '/var/run/docker.socker' in  |
+|                           |            |                                     |          | 'spec.template.volumes.hostPath.path'    |
+|                           |            |                                     |          | -->avd.aquasec.com/appshield/ksv006      |
++---------------------------+------------+-------------------------------------+----------+------------------------------------------+
+
+configs/main.tf (terraform)
+===========================
+Tests: 19 (SUCCESSES: 11, FAILURES: 8, EXCEPTIONS: 0)
+Failures: 8 (HIGH: 1, CRITICAL: 1)
+
++------------------------------------------+------------+---------------------------+----------+------------------------------------------+
+|                   TYPE                   | MISCONF ID |           CHECK           | SEVERITY |                 MESSAGE                  |
++------------------------------------------+------------+---------------------------+----------+------------------------------------------+
+|   Terraform Security Check powered by    |   AWS004   | Use of plain HTTP.        | CRITICAL | Resource                                 |
+|                  tfsec                   |            |                           |          | 'aws_alb_listener.my-alb-listener'       |
+|                                          |            |                           |          | uses plain HTTP instead of HTTPS.        |
+|                                          |            |                           |          | -->tfsec.dev/docs/aws/AWS004/            |
++                                          +------------+---------------------------+----------+------------------------------------------+
+|                                          |   AZU003   | Unencrypted managed disk. |   HIGH   | Resource 'azurerm_managed_disk.source'   |
+|                                          |            |                           |          | defines an unencrypted managed disk.     |
+|                                          |            |                           |          | -->tfsec.dev/docs/azure/AZU003/          |
++------------------------------------------+------------+---------------------------+----------+------------------------------------------+
+
+configs/variables.tf (terraform)
+================================
+Tests: 1 (SUCCESSES: 1, FAILURES: 0, EXCEPTIONS: 0)
+Failures: 0 (HIGH: 0, CRITICAL: 0)
+
+ +
+ +

By Exceptions

+

See Exceptions

+

Show Successes and Exceptions

+

Use --include-non-failures option to show successes and exceptions as well as failures.

+
trivy conf --severity CRITICAL --include-non-failures examples/misconf/mixed
+
+
+Result +
2021-07-10T17:44:02.049+0300    INFO    Detected config files: 4
+
+configs/Dockerfile (dockerfile)
+===============================
+Tests: 23 (SUCCESSES: 21, FAILURES: 2, EXCEPTIONS: 0)
+Failures: 2 (CRITICAL: 0)
+
++---------------------------+------------+------------------------------------------+----------+--------+-----------------+
+|           TYPE            | MISCONF ID |                  CHECK                   | SEVERITY | STATUS |     MESSAGE     |
++---------------------------+------------+------------------------------------------+----------+--------+-----------------+
+| Dockerfile Security Check |   DS006    | COPY '--from' refers to the current      | CRITICAL |  PASS  | No issues found |
+|                           |            | image                                    |          |        |                 |
++                           +------------+------------------------------------------+          +        +                 +
+|                           |   DS007    | Multiple ENTRYPOINT instructions are     |          |        |                 |
+|                           |            | listed                                   |          |        |                 |
++                           +------------+------------------------------------------+          +        +                 +
+|                           |   DS008    | Exposed port is out of range             |          |        |                 |
++                           +------------+------------------------------------------+          +        +                 +
+|                           |   DS010    | 'sudo' is used                           |          |        |                 |
++                           +------------+------------------------------------------+          +        +                 +
+|                           |   DS011    | COPY with more than two arguments is not |          |        |                 |
+|                           |            | ending with slash                        |          |        |                 |
++                           +------------+------------------------------------------+          +        +                 +
+|                           |   DS012    | Duplicate aliases are defined in         |          |        |                 |
+|                           |            | different FROMs                          |          |        |                 |
++---------------------------+------------+------------------------------------------+----------+--------+-----------------+
+
+...
+
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/options/others/index.html b/v0.25.4/docs/misconfiguration/options/others/index.html new file mode 100644 index 0000000000..9c45d52b13 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/options/others/index.html @@ -0,0 +1,3109 @@ + + + + + + + + + + + + + + + + + + + + + + + Others - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Others

+
+

Hint

+

See also Others in Vulnerability section.

+
+

File patterns

+

When a directory is given as an input, Trivy will recursively look for and test all files based on file patterns. +The default file patterns are here.

+

In addition to the default file patterns, the --file-patterns option takes regexp patterns to look for your files. +For example, it may be useful when your file name of Dockerfile doesn't match the default patterns.

+

This can be repeated for specifying multiple file patterns. +Allowed values are here:

+
    +
  • dockerfile
  • +
  • yaml
  • +
  • json
  • +
  • toml
  • +
  • hcl
  • +
+

For more details, see an example

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/options/policy/index.html b/v0.25.4/docs/misconfiguration/options/policy/index.html new file mode 100644 index 0000000000..9e153176e2 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/options/policy/index.html @@ -0,0 +1,3215 @@ + + + + + + + + + + + + + + + + + + + + + + + Policy - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Policy

+

Pass custom policies

+

You can pass directories including your custom policies through --policy option. +This can be repeated for specifying multiple directories.

+
cd examplex/misconf/
+trivy conf --policy custom-policy/policy --policy combine/policy --namespaces user misconf/mixed
+
+

For more details, see Custom Policies.

+
+

Tip

+

You also need to specify --namespaces option.

+
+

Pass custom data

+

You can pass directories including your custom data through --data option. +This can be repeated for specifying multiple directories.

+
cd examples/misconf/custom-data
+trivy conf --policy ./policy --data ./data --namespaces user ./configs
+
+

For more details, see Custom Data.

+

Pass namespaces

+

By default, Trivy evaluate policies defined in appshield.*. +If you want to evaluate custom policies in other packages, you have to specify package prefixes through --namespaces option. +This can be repeated for specifying multiple packages.

+
trivy conf --policy ./policy --namespaces main --namespaces user ./configs
+
+

Skip update of built-in policies

+

Trivy downloads built-in policies when it starts operating. +Then, it checks for updates every 24 hours. +You can use the --skip-policy-update option to skip it. +If you skip it the first time, the built-in policies will not be loaded.

+
+

Note

+

Even if you specify the option the first time, it will be loaded as Terraform policies are written in Go.

+
+
trivy conf --skip-policy-update examples/misconf/mixed                                                                                           [~/src/github.com/aquasecurity/trivy]
+
+
+Result + +
2021-07-10T18:04:19.083+0300    INFO    No builtin policies were loaded
+2021-07-10T18:04:19.174+0300    INFO    Detected config files: 2
+
+configs/main.tf (terraform)
+===========================
+Tests: 19 (SUCCESSES: 11, FAILURES: 8, EXCEPTIONS: 0)
+Failures: 8 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 1, CRITICAL: 1)
+
++------------------------------------------+------------+------------------------------------------+----------+------------------------------------------+
+|                   TYPE                   | MISCONF ID |                  CHECK                   | SEVERITY |                 MESSAGE                  |
++------------------------------------------+------------+------------------------------------------+----------+------------------------------------------+
+|   Terraform Security Check powered by    |   AWS004   | Use of plain HTTP.                       | CRITICAL | Resource                                 |
+|                  tfsec                   |            |                                          |          | 'aws_alb_listener.my-alb-listener'       |
+|                                          |            |                                          |          | uses plain HTTP instead of HTTPS.        |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS004/            |
++                                          +------------+------------------------------------------+----------+------------------------------------------+
+|                                          |   AWS006   | An ingress security group rule allows    |  MEDIUM  | Resource                                 |
+|                                          |            | traffic from /0.                         |          | 'aws_security_group_rule.my-rule'        |
+|                                          |            |                                          |          | defines a fully open                     |
+|                                          |            |                                          |          | ingress security group rule.             |
+|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS006/            |
++                                          +------------+------------------------------------------+----------+------------------------------------------+
+|                                          |   AZU003   | Unencrypted managed disk.                |   HIGH   | Resource 'azurerm_managed_disk.source'   |
+|                                          |            |                                          |          | defines an unencrypted managed disk.     |
+|                                          |            |                                          |          | -->tfsec.dev/docs/azure/AZU003/          |
++------------------------------------------+------------+------------------------------------------+----------+------------------------------------------+
+
+configs/variables.tf (terraform)
+================================
+Tests: 1 (SUCCESSES: 1, FAILURES: 0, EXCEPTIONS: 0)
+Failures: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)
+
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/options/report/index.html b/v0.25.4/docs/misconfiguration/options/report/index.html new file mode 100644 index 0000000000..e5fecb8b52 --- /dev/null +++ b/v0.25.4/docs/misconfiguration/options/report/index.html @@ -0,0 +1,3040 @@ + + + + + + + + + + + + + + + + + + + + + + + Report Formats - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Report Formats

+

See Reports Formats in Vulnerability section.

+
+

Caution

+

Misconfiguration scanning doesn't support default templates such as XML for now.

+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/policy/builtin/index.html b/v0.25.4/docs/misconfiguration/policy/builtin/index.html new file mode 100644 index 0000000000..aad51e889c --- /dev/null +++ b/v0.25.4/docs/misconfiguration/policy/builtin/index.html @@ -0,0 +1,3164 @@ + + + + + + + + + + + + + + + + + + + + + + + Built-in Policies - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Built-in Policies

+

Policy Sources

+

Built-in policies are mainly written in Rego. +Those policies are managed under AppShield repository. +Terraform policies are currently powered by tfsec and CloudFormation policies are powered by cfsec.

+ + + + + + + + + + + + + + + + + + + + + + + + + +
Config typeSource
KubernetesAppShield
DockerfileAppShield
Terraformtfsec
CloudFormationcfsec
+

For suggestions or issues regarding policy content, please open an issue under AppShield, tfsec or cfsec repository.

+

Ansible are coming soon.

+

Policy Distribution

+

AppShield policies are distributed as an OPA bundle on GitHub Container Registry (GHCR). +When misconfiguration detection is enabled, Trivy pulls the OPA bundle from GHCR as an OCI artifact and stores it in the cache. +Those policies are then loaded into Trivy OPA engine and used for detecting misconfigurations.

+

Update Interval

+

Trivy checks for updates to OPA bundle on GHCR every 24 hours and pulls it if there are any updates.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/misconfiguration/policy/exceptions/index.html b/v0.25.4/docs/misconfiguration/policy/exceptions/index.html new file mode 100644 index 0000000000..bdfd000dfe --- /dev/null +++ b/v0.25.4/docs/misconfiguration/policy/exceptions/index.html @@ -0,0 +1,3186 @@ + + + + + + + + + + + + + + + + + + + + + + + Exceptions - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Exceptions

+

Exceptions lets you to specify cases where you allow policy violations. +Trivy supports two types of exceptions.

+
+

Info

+

Exceptions can be applied to built-in policies as well as custom policies.

+
+

Namespace-based exceptions

+

There are some cases where you need to disable built-in policies partially or fully. +Namespace-based exceptions lets you rough choose which individual packages to exempt.

+

To use namespace-based exceptions, create a Rego rule with the name exception that returns the package names to exempt. +The exception rule must be defined under namespace.exceptions. +data.namespaces includes all package names.

+
+

Example

+
package namespace.exceptions
+
+import data.namespaces
+
+exception[ns] {
+    ns := data.namespaces[_]
+    startswith(ns, "appshield")
+}
+
+
+

This example exempts all built-in policies for Kubernetes.

+

For more details, see an example.

+

Rule-based exceptions

+

There are some cases where you need more flexibility and granularity in defining which cases to exempt. +Rule-based exceptions lets you granularly choose which individual rules to exempt, while also declaring under which conditions to exempt them.

+

To use rule-based exceptions, create a Rego rule with the name exception that returns the rule name suffixes to exempt, prefixed by deny_ (for example, returning foo will exempt deny_foo). +The rule can make any other assertion, for example, on the input or data documents. +This is useful to specify the exemption for a specific case.

+

Note that if you specify the empty string, the exception will match all rules named deny.

+
exception[rules] {
+    # Logic
+
+    rules = ["foo","bar"]
+}
+
+

The above would provide an exception from deny_foo and deny_bar.

+
+

Example

+
package user.kubernetes.ID100
+
+__rego_metadata := {
+    "id": "ID100",
+    "title": "Deployment not allowed",
+    "severity": "HIGH",
+    "type": "Kubernetes Custom Check",
+}
+
+deny_deployment[msg] {
+    input.kind == "Deployment"
+    msg = sprintf("Found deployment '%s' but deployments are not allowed", [name])
+}
+
+exception[rules] {
+    input.kind == "Deployment"
+    input.metadata.name == "allow-deployment"
+
+    rules := ["deployment"]
+}
+
+
+

If you want to apply rule-based exceptions to built-in policies, you have to define the exception under the same package.

+
+

Example

+
package appshield.kubernetes.KSV012
+
+exception[rules] {
+    input.metadata.name == "can-run-as-root"
+    rules := [""]
+}
+
+
+

This exception is applied to KSV012 in AppShield. +You can get the package names in AppShield repository or the JSON output from Trivy.

+

For more details, see an example.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/client/index.html b/v0.25.4/docs/references/cli/client/index.html new file mode 100644 index 0000000000..08a0fc9c3d --- /dev/null +++ b/v0.25.4/docs/references/cli/client/index.html @@ -0,0 +1,3063 @@ + + + + + + + + + + + + + + + + + + + + + + + Client - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Client

+
NAME:
+   trivy client - client mode
+
+USAGE:
+   trivy client [command options] image_name
+
+OPTIONS:
+   --template value, -t value  output template [$TRIVY_TEMPLATE]
+   --format value, -f value    format (table, json, sarif, template) (default: "table") [$TRIVY_FORMAT]
+   --input value, -i value     input file path instead of image name [$TRIVY_INPUT]
+   --severity value, -s value  severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --output value, -o value    output file name [$TRIVY_OUTPUT]
+   --exit-code value           Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]
+   --clear-cache, -c           clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --ignore-unfixed            display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]
+   --removed-pkgs              detect vulnerabilities of removed packages (only for Alpine) (default: false) [$TRIVY_REMOVED_PKGS]
+   --vuln-type value           comma-separated list of vulnerability types (os,library) (default: "os,library") [$TRIVY_VULN_TYPE]
+   --ignorefile value          specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --timeout value             timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --ignore-policy value       specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]
+   --list-all-pkgs             enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]
+   --offline-scan              do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]
+   --token value               for authentication [$TRIVY_TOKEN]
+   --token-header value        specify a header name for token (default: "Trivy-Token") [$TRIVY_TOKEN_HEADER]
+   --remote value              server address (default: "http://localhost:4954") [$TRIVY_REMOTE]
+   --custom-headers value      custom headers [$TRIVY_CUSTOM_HEADERS]
+   --help, -h                  show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/config/index.html b/v0.25.4/docs/references/cli/config/index.html new file mode 100644 index 0000000000..8c58e1c99d --- /dev/null +++ b/v0.25.4/docs/references/cli/config/index.html @@ -0,0 +1,3061 @@ + + + + + + + + + + + + + + + + + + + + + + + Config - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Config

+
NAME:
+   trivy config - scan config files
+
+USAGE:
+   trivy config [command options] dir
+
+OPTIONS:
+   --template value, -t value                     output template [$TRIVY_TEMPLATE]
+   --format value, -f value                       format (table, json, sarif, template) (default: "table") [$TRIVY_FORMAT]
+   --severity value, -s value                     severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --output value, -o value                       output file name [$TRIVY_OUTPUT]
+   --exit-code value                              Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]
+   --skip-policy-update                           skip updating built-in policies (default: false) [$TRIVY_SKIP_POLICY_UPDATE]
+   --reset                                        remove all caches and database (default: false) [$TRIVY_RESET]
+   --clear-cache, -c                              clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --ignorefile value                             specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --timeout value                                timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --skip-files value                             specify the file paths to skip traversal [$TRIVY_SKIP_FILES]
+   --skip-dirs value                              specify the directories where the traversal is skipped [$TRIVY_SKIP_DIRS]
+   --policy value, --config-policy value          specify paths to the Rego policy files directory, applying config files [$TRIVY_POLICY]
+   --data value, --config-data value              specify paths from which data for the Rego policies will be recursively loaded [$TRIVY_DATA]
+   --policy-namespaces value, --namespaces value  Rego namespaces (default: "users") [$TRIVY_POLICY_NAMESPACES]
+   --file-patterns value                          specify file patterns [$TRIVY_FILE_PATTERNS]
+   --include-successes                            include successes of misconfigurations (default: false) [$TRIVY_INCLUDE_SUCCESSES]
+   --help, -h                                     show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/fs/index.html b/v0.25.4/docs/references/cli/fs/index.html new file mode 100644 index 0000000000..da96041f6a --- /dev/null +++ b/v0.25.4/docs/references/cli/fs/index.html @@ -0,0 +1,3071 @@ + + + + + + + + + + + + + + + + + + + + + + + Filesystem - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Filesystem

+
NAME:
+   trivy filesystem - scan local filesystem
+
+USAGE:
+   trivy filesystem [command options] dir
+
+OPTIONS:
+   --template value, -t value                     output template [$TRIVY_TEMPLATE]
+   --format value, -f value                       format (table, json, sarif, template) (default: "table") [$TRIVY_FORMAT]
+   --severity value, -s value                     severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --output value, -o value                       output file name [$TRIVY_OUTPUT]
+   --exit-code value                              Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]
+   --skip-db-update, --skip-update                skip updating vulnerability database (default: false) [$TRIVY_SKIP_UPDATE, $TRIVY_SKIP_DB_UPDATE]
+   --skip-policy-update                           skip updating built-in policies (default: false) [$TRIVY_SKIP_POLICY_UPDATE]
+   --clear-cache, -c                              clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --ignore-unfixed                               display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]
+   --vuln-type value                              comma-separated list of vulnerability types (os,library) (default: "os,library") [$TRIVY_VULN_TYPE]
+   --security-checks value                        comma-separated list of what security issues to detect (vuln,config) (default: "vuln") [$TRIVY_SECURITY_CHECKS]
+   --ignorefile value                             specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --cache-backend value                          cache backend (e.g. redis://localhost:6379) (default: "fs") [$TRIVY_CACHE_BACKEND]
+   --timeout value                                timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --no-progress                                  suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]
+   --ignore-policy value                          specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]
+   --list-all-pkgs                                enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]
+   --offline-scan                                 do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]
+   --skip-files value                             specify the file paths to skip traversal [$TRIVY_SKIP_FILES]
+   --skip-dirs value                              specify the directories where the traversal is skipped [$TRIVY_SKIP_DIRS]
+   --config-policy value                          specify paths to the Rego policy files directory, applying config files [$TRIVY_CONFIG_POLICY]
+   --config-data value                            specify paths from which data for the Rego policies will be recursively loaded [$TRIVY_CONFIG_DATA]
+   --policy-namespaces value, --namespaces value  Rego namespaces (default: "users") [$TRIVY_POLICY_NAMESPACES]
+   --server value                                 server address [$TRIVY_SERVER]
+   --token value                                  for authentication [$TRIVY_TOKEN]
+   --token-header value                           specify a header name for token (default: "Trivy-Token") [$TRIVY_TOKEN_HEADER]
+   --custom-headers value                         custom headers [$TRIVY_CUSTOM_HEADERS]
+   --help, -h                                     show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/image/index.html b/v0.25.4/docs/references/cli/image/index.html new file mode 100644 index 0000000000..31c9f1b095 --- /dev/null +++ b/v0.25.4/docs/references/cli/image/index.html @@ -0,0 +1,3066 @@ + + + + + + + + + + + + + + + + + + + + + + + Image - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Image

+
NAME:
+   trivy image - scan an image
+
+USAGE:
+   trivy image [command options] image_name
+
+OPTIONS:
+   --template value, -t value  output template [$TRIVY_TEMPLATE]
+   --format value, -f value    format (table, json, sarif, template) (default: "table") [$TRIVY_FORMAT]
+   --input value, -i value     input file path instead of image name [$TRIVY_INPUT]
+   --severity value, -s value  severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --output value, -o value    output file name [$TRIVY_OUTPUT]
+   --exit-code value           Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]
+   --skip-update               skip db update (default: false) [$TRIVY_SKIP_UPDATE]
+   --download-db-only          download/update vulnerability database but don't run a scan (default: false) [$TRIVY_DOWNLOAD_DB_ONLY]
+   --reset                     remove all caches and database (default: false) [$TRIVY_RESET]
+   --clear-cache, -c           clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --no-progress               suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]
+   --ignore-unfixed            display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]
+   --removed-pkgs              detect vulnerabilities of removed packages (only for Alpine) (default: false) [$TRIVY_REMOVED_PKGS]
+   --vuln-type value           comma-separated list of vulnerability types (os,library) (default: "os,library") [$TRIVY_VULN_TYPE]
+   --ignorefile value          specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --timeout value             timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --ignore-policy value       specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]
+   --list-all-pkgs             enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]
+   --offline-scan              do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]
+   --skip-files value          specify the file path to skip traversal [$TRIVY_SKIP_FILES]
+   --skip-dirs value           specify the directory where the traversal is skipped [$TRIVY_SKIP_DIRS]
+   --cache-backend value       cache backend (e.g. redis://localhost:6379) (default: "fs") [$TRIVY_CACHE_BACKEND]
+   --help, -h                  show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/index.html b/v0.25.4/docs/references/cli/index.html new file mode 100644 index 0000000000..979e69cb3d --- /dev/null +++ b/v0.25.4/docs/references/cli/index.html @@ -0,0 +1,3055 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Overview

+ +

Trivy has several sub commands, image, fs, repo, client and server.

+
NAME:
+   trivy - A simple and comprehensive vulnerability scanner for containers
+
+USAGE:
+   trivy [global options] command [command options] target
+
+VERSION:
+   dev
+
+COMMANDS:
+   image, i          scan an image
+   filesystem, fs    scan local filesystem
+   repository, repo  scan remote repository
+   client, c         client mode
+   server, s         server mode
+   config, conf      scan config files
+   plugin, p         manage plugins
+   version           print the version
+   help, h           Shows a list of commands or help for one command
+
+GLOBAL OPTIONS:
+   --quiet, -q        suppress progress bar and log output (default: false) [$TRIVY_QUIET]
+   --debug, -d        debug mode (default: false) [$TRIVY_DEBUG]
+   --cache-dir value  cache directory (default: "/Users/teppei/Library/Caches/trivy") [$TRIVY_CACHE_DIR]
+   --help, -h         show help (default: false)
+   --version, -v      print the version (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/plugins/index.html b/v0.25.4/docs/references/cli/plugins/index.html new file mode 100644 index 0000000000..f8c632eedd --- /dev/null +++ b/v0.25.4/docs/references/cli/plugins/index.html @@ -0,0 +1,3336 @@ + + + + + + + + + + + + + + + + + + + + + + + Plugins - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + + + + +
+
+ + + + +

Plugins

+

Trivy provides a plugin feature to allow others to extend the Trivy CLI without the need to change the Trivycode base. +This plugin system was inspired by the plugin system used in kubectl, Helm, and Conftest.

+

Overview

+

Trivy plugins are add-on tools that integrate seamlessly with Trivy. +They provide a way to extend the core feature set of Trivy, but without requiring every new feature to be written in Go and added to the core tool.

+
    +
  • They can be added and removed from a Trivy installation without impacting the core Trivy tool.
  • +
  • They can be written in any programming language.
  • +
  • They integrate with Trivy, and will show up in Trivy help and subcommands.
  • +
+
+

Warning

+

Trivy plugins available in public are not audited for security. +You should install and run third-party plugins at your own risk, since they are arbitrary programs running on your machine.

+
+

Installing a Plugin

+

A plugin can be installed using the trivy plugin install command. +This command takes a url and will download the plugin and install it in the plugin cache.

+

Trivy adheres to the XDG specification, so the location depends on whether XDG_DATA_HOME is set. +Trivy will now search XDG_DATA_HOME for the location of the Trivy plugins cache. +The preference order is as follows:

+
    +
  • XDG_DATA_HOME if set and .trivy/plugins exists within the XDG_DATA_HOME dir
  • +
  • ~/.trivy/plugins
  • +
+

Under the hood Trivy leverages go-getter to download plugins. +This means the following protocols are supported for downloading plugins:

+
    +
  • OCI Registries
  • +
  • Local Files
  • +
  • Git
  • +
  • HTTP/HTTPS
  • +
  • Mercurial
  • +
  • Amazon S3
  • +
  • Google Cloud Storage
  • +
+

For example, to download the Kubernetes Trivy plugin you can execute the following command:

+
$ trivy plugin install github.com/aquasecurity/trivy-plugin-kubectl
+
+

Using Plugins

+

Once the plugin is installed, Trivy will load all available plugins in the cache on the start of the next Trivy execution. +A plugin will be made in the Trivy CLI based on the plugin name. +To display all plugins, you can list them by trivy --help

+
$ trivy --help
+NAME:
+   trivy - A simple and comprehensive vulnerability scanner for containers
+
+USAGE:
+   trivy [global options] command [command options] target
+
+VERSION:
+   dev
+
+COMMANDS:
+   image, i          scan an image
+   filesystem, fs    scan local filesystem
+   repository, repo  scan remote repository
+   client, c         client mode
+   server, s         server mode
+   plugin, p         manage plugins
+   kubectl           scan kubectl resources
+   help, h           Shows a list of commands or help for one command
+
+

As shown above, kubectl subcommand exists in the COMMANDS section. +To call the kubectl plugin and scan existing Kubernetes deployments, you can execute the following command:

+
$ trivy kubectl deployment <deployment-id> -- --ignore-unfixed --severity CRITICAL
+
+

Internally the kubectl plugin calls the kubectl binary to fetch information about that deployment and passes the using images to Trivy. +You can see the detail here.

+

If you want to omit even the subcommand, you can use TRIVY_RUN_AS_PLUGIN environment variable.

+
$ TRIVY_RUN_AS_PLUGIN=kubectl trivy job your-job -- --format json
+
+

Installing and Running Plugins on the fly

+

trivy plugin run installs a plugin and runs it on the fly. +If the plugin is already present in the cache, the installation is skipped.

+
trivy plugin run github.com/aquasecurity/trivy-plugin-kubectl pod your-pod -- --exit-code 1
+
+

Uninstalling Plugins

+

Specify a plugin name with trivy plugin uninstall command.

+
$ trivy plugin uninstall kubectl
+
+

Building Plugins

+

Each plugin has a top-level directory, and then a plugin.yaml file.

+
your-plugin/
+  |
+  |- plugin.yaml
+  |- your-plugin.sh
+
+

In the example above, the plugin is contained inside of a directory named your-plugin. +It has two files: plugin.yaml (required) and an executable script, your-plugin.sh (optional).

+

The core of a plugin is a simple YAML file named plugin.yaml. +Here is an example YAML of trivy-plugin-kubectl plugin that adds support for Kubernetes scanning.

+
name: "kubectl"
+repository: github.com/aquasecurity/trivy-plugin-kubectl
+version: "0.1.0"
+usage: scan kubectl resources
+description: |-
+  A Trivy plugin that scans the images of a kubernetes resource.
+  Usage: trivy kubectl TYPE[.VERSION][.GROUP] NAME
+platforms:
+  - selector: # optional
+      os: darwin
+      arch: amd64
+    uri: ./trivy-kubectl # where the execution file is (local file, http, git, etc.)
+    bin: ./trivy-kubectl # path to the execution file
+  - selector: # optional
+      os: linux
+      arch: amd64
+    uri: https://github.com/aquasecurity/trivy-plugin-kubectl/releases/download/v0.1.0/trivy-kubectl.tar.gz
+    bin: ./trivy-kubectl
+
+

The plugin.yaml field should contain the following information:

+
    +
  • name: The name of the plugin. This also determines how the plugin will be made available in the Trivy CLI. For example, if the plugin is named kubectl, you can call the plugin with trivy kubectl. (required)
  • +
  • version: The version of the plugin. (required)
  • +
  • usage: A short usage description. (required)
  • +
  • description: A long description of the plugin. This is where you could provide a helpful documentation of your plugin. (required)
  • +
  • platforms: (required)
  • +
  • selector: The OS/Architecture specific variations of a execution file. (optional)
      +
    • os: OS information based on GOOS (linux, darwin, etc.) (optional)
    • +
    • arch: The architecture information based on GOARCH (amd64, arm64, etc.) (optional)
    • +
    +
  • +
  • uri: Where the executable file is. Relative path from the root directory of the plugin or remote URL such as HTTP and S3. (required)
  • +
  • bin: Which file to call when the plugin is executed. Relative path from the root directory of the plugin. (required)
  • +
+

The following rules will apply in deciding which platform to select:

+
    +
  • If both os and arch under selector match the current platform, search will stop and the platform will be used.
  • +
  • If selector is not present, the platform will be used.
  • +
  • If os matches and there is no more specific arch match, the platform will be used.
  • +
  • If no platform match is found, Trivy will exit with an error.
  • +
+

After determining platform, Trivy will download the execution file from uri and store it in the plugin cache. +When the plugin is called via Trivy CLI, bin command will be executed.

+

The plugin is responsible for handling flags and arguments. Any arguments are passed to the plugin from the trivy command.

+

Example

+

https://github.com/aquasecurity/trivy-plugin-kubectl

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/repo/index.html b/v0.25.4/docs/references/cli/repo/index.html new file mode 100644 index 0000000000..aa378b007f --- /dev/null +++ b/v0.25.4/docs/references/cli/repo/index.html @@ -0,0 +1,3065 @@ + + + + + + + + + + + + + + + + + + + + + + + Repository - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Repository

+
NAME:
+   trivy repository - scan remote repository
+
+USAGE:
+   trivy repository [command options] repo_url
+
+OPTIONS:
+   --template value, -t value  output template [$TRIVY_TEMPLATE]
+   --format value, -f value    format (table, json, sarif, template) (default: "table") [$TRIVY_FORMAT]
+   --input value, -i value     input file path instead of image name [$TRIVY_INPUT]
+   --severity value, -s value  severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --output value, -o value    output file name [$TRIVY_OUTPUT]
+   --exit-code value           Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]
+   --skip-update               skip db update (default: false) [$TRIVY_SKIP_UPDATE]
+   --clear-cache, -c           clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --ignore-unfixed            display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]
+   --removed-pkgs              detect vulnerabilities of removed packages (only for Alpine) (default: false) [$TRIVY_REMOVED_PKGS]
+   --vuln-type value           comma-separated list of vulnerability types (os,library) (default: "os,library") [$TRIVY_VULN_TYPE]
+   --ignorefile value          specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --cache-backend value       cache backend (e.g. redis://localhost:6379) (default: "fs") [$TRIVY_CACHE_BACKEND]
+   --timeout value             timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --no-progress               suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]
+   --quiet, -q                      suppress progress bar and log output (default: false) [$TRIVY_QUIET]
+   --ignore-policy value       specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]
+   --list-all-pkgs             enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]
+   --offline-scan              do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]
+   --skip-files value          specify the file path to skip traversal [$TRIVY_SKIP_FILES]
+   --skip-dirs value           specify the directory where the traversal is skipped [$TRIVY_SKIP_DIRS]
+   --help, -h                  show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/rootfs/index.html b/v0.25.4/docs/references/cli/rootfs/index.html new file mode 100644 index 0000000000..4144cb6273 --- /dev/null +++ b/v0.25.4/docs/references/cli/rootfs/index.html @@ -0,0 +1,3067 @@ + + + + + + + + + + + + + + + + + + + + + + + Rootfs - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Rootfs

+
NAME:
+   trivy rootfs - scan rootfs
+
+USAGE:
+   trivy rootfs [command options] dir
+
+OPTIONS:
+   --template value, -t value                     output template [$TRIVY_TEMPLATE]
+   --format value, -f value                       format (table, json, sarif, template) (default: "table") [$TRIVY_FORMAT]
+   --severity value, -s value                     severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --output value, -o value                       output file name [$TRIVY_OUTPUT]
+   --exit-code value                              Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]
+   --skip-db-update, --skip-update                skip updating vulnerability database (default: false) [$TRIVY_SKIP_UPDATE, $TRIVY_SKIP_DB_UPDATE]
+   --skip-policy-update                           skip updating built-in policies (default: false) [$TRIVY_SKIP_POLICY_UPDATE]
+   --clear-cache, -c                              clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --ignore-unfixed                               display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]
+   --vuln-type value                              comma-separated list of vulnerability types (os,library) (default: "os,library") [$TRIVY_VULN_TYPE]
+   --security-checks value                        comma-separated list of what security issues to detect (vuln,config) (default: "vuln") [$TRIVY_SECURITY_CHECKS]
+   --ignorefile value                             specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --cache-backend value                          cache backend (e.g. redis://localhost:6379) (default: "fs") [$TRIVY_CACHE_BACKEND]
+   --timeout value                                timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --no-progress                                  suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]
+   --ignore-policy value                          specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]
+   --list-all-pkgs                                enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]
+   --offline-scan                                 do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]
+   --skip-files value                             specify the file paths to skip traversal [$TRIVY_SKIP_FILES]
+   --skip-dirs value                              specify the directories where the traversal is skipped [$TRIVY_SKIP_DIRS]
+   --config-policy value                          specify paths to the Rego policy files directory, applying config files [$TRIVY_CONFIG_POLICY]
+   --config-data value                            specify paths from which data for the Rego policies will be recursively loaded [$TRIVY_CONFIG_DATA]
+   --policy-namespaces value, --namespaces value  Rego namespaces (default: "users") [$TRIVY_POLICY_NAMESPACES]
+   --help, -h                                     show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/sbom/index.html b/v0.25.4/docs/references/cli/sbom/index.html new file mode 100644 index 0000000000..dc8c34f181 --- /dev/null +++ b/v0.25.4/docs/references/cli/sbom/index.html @@ -0,0 +1,3051 @@ + + + + + + + + + + + + + + + + + + + + + + + SBOM - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

SBOM

+
NAME:
+   trivy sbom - generate SBOM for an artifact
+
+USAGE:
+   trivy sbom [command options] ARTIFACT
+
+OPTIONS:
+   --output value, -o value             output file name [$TRIVY_OUTPUT]
+   --clear-cache, -c                    clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]
+   --ignorefile value                   specify .trivyignore file (default: ".trivyignore") [$TRIVY_IGNOREFILE]
+   --timeout value                      timeout (default: 5m0s) [$TRIVY_TIMEOUT]
+   --severity value, -s value           severities of vulnerabilities to be displayed (comma separated) (default: "UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL") [$TRIVY_SEVERITY]
+   --artifact-type value, --type value  input artifact type (image, fs, repo, archive) (default: "image") [$TRIVY_ARTIFACT_TYPE]
+   --sbom-format value, --format value  SBOM format (cyclonedx) (default: "cyclonedx") [$TRIVY_SBOM_FORMAT]
+   --help, -h                           show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/cli/server/index.html b/v0.25.4/docs/references/cli/server/index.html new file mode 100644 index 0000000000..f2c2fcd3d8 --- /dev/null +++ b/v0.25.4/docs/references/cli/server/index.html @@ -0,0 +1,3051 @@ + + + + + + + + + + + + + + + + + + + + + + + Server - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Server

+
NAME:
+   trivy server - server mode
+
+USAGE:
+   trivy server [command options] [arguments...]
+
+OPTIONS:
+   --skip-update          skip db update (default: false) [$TRIVY_SKIP_UPDATE]
+   --download-db-only     download/update vulnerability database but don't run a scan (default: false) [$TRIVY_DOWNLOAD_DB_ONLY]
+   --reset                remove all caches and database (default: false) [$TRIVY_RESET]
+   --cache-backend value  cache backend (e.g. redis://localhost:6379) (default: "fs") [$TRIVY_CACHE_BACKEND]
+   --token value          for authentication [$TRIVY_TOKEN]
+   --token-header value   specify a header name for token (default: "Trivy-Token") [$TRIVY_TOKEN_HEADER]
+   --listen value         listen address (default: "localhost:4954") [$TRIVY_LISTEN]
+   --help, -h             show help (default: false)
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/modes/client-server/index.html b/v0.25.4/docs/references/modes/client-server/index.html new file mode 100644 index 0000000000..3c4cb29f1d --- /dev/null +++ b/v0.25.4/docs/references/modes/client-server/index.html @@ -0,0 +1,3185 @@ + + + + + + + + + + + + + + + + + + + + + + + Client/Server - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Client/Server

+

Trivy has client/server mode. Trivy server has vulnerability database and Trivy client doesn't have to download vulnerability database. It is useful if you want to scan images at multiple locations and do not want to download the database at every location.

+

Server

+

At first, you need to launch Trivy server. It downloads vulnerability database automatically and continue to fetch the latest DB in the background. +

$ trivy server --listen localhost:8080
+2019-12-12T15:17:06.551+0200    INFO    Need to update DB
+2019-12-12T15:17:56.706+0200    INFO    Reopening DB...
+2019-12-12T15:17:56.707+0200    INFO    Listening localhost:8080...
+

+

If you want to accept a connection from outside, you have to specify 0.0.0.0 or your ip address, not localhost.

+
$ trivy server --listen 0.0.0.0:8080
+
+

Client

+

Then, specify the remote address. +

$ trivy client --remote http://localhost:8080 alpine:3.10
+

+
+Result + +
alpine:3.10 (alpine 3.10.2)
+===========================
+Total: 3 (UNKNOWN: 0, LOW: 1, MEDIUM: 2, HIGH: 0, CRITICAL: 0)
+
++---------+------------------+----------+-------------------+---------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |
++---------+------------------+----------+-------------------+---------------+
+| openssl | CVE-2019-1549    | MEDIUM   | 1.1.1c-r0         | 1.1.1d-r0     |
++         +------------------+          +                   +               +
+|         | CVE-2019-1563    |          |                   |               |
++         +------------------+----------+                   +               +
+|         | CVE-2019-1547    | LOW      |                   |               |
++---------+------------------+----------+-------------------+---------------+
+
+
+ +

Authentication

+
$ trivy server --listen localhost:8080 --token dummy
+
+
$ trivy client --remote http://localhost:8080 --token dummy alpine:3.10
+
+

Architecture

+

architecture

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/modes/standalone/index.html b/v0.25.4/docs/references/modes/standalone/index.html new file mode 100644 index 0000000000..720c864058 --- /dev/null +++ b/v0.25.4/docs/references/modes/standalone/index.html @@ -0,0 +1,3133 @@ + + + + + + + + + + + + + + + + + + + + + + + Standalone - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Standalone

+

trivy image, trivy filesystem, and trivy repo works as standalone mode.

+

Image

+

standalone

+

Filesystem

+

fs

+

Git Repository

+

repo

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/references/troubleshooting/index.html b/v0.25.4/docs/references/troubleshooting/index.html new file mode 100644 index 0000000000..bd111b3a2e --- /dev/null +++ b/v0.25.4/docs/references/troubleshooting/index.html @@ -0,0 +1,3463 @@ + + + + + + + + + + + + + + + + + + + + + + + Troubleshooting - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + + + + +
+
+ + + + +

Troubleshooting

+

Scan

+

Timeout

+
+

Error

+
$ trivy image ...
+...
+analyze error: timeout: context deadline exceeded
+
+
+

Your scan may time out. Java takes a particularly long time to scan. Try increasing the value of the ---timeout option such as --timeout 15m.

+

Certification

+
+

Error

+

Error: x509: certificate signed by unknown authority

+
+

TRIVY_INSECURE can be used to allow insecure connections to a container registry when using SSL.

+
$ TRIVY_INSECURE=true trivy image [YOUR_IMAGE]
+
+

GitHub Rate limiting

+
+

Error

+
$ trivy image ...
+...
+API rate limit exceeded for xxx.xxx.xxx.xxx.
+
+
+

Specify GITHUB_TOKEN for authentication +https://developer.github.com/v3/#rate-limiting

+
$ GITHUB_TOKEN=XXXXXXXXXX trivy alpine:3.10
+
+

Maven rate limiting / inconsistent jar vulnerability reporting

+
+

Error

+
$ trivy image ...
+...
+status 403 Forbidden from http://search.maven.org/solrsearch/select
+
+
+

Trivy calls Maven API for better detection of JAR files, but many requests may exceed rate limiting. +This can easily happen if you are running more than one instance of Trivy which is concurrently scanning multiple images. +Once this starts happening Trivy's vulnerability reporting on jar files may become inconsistent. +There are two options to resolve this issue:

+

The first is to enable offline scanning using the --offline-scan option to stop Trivy from making API requests. +This option affects only vulnerability scanning. The vulnerability database and builtin policies are downloaded as usual. +If you want to skip them as well, you can try --skip-update and --skip-policy-update. +Note that a number of vulnerabilities might be fewer than without the --offline-scan option.

+

The second, more scalable, option is the place Trivy behind a rate-limiting forward-proxy to the Maven Central API. +One way to achieve this is to use nginx. You can use the following nginx config to enable both rate-limiting and caching (the caching greatly reduces the number of calls to the Maven Central API, especially if you are scanning a lot of similar images):

+
limit_req_zone global zone=maven:1m rate=10r/s;
+proxy_cache_path /tmp/cache keys_zone=mavencache:10m;
+
+server {
+  listen 80;
+  proxy_cache mavencache;
+
+  location / {
+    limit_req zone=maven burst=1000;
+    proxy_cache_valid any 1h;
+    proxy_pass https://search.maven.org:443;
+  }
+}
+
+

This config file will allow a maximum of 10 requests per second to the Maven API, this number was determined experimentally so you might want to use something else if it doesn't fit your needs.

+

Once nginx is up and running, you need to tell all your Trivy deployments to proxy their Maven API calls through nginx. You can do this by setting the MAVEN_CENTRAL_URL environment variable. For example, if your nginx proxy is running at 127.0.0.1, you can set MAVEN_CENTRAL_URL=http://127.0.0.1/solrsearch/select.

+

Running in parallel takes same time as series run

+

When running trivy on multiple images simultaneously, it will take same time as running trivy in series. +This is because of a limitation of boltdb.

+
+

Bolt obtains a file lock on the data file so multiple processes cannot open the same database at the same time. Opening an already open Bolt database will cause it to hang until the other process closes it.

+
+

Reference : boltdb: Opening a database.

+

Error downloading vulnerability DB

+
+

Error

+

FATAL failed to download vulnerability DB

+
+

If trivy is running behind corporate firewall, you have to add the following urls to your allowlist.

+
    +
  • ghcr.io
  • +
  • pkg-containers.githubusercontent.com
  • +
+

Old DB schema

+
+

Error

+

--skip-update cannot be specified with the old DB schema.

+
+

Trivy v0.23.0 or later requires Trivy DB v2. Please update your local database or follow [the instruction of air-gapped environment][../advanced/air-gap.md].

+

Homebrew

+

Scope error

+
+

Error

+

Error: Your macOS keychain GitHub credentials do not have sufficient scope!

+
+
$ brew tap aquasecurity/trivy
+Error: Your macOS keychain GitHub credentials do not have sufficient scope!
+Scopes they need: none
+Scopes they have:
+Create a personal access token:
+https://github.com/settings/tokens/new?scopes=gist,public_repo&description=Homebrew
+echo 'export HOMEBREW_GITHUB_API_TOKEN=your_token_here' >> ~/.zshrc
+
+

Try:

+
$ printf "protocol=https\nhost=github.com\n" | git credential-osxkeychain erase
+
+

Already installed

+
+

Error

+

Error: aquasecurity/trivy/trivy 64 already installed

+
+
$ brew upgrade
+...
+Error: aquasecurity/trivy/trivy 64 already installed
+
+

Try:

+
$ brew unlink trivy && brew uninstall trivy
+($ rm -rf /usr/local/Cellar/trivy/64)
+$ brew install aquasecurity/trivy/trivy
+
+

Others

+

Unknown error

+

Try again with --reset option:

+
$ trivy image --reset
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/sbom/cyclonedx/index.html b/v0.25.4/docs/sbom/cyclonedx/index.html new file mode 100644 index 0000000000..af344a50c4 --- /dev/null +++ b/v0.25.4/docs/sbom/cyclonedx/index.html @@ -0,0 +1,3256 @@ + + + + + + + + + + + + + + + + + + + + + + + CycloneDX - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

CycloneDX

+

Trivy generates JSON reports in the CycloneDX format. +Note that XML format is not supported at the moment.

+

You can use the regular subcommands (like image, fs and rootfs) and specify cyclonedx with the --format option.

+
$ trivy image --format cyclonedx --output result.json alpine:3.15
+
+
+Result + +
$ cat result.json | jq .
+{
+  "bomFormat": "CycloneDX",
+  "specVersion": "1.4",
+  "serialNumber": "urn:uuid:2be5773d-7cd3-4b4b-90a5-e165474ddace",
+  "version": 1,
+  "metadata": {
+    "timestamp": "2022-02-22T15:11:40.270597Z",
+    "tools": [
+      {
+        "vendor": "aquasecurity",
+        "name": "trivy",
+        "version": "dev"
+      }
+    ],
+    "component": {
+      "bom-ref": "pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64",
+      "type": "container",
+      "name": "alpine:3.15",
+      "version": "",
+      "purl": "pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:SchemaVersion",
+          "value": "2"
+        },
+        {
+          "name": "aquasecurity:trivy:ImageID",
+          "value": "sha256:c059bfaa849c4d8e4aecaeb3a10c2d9b3d85f5165c66ad3a4d937758128c4d18"
+        },
+        {
+          "name": "aquasecurity:trivy:RepoDigest",
+          "value": "alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300"
+        },
+        {
+          "name": "aquasecurity:trivy:DiffID",
+          "value": "sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759"
+        },
+        {
+          "name": "aquasecurity:trivy:RepoTag",
+          "value": "alpine:3.15"
+        }
+      ]
+    }
+  },
+  "components": [
+    {
+      "bom-ref": "pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0",
+      "type": "library",
+      "name": "alpine-baselayout",
+      "version": "3.2.0-r18",
+      "licenses": [
+        {
+          "expression": "GPL-2.0-only"
+        }
+      ],
+      "purl": "pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:SrcName",
+          "value": "alpine-baselayout"
+        },
+        {
+          "name": "aquasecurity:trivy:SrcVersion",
+          "value": "3.2.0-r18"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDigest",
+          "value": "sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDiffID",
+          "value": "sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759"
+        }
+      ]
+    },
+    ...(snip)...
+    {
+      "bom-ref": "pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0",
+      "type": "library",
+      "name": "zlib",
+      "version": "1.2.11-r3",
+      "licenses": [
+        {
+          "expression": "Zlib"
+        }
+      ],
+      "purl": "pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:SrcName",
+          "value": "zlib"
+        },
+        {
+          "name": "aquasecurity:trivy:SrcVersion",
+          "value": "1.2.11-r3"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDigest",
+          "value": "sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDiffID",
+          "value": "sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759"
+        }
+      ]
+    },
+    {
+      "bom-ref": "3da6a469-964d-4b4e-b67d-e94ec7c88d37",
+      "type": "operating-system",
+      "name": "alpine",
+      "version": "3.15.0",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:Type",
+          "value": "alpine"
+        },
+        {
+          "name": "aquasecurity:trivy:Class",
+          "value": "os-pkgs"
+        }
+      ]
+    }
+  ],
+  "dependencies": [
+    {
+      "ref": "3da6a469-964d-4b4e-b67d-e94ec7c88d37",
+      "dependsOn": [
+        "pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0",
+        "pkg:apk/alpine/alpine-keys@2.4-r1?distro=3.15.0",
+        "pkg:apk/alpine/apk-tools@2.12.7-r3?distro=3.15.0",
+        "pkg:apk/alpine/busybox@1.34.1-r3?distro=3.15.0",
+        "pkg:apk/alpine/ca-certificates-bundle@20191127-r7?distro=3.15.0",
+        "pkg:apk/alpine/libc-utils@0.7.2-r3?distro=3.15.0",
+        "pkg:apk/alpine/libcrypto1.1@1.1.1l-r7?distro=3.15.0",
+        "pkg:apk/alpine/libretls@3.3.4-r2?distro=3.15.0",
+        "pkg:apk/alpine/libssl1.1@1.1.1l-r7?distro=3.15.0",
+        "pkg:apk/alpine/musl@1.2.2-r7?distro=3.15.0",
+        "pkg:apk/alpine/musl-utils@1.2.2-r7?distro=3.15.0",
+        "pkg:apk/alpine/scanelf@1.3.3-r0?distro=3.15.0",
+        "pkg:apk/alpine/ssl_client@1.34.1-r3?distro=3.15.0",
+        "pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0"
+      ]
+    },
+    {
+      "ref": "pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64",
+      "dependsOn": [
+        "3da6a469-964d-4b4e-b67d-e94ec7c88d37"
+      ]
+    }
+  ],
+  "vulnerabilities": [
+    {
+      "id": "CVE-2021-42386",
+      "source": {
+        "name": "alpine",
+        "url": "https://secdb.alpinelinux.org/"
+      },
+      "ratings": [
+        {
+          "source": {
+            "name": "nvd"
+          },
+          "score": 7.2,
+          "severity": "high",
+          "method": "CVSSv31",
+          "vector": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H"
+        },
+        {
+          "source": {
+            "name": "nvd"
+          },
+          "score": 6.5,
+          "severity": "medium",
+          "method": "CVSSv2",
+          "vector": "AV:N/AC:L/Au:S/C:P/I:P/A:P"
+        },
+        {
+          "source": {
+            "name": "redhat"
+          },
+          "score": 6.6,
+          "severity": "medium",
+          "method": "CVSSv31",
+          "vector": "CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:H"
+        }
+      ],
+      "cwes": [
+        416
+      ],
+      "description": "A use-after-free in Busybox's awk applet leads to denial of service and possibly code execution when processing a crafted awk pattern in the nvalloc function",
+      "advisories": [
+        {
+          "url": "https://access.redhat.com/security/cve/CVE-2021-42386"
+        },
+        {
+          "url": "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-42386"
+        }
+      ],
+      "published": "2021-11-15 21:15:00 +0000 UTC",
+      "updated": "2022-01-04 17:14:00 +0000 UTC",
+      "affects": [
+        {
+          "ref": "pkg:apk/alpine/busybox@1.33.1-r3?distro=3.14.2"
+        },
+        {
+          "ref": "pkg:apk/alpine/ssl_client@1.33.1-r3?distro=3.14.2"
+        }
+      ]
+    }
+  ]
+}
+
+ +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/sbom/index.html b/v0.25.4/docs/sbom/index.html new file mode 100644 index 0000000000..71dc085d6f --- /dev/null +++ b/v0.25.4/docs/sbom/index.html @@ -0,0 +1,3211 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

SBOM

+

Trivy currently supports the following SBOM formats.

+ +

To generate SBOM, you can use the --format option for each subcommand such as image and fs.

+
$ trivy image --format cyclonedx --output result.json alpine:3.15
+
+

In addition, you can use the trivy sbom subcommand.

+
$ trivy sbom alpine:3.15
+
+
+Result + +
{
+  "bomFormat": "CycloneDX",
+  "specVersion": "1.3",
+  "serialNumber": "urn:uuid:2be5773d-7cd3-4b4b-90a5-e165474ddace",
+  "version": 1,
+  "metadata": {
+    "timestamp": "2022-02-22T15:11:40.270597Z",
+    "tools": [
+      {
+        "vendor": "aquasecurity",
+        "name": "trivy",
+        "version": "dev"
+      }
+    ],
+    "component": {
+      "bom-ref": "pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64",
+      "type": "container",
+      "name": "alpine:3.15",
+      "version": "",
+      "purl": "pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:SchemaVersion",
+          "value": "2"
+        },
+        {
+          "name": "aquasecurity:trivy:ImageID",
+          "value": "sha256:c059bfaa849c4d8e4aecaeb3a10c2d9b3d85f5165c66ad3a4d937758128c4d18"
+        },
+        {
+          "name": "aquasecurity:trivy:RepoDigest",
+          "value": "alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300"
+        },
+        {
+          "name": "aquasecurity:trivy:DiffID",
+          "value": "sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759"
+        },
+        {
+          "name": "aquasecurity:trivy:RepoTag",
+          "value": "alpine:3.15"
+        }
+      ]
+    }
+  },
+  "components": [
+    {
+      "bom-ref": "pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0",
+      "type": "library",
+      "name": "alpine-baselayout",
+      "version": "3.2.0-r18",
+      "licenses": [
+        {
+          "expression": "GPL-2.0-only"
+        }
+      ],
+      "purl": "pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:SrcName",
+          "value": "alpine-baselayout"
+        },
+        {
+          "name": "aquasecurity:trivy:SrcVersion",
+          "value": "3.2.0-r18"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDigest",
+          "value": "sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDiffID",
+          "value": "sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759"
+        }
+      ]
+    },
+    ...(snip)...
+    {
+      "bom-ref": "pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0",
+      "type": "library",
+      "name": "zlib",
+      "version": "1.2.11-r3",
+      "licenses": [
+        {
+          "expression": "Zlib"
+        }
+      ],
+      "purl": "pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:SrcName",
+          "value": "zlib"
+        },
+        {
+          "name": "aquasecurity:trivy:SrcVersion",
+          "value": "1.2.11-r3"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDigest",
+          "value": "sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3"
+        },
+        {
+          "name": "aquasecurity:trivy:LayerDiffID",
+          "value": "sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759"
+        }
+      ]
+    },
+    {
+      "bom-ref": "3da6a469-964d-4b4e-b67d-e94ec7c88d37",
+      "type": "operating-system",
+      "name": "alpine",
+      "version": "3.15.0",
+      "properties": [
+        {
+          "name": "aquasecurity:trivy:Type",
+          "value": "alpine"
+        },
+        {
+          "name": "aquasecurity:trivy:Class",
+          "value": "os-pkgs"
+        }
+      ]
+    }
+  ],
+  "dependencies": [
+    {
+      "ref": "3da6a469-964d-4b4e-b67d-e94ec7c88d37",
+      "dependsOn": [
+        "pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0",
+        "pkg:apk/alpine/alpine-keys@2.4-r1?distro=3.15.0",
+        "pkg:apk/alpine/apk-tools@2.12.7-r3?distro=3.15.0",
+        "pkg:apk/alpine/busybox@1.34.1-r3?distro=3.15.0",
+        "pkg:apk/alpine/ca-certificates-bundle@20191127-r7?distro=3.15.0",
+        "pkg:apk/alpine/libc-utils@0.7.2-r3?distro=3.15.0",
+        "pkg:apk/alpine/libcrypto1.1@1.1.1l-r7?distro=3.15.0",
+        "pkg:apk/alpine/libretls@3.3.4-r2?distro=3.15.0",
+        "pkg:apk/alpine/libssl1.1@1.1.1l-r7?distro=3.15.0",
+        "pkg:apk/alpine/musl@1.2.2-r7?distro=3.15.0",
+        "pkg:apk/alpine/musl-utils@1.2.2-r7?distro=3.15.0",
+        "pkg:apk/alpine/scanelf@1.3.3-r0?distro=3.15.0",
+        "pkg:apk/alpine/ssl_client@1.34.1-r3?distro=3.15.0",
+        "pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0"
+      ]
+    },
+    {
+      "ref": "pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64",
+      "dependsOn": [
+        "3da6a469-964d-4b4e-b67d-e94ec7c88d37"
+      ]
+    }
+  ]
+}
+
+ +
+ +

fs, repo and archive also work with sbom subcommand.

+
# filesystem
+$ trivy sbom --artifact-type fs /path/to/project
+
+# repository
+$ trivy sbom --artifact-type repo github.com/aquasecurity/trivy-ci-test
+
+# container image archive
+$ trivy sbom --artifact-type archive alpine.tar
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/detection/data-source/index.html b/v0.25.4/docs/vulnerability/detection/data-source/index.html new file mode 100644 index 0000000000..09c672b8b6 --- /dev/null +++ b/v0.25.4/docs/vulnerability/detection/data-source/index.html @@ -0,0 +1,3225 @@ + + + + + + + + + + + + + + + + + + + + + + + Data Sources - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

OS

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
OSSource
Arch LinuxVulnerable Issues
Alpine Linuxsecdb
Amazon Linux 1Amazon Linux Security Center
Amazon Linux 2Amazon Linux Security Center
DebianSecurity Bug Tracker
OVAL
UbuntuUbuntu CVE Tracker
RHEL/CentOSOVAL
Security Data
AlmaLinuxAlmaLinux Product Errata
Rocky LinuxRocky Linux UpdateInfo
Oracle LinuxOVAL
CBL-MarinerOVAL
OpenSUSE/SLESCVRF
Photon OSPhoton Security Advisory
+

Programming Language

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
LanguageSourceCommercial UseDelay1
PHPPHP Security Advisories Database-
GitHub Advisory Database (Composer)-
PythonGitHub Advisory Database (pip)-
Open Source Vulnerabilities (PyPI)-
RubyRuby Advisory Database-
GitHub Advisory Database (RubyGems)-
Node.jsEcosystem Security Working Group-
GitHub Advisory Database (npm)-
JavaGitLab Advisories Community1 month
GitHub Advisory Database (Maven)-
GoGitLab Advisories Community1 month
The Go Vulnerability Database-
RustOpen Source Vulnerabilities (crates.io)-
.NETGitHub Advisory Database (NuGet)-
+

Others

+ + + + + + + + + + + + + +
NameSource
National Vulnerability DatabaseNVD
+
+
+
    +
  1. +

    Intentional delay between vulnerability disclosure and registration in the DB 

    +
  2. +
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/detection/language/index.html b/v0.25.4/docs/vulnerability/detection/language/index.html new file mode 100644 index 0000000000..d6c92e2f55 --- /dev/null +++ b/v0.25.4/docs/vulnerability/detection/language/index.html @@ -0,0 +1,3250 @@ + + + + + + + + + + + + + + + + + + + + + + + Language-specific Packages - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Language-specific Packages

+

Trivy automatically detects the following files in the container and scans vulnerabilities in the application dependencies.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
LanguageFileImage7Rootfs8Filesystem9Repository10Dev dependencies
RubyGemfile.lock--included
gemspec--included
PythonPipfile.lock--excluded
poetry.lock--included
requirements.txt--included
egg package1--excluded
wheel package2--excluded
PHPcomposer.lockexcluded
Node.jspackage-lock.json--excluded
yarn.lock--included
package.json--excluded
.NETpackages.lock.jsonincluded
packages.configexcluded
JavaJAR/WAR/PAR/EAR34--included
pom.xml5--excluded
GoBinaries built by Go6--excluded
go.sum--included
RustCargo.lockincluded
+

The path of these files does not matter.

+

Example: Dockerfile

+
+
+
    +
  1. +

    *.egg-info, *.egg-info/PKG-INFO, *.egg and EGG-INFO/PKG-INFO 

    +
  2. +
  3. +

    .dist-info/META-DATA 

    +
  4. +
  5. +

    *.jar, *.war, *.par and *.ear 

    +
  6. +
  7. +

    It requires Internet access 

    +
  8. +
  9. +

    It requires Internet access when the POM doesn't exist in your local repository 

    +
  10. +
  11. +

    UPX-compressed binaries don't work 

    +
  12. +
  13. +

    ✅ means "enabled" and - means "disabled" in the image scanning 

    +
  14. +
  15. +

    ✅ means "enabled" and - means "disabled" in the rootfs scanning 

    +
  16. +
  17. +

    ✅ means "enabled" and - means "disabled" in the filesystem scanning 

    +
  18. +
  19. +

    ✅ means "enabled" and - means "disabled" in the git repository scanning 

    +
  20. +
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/detection/os/index.html b/v0.25.4/docs/vulnerability/detection/os/index.html new file mode 100644 index 0000000000..45661d037b --- /dev/null +++ b/v0.25.4/docs/vulnerability/detection/os/index.html @@ -0,0 +1,3149 @@ + + + + + + + + + + + + + + + + + + + + + + + OS Packages - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Supported OS

+

The unfixed/unfixable vulnerabilities mean that the patch has not yet been provided on their distribution. Trivy doesn't support self-compiled packages/binaries, but official packages provided by vendors such as Red Hat and Debian.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
OSSupported VersionsTarget PackagesDetection of unfixed vulnerabilities
Alpine Linux2.2 - 2.7, 3.0 - 3.15Installed by apkNO
Red Hat Universal Base Image17, 8Installed by yum/rpmYES
Red Hat Enterprise Linux6, 7, 8Installed by yum/rpmYES
CentOS6, 7, 8Installed by yum/rpmYES
AlmaLinux8Installed by yum/rpmNO
Rocky Linux8Installed by yum/rpmNO
Oracle Linux5, 6, 7, 8Installed by yum/rpmNO
CBL-Mariner1.0, 2.0Installed by yum/rpmYES
Amazon Linux1, 2Installed by yum/rpmNO
openSUSE Leap42, 15Installed by zypper/rpmNO
SUSE Enterprise Linux11, 12, 15Installed by zypper/rpmNO
Photon OS1.0, 2.0, 3.0, 4.0Installed by tdnf/yum/rpmNO
Debian GNU/Linuxwheezy, jessie, stretch, buster, bullseyeInstalled by apt/apt-get/dpkgYES
UbuntuAll versions supported by CanonicalInstalled by apt/apt-get/dpkgYES
Distroless2AnyInstalled by apt/apt-get/dpkgYES
+
+
+
    +
  1. +

    https://developers.redhat.com/products/rhel/ubi 

    +
  2. +
  3. +

    https://github.com/GoogleContainerTools/distroless 

    +
  4. +
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/detection/supported/index.html b/v0.25.4/docs/vulnerability/detection/supported/index.html new file mode 100644 index 0000000000..cb57ab3158 --- /dev/null +++ b/v0.25.4/docs/vulnerability/detection/supported/index.html @@ -0,0 +1,3170 @@ + + + + + + + + + + + + + + + + + + + + + + + Supported - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+ + +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/examples/cache/index.html b/v0.25.4/docs/vulnerability/examples/cache/index.html new file mode 100644 index 0000000000..cbc8469e7d --- /dev/null +++ b/v0.25.4/docs/vulnerability/examples/cache/index.html @@ -0,0 +1,3164 @@ + + + + + + + + + + + + + + + + + + + + + + + Cache - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Cache

+

Clear Caches

+

The --clear-cache option removes caches.

+

The scan is not performed.

+
$ trivy image --clear-cache
+
+
+Result + +
2019-11-15T15:13:26.209+0200    INFO    Reopening vulnerability DB
+2019-11-15T15:13:26.209+0200    INFO    Removing image caches...
+
+ +
+ +

Cache Directory

+

Specify where the cache is stored with --cache-dir.

+
$ trivy --cache-dir /tmp/trivy/ image python:3.4-alpine3.9
+
+

Cache Backend

+
+

EXPERIMENTAL

+

This feature might change without preserving backwards compatibility.

+
+

Trivy supports local filesystem and Redis as the cache backend. This option is useful especially for client/server mode.

+

Two options: +- fs + - the cache path can be specified by --cache-dir +- redis:// + - redis://[HOST]:[PORT]

+
$ trivy server --cache-backend redis://localhost:6379
+
+

Trivy also support for connecting to Redis using TLS, you only need to specify --redis-ca , --redis-cert , and --redis-key option.

+
$ trivy server --cache-backend redis://localhost:6379 \
+  --redis-ca /path/to/ca-cert.pem \
+  --redis-cert /path/to/cert.pem \
+  --redis-key /path/to/key.pem
+
+

TLS option for redis is hidden from Trivy command-line flag, but you still can use it.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/examples/db/index.html b/v0.25.4/docs/vulnerability/examples/db/index.html new file mode 100644 index 0000000000..810b13e83e --- /dev/null +++ b/v0.25.4/docs/vulnerability/examples/db/index.html @@ -0,0 +1,3160 @@ + + + + + + + + + + + + + + + + + + + + + + + Vulnerability DB - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Vulnerability DB

+

Skip update of vulnerability DB

+

Trivy downloads its vulnerability database every 12 hours when it starts operating. +This is usually fast, as the size of the DB is only 10~30MB. +But if you want to skip even that, use the --skip-db-update option.

+
$ trivy image --skip-db-update python:3.4-alpine3.9
+
+
+Result + +
2019-05-16T12:48:08.703+0900    INFO    Detecting Alpine vulnerabilities...
+
+python:3.4-alpine3.9 (alpine 3.9.2)
+===================================
+Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)
+
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |
+|         |                  |          |                   |               | with long nonces               |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+
+ +
+ +

Only download vulnerability database

+

You can also ask Trivy to simply retrieve the vulnerability database. +This is useful to initialize workers in Continuous Integration systems.

+
$ trivy image --download-db-only
+
+

DB Repository

+

Trivy could also download the vulnerability database from an external OCI registry by using --db-repository option.

+
$ trivy image --db-repository registry.gitlab.com/gitlab-org/security-products/dependencies/trivy-db
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/examples/filter/index.html b/v0.25.4/docs/vulnerability/examples/filter/index.html new file mode 100644 index 0000000000..e3c682413f --- /dev/null +++ b/v0.25.4/docs/vulnerability/examples/filter/index.html @@ -0,0 +1,3485 @@ + + + + + + + + + + + + + + + + + + + + + + + Vulnerability Filtering - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Filter Vulnerabilities

+

Hide Unfixed Vulnerabilities

+

By default, Trivy also detects unpatched/unfixed vulnerabilities. This means you can't fix these vulnerabilities even if you update all packages. +If you would like to ignore them, use the --ignore-unfixed option.

+
$ trivy image --ignore-unfixed ruby:2.4.0
+
+
+Result + +
2019-05-16T12:49:52.656+0900    INFO    Updating vulnerability database...
+2019-05-16T12:50:14.786+0900    INFO    Detecting Debian vulnerabilities...
+
+ruby:2.4.0 (debian 8.7)
+=======================
+Total: 4730 (UNKNOWN: 1, LOW: 145, MEDIUM: 3487, HIGH: 1014, CRITICAL: 83)
+
++------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+
+|           LIBRARY            | VULNERABILITY ID | SEVERITY |     INSTALLED VERSION      |          FIXED VERSION           |                        TITLE                        |
++------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+
+| apt                          | CVE-2019-3462    | CRITICAL | 1.0.9.8.3                  | 1.0.9.8.5                        | Incorrect sanitation of the                         |
+|                              |                  |          |                            |                                  | 302 redirect field in HTTP                          |
+|                              |                  |          |                            |                                  | transport method of...                              |
++                              +------------------+----------+                            +----------------------------------+-----------------------------------------------------+
+|                              | CVE-2016-1252    | MEDIUM   |                            | 1.0.9.8.4                        | The apt package in Debian                           |
+|                              |                  |          |                            |                                  | jessie before 1.0.9.8.4, in                         |
+|                              |                  |          |                            |                                  | Debian unstable before...                           |
++------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+
+| bash                         | CVE-2019-9924    | HIGH     | 4.3-11                     | 4.3-11+deb8u2                    | bash: BASH_CMD is writable in                       |
+|                              |                  |          |                            |                                  | restricted bash shells                              |
++                              +------------------+          +                            +----------------------------------+-----------------------------------------------------+
+|                              | CVE-2016-7543    |          |                            | 4.3-11+deb8u1                    | bash: Specially crafted                             |
+|                              |                  |          |                            |                                  | SHELLOPTS+PS4 variables allows                      |
+|                              |                  |          |                            |                                  | command substitution                                |
++                              +------------------+----------+                            +                                  +-----------------------------------------------------+
+|                              | CVE-2016-0634    | MEDIUM   |                            |                                  | bash: Arbitrary code execution                      |
+|                              |                  |          |                            |                                  | via malicious hostname                              |
++                              +------------------+----------+                            +----------------------------------+-----------------------------------------------------+
+|                              | CVE-2016-9401    | LOW      |                            | 4.3-11+deb8u2                    | bash: popd controlled free                          |
++------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+
+...
+
+ +
+ +

By Severity

+

Use --severity option.

+
$ trivy image --severity HIGH,CRITICAL ruby:2.4.0
+
+
+Result + +
2019-05-16T01:51:46.255+0900    INFO    Updating vulnerability database...
+2019-05-16T01:51:49.213+0900    INFO    Detecting Debian vulnerabilities...
+
+ruby:2.4.0 (debian 8.7)
+=======================
+Total: 1785 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1680, CRITICAL: 105)
+
++-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+
+|           LIBRARY           | VULNERABILITY ID | SEVERITY |     INSTALLED VERSION     |          FIXED VERSION           |                      TITLE                      |
++-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+
+| apt                         | CVE-2019-3462    | CRITICAL | 1.0.9.8.3                 | 1.0.9.8.5                        | Incorrect sanitation of the                     |
+|                             |                  |          |                           |                                  | 302 redirect field in HTTP                      |
+|                             |                  |          |                           |                                  | transport method of...                          |
++-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+
+| bash                        | CVE-2019-9924    | HIGH     | 4.3-11                    | 4.3-11+deb8u2                    | bash: BASH_CMD is writable in                   |
+|                             |                  |          |                           |                                  | restricted bash shells                          |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2016-7543    |          |                           | 4.3-11+deb8u1                    | bash: Specially crafted                         |
+|                             |                  |          |                           |                                  | SHELLOPTS+PS4 variables allows                  |
+|                             |                  |          |                           |                                  | command substitution                            |
++-----------------------------+------------------+          +---------------------------+----------------------------------+-------------------------------------------------+
+| binutils                    | CVE-2017-8421    |          | 2.25-5                    |                                  | binutils: Memory exhaustion in                  |
+|                             |                  |          |                           |                                  | objdump via a crafted PE file                   |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2017-14930   |          |                           |                                  | binutils: Memory leak in                        |
+|                             |                  |          |                           |                                  | decode_line_info                                |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2017-7614    |          |                           |                                  | binutils: NULL                                  |
+|                             |                  |          |                           |                                  | pointer dereference in                          |
+|                             |                  |          |                           |                                  | bfd_elf_final_link function                     |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2014-9939    |          |                           |                                  | binutils: buffer overflow in                    |
+|                             |                  |          |                           |                                  | ihex.c                                          |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2017-13716   |          |                           |                                  | binutils: Memory leak with the                  |
+|                             |                  |          |                           |                                  | C++ symbol demangler routine                    |
+|                             |                  |          |                           |                                  | in libiberty                                    |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2018-12699   |          |                           |                                  | binutils: heap-based buffer                     |
+|                             |                  |          |                           |                                  | overflow in finish_stab in                      |
+|                             |                  |          |                           |                                  | stabs.c                                         |
++-----------------------------+------------------+          +---------------------------+----------------------------------+-------------------------------------------------+
+| bsdutils                    | CVE-2015-5224    |          | 2.25.2-6                  |                                  | util-linux: File name                           |
+|                             |                  |          |                           |                                  | collision due to incorrect                      |
+|                             |                  |          |                           |                                  | mkstemp use                                     |
++                             +------------------+          +                           +----------------------------------+-------------------------------------------------+
+|                             | CVE-2016-2779    |          |                           |                                  | util-linux: runuser tty hijack                  |
+|                             |                  |          |                           |                                  | via TIOCSTI ioctl                               |
++-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+
+
+ +
+ +

By Vulnerability IDs

+

Use .trivyignore.

+
$ cat .trivyignore
+# Accept the risk
+CVE-2018-14618
+
+# No impact in our settings
+CVE-2019-1543
+
+$ trivy image python:3.4-alpine3.9
+
+
+Result + +
2019-05-16T12:53:10.076+0900    INFO    Updating vulnerability database...
+2019-05-16T12:53:28.134+0900    INFO    Detecting Alpine vulnerabilities...
+
+python:3.4-alpine3.9 (alpine 3.9.2)
+===================================
+Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)
+
+ +
+ +

By Type

+

Use --vuln-type option.

+
$ trivy image --vuln-type os ruby:2.4.0
+
+

Available values: +- library +- os

+
+Result + +
2019-05-22T19:36:50.530+0200    INFO    Updating vulnerability database...
+2019-05-22T19:36:51.681+0200    INFO    Detecting Alpine vulnerabilities...
+2019-05-22T19:36:51.685+0200    INFO    Updating npm Security DB...
+2019-05-22T19:36:52.389+0200    INFO    Detecting npm vulnerabilities...
+2019-05-22T19:36:52.390+0200    INFO    Updating pipenv Security DB...
+2019-05-22T19:36:53.406+0200    INFO    Detecting pipenv vulnerabilities...
+
+ruby:2.4.0 (debian 8.7)
+Total: 4751 (UNKNOWN: 1, LOW: 150, MEDIUM: 3504, HIGH: 1013, CRITICAL: 83)
+
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |              TITLE               |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| curl    | CVE-2018-14618   | CRITICAL | 7.61.0-r0         | 7.61.1-r0     | curl: NTLM password overflow     |
+|         |                  |          |                   |               | via integer overflow             |
++         +------------------+----------+                   +---------------+----------------------------------+
+|         | CVE-2018-16839   | HIGH     |                   | 7.61.1-r1     | curl: Integer overflow leading   |
+|         |                  |          |                   |               | to heap-based buffer overflow in |
+|         |                  |          |                   |               | Curl_sasl_create_plain_message() |
++         +------------------+          +                   +---------------+----------------------------------+
+|         | CVE-2019-3822    |          |                   | 7.61.1-r2     | curl: NTLMv2 type-3 header       |
+|         |                  |          |                   |               | stack buffer overflow            |
++         +------------------+          +                   +---------------+----------------------------------+
+|         | CVE-2018-16840   |          |                   | 7.61.1-r1     | curl: Use-after-free when        |
+|         |                  |          |                   |               | closing "easy" handle in         |
+|         |                  |          |                   |               | Curl_close()                     |
++         +------------------+----------+                   +---------------+----------------------------------+
+|         | CVE-2019-3823    | MEDIUM   |                   | 7.61.1-r2     | curl: SMTP end-of-response       |
+|         |                  |          |                   |               | out-of-bounds read               |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2018-16890   |          |                   |               | curl: NTLM type-2 heap           |
+|         |                  |          |                   |               | out-of-bounds buffer read        |
++         +------------------+          +                   +---------------+----------------------------------+
+|         | CVE-2018-16842   |          |                   | 7.61.1-r1     | curl: Heap-based buffer          |
+|         |                  |          |                   |               | over-read in the curl tool       |
+|         |                  |          |                   |               | warning formatting               |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| git     | CVE-2018-17456   | HIGH     | 2.15.2-r0         | 2.15.3-r0     | git: arbitrary code execution    |
+|         |                  |          |                   |               | via .gitmodules                  |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2018-19486   |          |                   |               | git: Improper handling of        |
+|         |                  |          |                   |               | PATH allows for commands to be   |
+|         |                  |          |                   |               | executed from...                 |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| libssh2 | CVE-2019-3855    | CRITICAL | 1.8.0-r2          | 1.8.1-r0      | libssh2: Integer overflow in     |
+|         |                  |          |                   |               | transport read resulting in      |
+|         |                  |          |                   |               | out of bounds write...           |
++         +------------------+----------+                   +               +----------------------------------+
+|         | CVE-2019-3861    | MEDIUM   |                   |               | libssh2: Out-of-bounds reads     |
+|         |                  |          |                   |               | with specially crafted SSH       |
+|         |                  |          |                   |               | packets                          |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3857    |          |                   |               | libssh2: Integer overflow in     |
+|         |                  |          |                   |               | SSH packet processing channel    |
+|         |                  |          |                   |               | resulting in out of...           |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3856    |          |                   |               | libssh2: Integer overflow in     |
+|         |                  |          |                   |               | keyboard interactive handling    |
+|         |                  |          |                   |               | resulting in out of bounds...    |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3863    |          |                   |               | libssh2: Integer overflow        |
+|         |                  |          |                   |               | in user authenticate             |
+|         |                  |          |                   |               | keyboard interactive allows      |
+|         |                  |          |                   |               | out-of-bounds writes             |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3862    |          |                   |               | libssh2: Out-of-bounds memory    |
+|         |                  |          |                   |               | comparison with specially        |
+|         |                  |          |                   |               | crafted message channel          |
+|         |                  |          |                   |               | request                          |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3860    |          |                   |               | libssh2: Out-of-bounds reads     |
+|         |                  |          |                   |               | with specially crafted SFTP      |
+|         |                  |          |                   |               | packets                          |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3858    |          |                   |               | libssh2: Zero-byte allocation    |
+|         |                  |          |                   |               | with a specially crafted SFTP    |
+|         |                  |          |                   |               | packed leading to an...          |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-3859    |          |                   |               | libssh2: Unchecked use of        |
+|         |                  |          |                   |               | _libssh2_packet_require and      |
+|         |                  |          |                   |               | _libssh2_packet_requirev         |
+|         |                  |          |                   |               | resulting in out-of-bounds       |
+|         |                  |          |                   |               | read                             |
++---------+------------------+          +-------------------+---------------+----------------------------------+
+| libxml2 | CVE-2018-14404   |          | 2.9.7-r0          | 2.9.8-r1      | libxml2: NULL pointer            |
+|         |                  |          |                   |               | dereference in                   |
+|         |                  |          |                   |               | xpath.c:xmlXPathCompOpEval()     |
+|         |                  |          |                   |               | can allow attackers to cause     |
+|         |                  |          |                   |               | a...                             |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2018-14567   |          |                   |               | libxml2: Infinite loop when      |
+|         |                  |          |                   |               | --with-lzma is used allows for   |
+|         |                  |          |                   |               | denial of service...             |
++         +------------------+----------+                   +               +----------------------------------+
+|         | CVE-2018-9251    | LOW      |                   |               | libxml2: infinite loop in        |
+|         |                  |          |                   |               | xz_decomp function in xzlib.c    |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| openssh | CVE-2019-6109    | MEDIUM   | 7.5_p1-r9         | 7.5_p1-r10    | openssh: Missing character       |
+|         |                  |          |                   |               | encoding in progress display     |
+|         |                  |          |                   |               | allows for spoofing of scp...    |
++         +------------------+          +                   +               +----------------------------------+
+|         | CVE-2019-6111    |          |                   |               | openssh: Improper validation     |
+|         |                  |          |                   |               | of object names allows           |
+|         |                  |          |                   |               | malicious server to overwrite    |
+|         |                  |          |                   |               | files...                         |
++         +------------------+----------+                   +               +----------------------------------+
+|         | CVE-2018-20685   | LOW      |                   |               | openssh: scp client improper     |
+|         |                  |          |                   |               | directory name validation        |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| sqlite  | CVE-2018-20346   | MEDIUM   | 3.21.0-r1         | 3.25.3-r0     | CVE-2018-20505 CVE-2018-20506    |
+|         |                  |          |                   |               | sqlite: Multiple flaws in        |
+|         |                  |          |                   |               | sqlite which can be triggered    |
+|         |                  |          |                   |               | via...                           |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+| tar     | CVE-2018-20482   | LOW      | 1.29-r1           | 1.31-r0       | tar: Infinite read loop in       |
+|         |                  |          |                   |               | sparse_dump_region function in   |
+|         |                  |          |                   |               | sparse.c                         |
++---------+------------------+----------+-------------------+---------------+----------------------------------+
+
+ +
+ +

By Open Policy Agent

+
+

EXPERIMENTAL

+

This feature might change without preserving backwards compatibility.

+
+

Trivy supports Open Policy Agent (OPA) to filter vulnerabilities. You can specify a Rego file with --ignore-policy option.

+

The Rego package name must be trivy and it must include a rule called ignore which determines if each individual vulnerability should be excluded (ignore=true) or not (ignore=false). In the policy, each vulnerability will be available for inspection as the input variable. The structure of each vulnerability input is the same as for the Trivy JSON output.
+There is a built-in Rego library with helper functions that you can import into your policy using: import data.lib.trivy. For more info about the helper functions, look at the library here

+

To get started, see the example policy.

+
$ trivy image --ignore-policy contrib/example_policy/basic.rego centos:7
+
+
+Result + +
centos:7 (centos 7.9.2009)
+==========================
+Total: 9 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 4, CRITICAL: 5)
+
++--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+
+|   LIBRARY    | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |   FIXED VERSION   |                  TITLE                  |
++--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+
+| glib2        | CVE-2015-8385    | HIGH     | 2.56.1-7.el7      |                   | pcre: buffer overflow caused            |
+|              |                  |          |                   |                   | by named forward reference              |
+|              |                  |          |                   |                   | to duplicate group number...            |
+|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2015-8385    |
++              +------------------+          +                   +-------------------+-----------------------------------------+
+|              | CVE-2016-3191    |          |                   |                   | pcre: workspace overflow for            |
+|              |                  |          |                   |                   | (*ACCEPT) with deeply nested            |
+|              |                  |          |                   |                   | parentheses (8.39/13, 10.22/12)         |
+|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2016-3191    |
++              +------------------+          +                   +-------------------+-----------------------------------------+
+|              | CVE-2021-27219   |          |                   | 2.56.1-9.el7_9    | glib: integer overflow in               |
+|              |                  |          |                   |                   | g_bytes_new function on                 |
+|              |                  |          |                   |                   | 64-bit platforms due to an...           |
+|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2021-27219   |
++--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+
+| glibc        | CVE-2019-1010022 | CRITICAL | 2.17-317.el7      |                   | glibc: stack guard protection bypass    |
+|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2019-1010022 |
++--------------+                  +          +                   +-------------------+                                         +
+| glibc-common |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
++--------------+------------------+          +-------------------+-------------------+-----------------------------------------+
+| nss          | CVE-2021-43527   |          | 3.53.1-3.el7_9    | 3.67.0-4.el7_9    | nss: Memory corruption in               |
+|              |                  |          |                   |                   | decodeECorDsaSignature with             |
+|              |                  |          |                   |                   | DSA signatures (and RSA-PSS)            |
+|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2021-43527   |
++--------------+                  +          +                   +                   +                                         +
+| nss-sysinit  |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
++--------------+                  +          +                   +                   +                                         +
+| nss-tools    |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
+|              |                  |          |                   |                   |                                         |
++--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+
+| openssl-libs | CVE-2020-1971    | HIGH     | 1:1.0.2k-19.el7   | 1:1.0.2k-21.el7_9 | openssl: EDIPARTYNAME                   |
+|              |                  |          |                   |                   | NULL pointer de-reference               |
+|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2020-1971    |
++--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+
+
+ +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/examples/others/index.html b/v0.25.4/docs/vulnerability/examples/others/index.html new file mode 100644 index 0000000000..33318bc3a7 --- /dev/null +++ b/v0.25.4/docs/vulnerability/examples/others/index.html @@ -0,0 +1,3195 @@ + + + + + + + + + + + + + + + + + + + + + + + Others - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Others

+

Skip Files

+

Trivy traversals directories and looks for all lock files by default. +If your image contains lock files which are not maintained by you, you can skip the file.

+
$ trivy image --skip-files "/Gemfile.lock" --skip-files "/var/lib/gems/2.5.0/gems/http_parser.rb-0.6.0/Gemfile.lock" quay.io/fluentd_elasticsearch/fluentd:v2.9.0
+
+

Skip Directories

+

Trivy traversals directories and look for all lock files by default. +If your image contains lock files which are not maintained by you, you can skip traversal in the specific directory.

+
$ trivy image --skip-dirs /var/lib/gems/2.5.0/gems/fluent-plugin-detect-exceptions-0.0.13 --skip-dirs "/var/lib/gems/2.5.0/gems/http_parser.rb-0.6.0" quay.io/fluentd_elasticsearch/fluentd:v2.9.0
+
+

Exit Code

+

By default, Trivy exits with code 0 even when vulnerabilities are detected. +Use the --exit-code option if you want to exit with a non-zero exit code.

+
$ trivy image --exit-code 1 python:3.4-alpine3.9
+
+
+Result + +
2019-05-16T12:51:43.500+0900    INFO    Updating vulnerability database...
+2019-05-16T12:52:00.387+0900    INFO    Detecting Alpine vulnerabilities...
+
+python:3.4-alpine3.9 (alpine 3.9.2)
+===================================
+Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)
+
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |
+|         |                  |          |                   |               | with long nonces               |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+
+ +
+ +

This option is useful for CI/CD. In the following example, the test will fail only when a critical vulnerability is found.

+
$ trivy image --exit-code 0 --severity MEDIUM,HIGH ruby:2.4.0
+$ trivy image --exit-code 1 --severity CRITICAL ruby:2.4.0
+
+

Reset

+

The --reset option removes all caches and database. +After this, it takes a long time as the vulnerability database needs to be rebuilt locally.

+
$ trivy image --reset
+
+
+Result + +
2019-05-16T13:05:31.935+0900    INFO    Resetting...
+
+ +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/examples/report/index.html b/v0.25.4/docs/vulnerability/examples/report/index.html new file mode 100644 index 0000000000..2a6df6b4d8 --- /dev/null +++ b/v0.25.4/docs/vulnerability/examples/report/index.html @@ -0,0 +1,3451 @@ + + + + + + + + + + + + + + + + + + + + + + + Report Formats - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Report Formats

+

Table (Default)

+
$ trivy image -f table golang:1.12-alpine
+
+

JSON

+
$ trivy image -f json -o results.json golang:1.12-alpine
+
+
+

Caution

+

v0.20.0 changes the JSON schema. For more details, see here.

+
+
+Result + +
2019-05-16T01:46:31.777+0900    INFO    Updating vulnerability database...
+2019-05-16T01:47:03.007+0900    INFO    Detecting Alpine vulnerabilities...
+
+ +
+ +
+JSON + +
[
+  {
+    "Target": "php-app/composer.lock",
+    "Vulnerabilities": null
+  },
+  {
+    "Target": "node-app/package-lock.json",
+    "Vulnerabilities": [
+      {
+        "VulnerabilityID": "CVE-2018-16487",
+        "PkgName": "lodash",
+        "InstalledVersion": "4.17.4",
+        "FixedVersion": "\u003e=4.17.11",
+        "Title": "lodash: Prototype pollution in utilities function",
+        "Description": "A prototype pollution vulnerability was found in lodash \u003c4.17.11 where the functions merge, mergeWith, and defaultsDeep can be tricked into adding or modifying properties of Object.prototype.",
+        "Severity": "HIGH",
+        "References": [
+          "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-16487",
+        ]
+      }
+    ]
+  },
+  {
+    "Target": "trivy-ci-test (alpine 3.7.1)",
+    "Vulnerabilities": [
+      {
+        "VulnerabilityID": "CVE-2018-16840",
+        "PkgName": "curl",
+        "InstalledVersion": "7.61.0-r0",
+        "FixedVersion": "7.61.1-r1",
+        "Title": "curl: Use-after-free when closing \"easy\" handle in Curl_close()",
+        "Description": "A heap use-after-free flaw was found in curl versions from 7.59.0 through 7.61.1 in the code related to closing an easy handle. ",
+        "Severity": "HIGH",
+        "References": [
+          "https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-16840",
+        ]
+      },
+      {
+        "VulnerabilityID": "CVE-2019-3822",
+        "PkgName": "curl",
+        "InstalledVersion": "7.61.0-r0",
+        "FixedVersion": "7.61.1-r2",
+        "Title": "curl: NTLMv2 type-3 header stack buffer overflow",
+        "Description": "libcurl versions from 7.36.0 to before 7.64.0 are vulnerable to a stack-based buffer overflow. ",
+        "Severity": "HIGH",
+        "References": [
+          "https://curl.haxx.se/docs/CVE-2019-3822.html",
+          "https://lists.apache.org/thread.html/8338a0f605bdbb3a6098bb76f666a95fc2b2f53f37fa1ecc89f1146f@%3Cdevnull.infra.apache.org%3E"
+        ]
+      },
+      {
+        "VulnerabilityID": "CVE-2018-16839",
+        "PkgName": "curl",
+        "InstalledVersion": "7.61.0-r0",
+        "FixedVersion": "7.61.1-r1",
+        "Title": "curl: Integer overflow leading to heap-based buffer overflow in Curl_sasl_create_plain_message()",
+        "Description": "Curl versions 7.33.0 through 7.61.1 are vulnerable to a buffer overrun in the SASL authentication code that may lead to denial of service.",
+        "Severity": "HIGH",
+        "References": [
+          "https://github.com/curl/curl/commit/f3a24d7916b9173c69a3e0ee790102993833d6c5",
+        ]
+      },
+      {
+        "VulnerabilityID": "CVE-2018-19486",
+        "PkgName": "git",
+        "InstalledVersion": "2.15.2-r0",
+        "FixedVersion": "2.15.3-r0",
+        "Title": "git: Improper handling of PATH allows for commands to be executed from the current directory",
+        "Description": "Git before 2.19.2 on Linux and UNIX executes commands from the current working directory (as if '.' were at the end of $PATH) in certain cases involving the run_command() API and run-command.c, because there was a dangerous change from execvp to execv during 2017.",
+        "Severity": "HIGH",
+        "References": [
+          "https://usn.ubuntu.com/3829-1/",
+        ]
+      },
+      {
+        "VulnerabilityID": "CVE-2018-17456",
+        "PkgName": "git",
+        "InstalledVersion": "2.15.2-r0",
+        "FixedVersion": "2.15.3-r0",
+        "Title": "git: arbitrary code execution via .gitmodules",
+        "Description": "Git before 2.14.5, 2.15.x before 2.15.3, 2.16.x before 2.16.5, 2.17.x before 2.17.2, 2.18.x before 2.18.1, and 2.19.x before 2.19.1 allows remote code execution during processing of a recursive \"git clone\" of a superproject if a .gitmodules file has a URL field beginning with a '-' character.",
+        "Severity": "HIGH",
+        "References": [
+          "http://www.securitytracker.com/id/1041811",
+        ]
+      }
+    ]
+  },
+  {
+    "Target": "python-app/Pipfile.lock",
+    "Vulnerabilities": null
+  },
+  {
+    "Target": "ruby-app/Gemfile.lock",
+    "Vulnerabilities": null
+  },
+  {
+    "Target": "rust-app/Cargo.lock",
+    "Vulnerabilities": null
+  }
+]
+
+ +
+ +

VulnerabilityID, PkgName, InstalledVersion, and Severity in Vulnerabilities are always filled with values, but other fields might be empty.

+

SARIF

+

Sarif can be generated with the --format sarif option.

+
$ trivy image --format sarif -o report.sarif  golang:1.12-alpine
+
+

This SARIF file can be uploaded to GitHub code scanning results, and there is a Trivy GitHub Action for automating this process.

+

Template

+

Custom Template

+
$ trivy image --format template --template "{{ range . }} {{ .Target }} {{ end }}" golang:1.12-alpine
+
+
+Result + +
2020-01-02T18:02:32.856+0100    INFO    Detecting Alpine vulnerabilities...
+ golang:1.12-alpine (alpine 3.10.2)
+
+
+ +

You can compute different figures within the template using sprig functions. +As an example you can summarize the different classes of issues:

+
$ trivy image --format template --template '{{- $critical := 0 }}{{- $high := 0 }}{{- range . }}{{- range .Vulnerabilities }}{{- if  eq .Severity "CRITICAL" }}{{- $critical = add $critical 1 }}{{- end }}{{- if  eq .Severity "HIGH" }}{{- $high = add $high 1 }}{{- end }}{{- end }}{{- end }}Critical: {{ $critical }}, High: {{ $high }}' golang:1.12-alpine
+
+
+Result + +
Critical: 0, High: 2
+
+
+ +

For other features of sprig, see the official sprig documentation.

+

Load templates from a file

+

You can load templates from a file prefixing the template path with an @.

+
$ trivy image --format template --template "@/path/to/template" golang:1.12-alpine
+
+

Default Templates

+

If Trivy is installed using rpm then default templates can be found at /usr/local/share/trivy/templates.

+

XML

+

In the following example using the template junit.tpl XML can be generated. +

$ trivy image --format template --template "@contrib/junit.tpl" -o junit-report.xml  golang:1.12-alpine
+

+

ASFF

+

Trivy also supports an ASFF template for reporting findings to AWS Security Hub

+

HTML

+
$ trivy image --format template --template "@contrib/html.tpl" -o report.html golang:1.12-alpine
+
+

The following example shows use of default HTML template when Trivy is installed using rpm.

+
$ trivy image --format template --template "@/usr/local/share/trivy/templates/html.tpl" -o report.html golang:1.12-alpine
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/scanning/filesystem/index.html b/v0.25.4/docs/vulnerability/scanning/filesystem/index.html new file mode 100644 index 0000000000..d3929df515 --- /dev/null +++ b/v0.25.4/docs/vulnerability/scanning/filesystem/index.html @@ -0,0 +1,3239 @@ + + + + + + + + + + + + + + + + + + + + + + + Filesystem - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Filesystem

+

Scan a local project including language-specific files.

+
$ trivy fs /path/to/project
+
+

Standalone mode

+

Local Project

+

Trivy will look for vulnerabilities based on lock files such as Gemfile.lock and package-lock.json.

+
$ trivy fs ~/src/github.com/aquasecurity/trivy-ci-test
+
+
+Result + +
2020-06-01T17:06:58.652+0300    WARN    OS is not detected and vulnerabilities in OS packages are not detected.
+2020-06-01T17:06:58.652+0300    INFO    Detecting pipenv vulnerabilities...
+2020-06-01T17:06:58.691+0300    INFO    Detecting cargo vulnerabilities...
+
+Pipfile.lock
+============
+Total: 10 (UNKNOWN: 2, LOW: 0, MEDIUM: 6, HIGH: 2, CRITICAL: 0)
+
++---------------------+------------------+----------+-------------------+------------------------+------------------------------------+
+|       LIBRARY       | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |     FIXED VERSION      |               TITLE                |
++---------------------+------------------+----------+-------------------+------------------------+------------------------------------+
+| django              | CVE-2020-7471    | HIGH     | 2.0.9             | 3.0.3, 2.2.10, 1.11.28 | django: potential                  |
+|                     |                  |          |                   |                        | SQL injection via                  |
+|                     |                  |          |                   |                        | StringAgg(delimiter)               |
++                     +------------------+----------+                   +------------------------+------------------------------------+
+|                     | CVE-2019-19844   | MEDIUM   |                   | 3.0.1, 2.2.9, 1.11.27  | Django: crafted email address      |
+|                     |                  |          |                   |                        | allows account takeover            |
++                     +------------------+          +                   +------------------------+------------------------------------+
+|                     | CVE-2019-3498    |          |                   | 2.1.5, 2.0.10, 1.11.18 | python-django: Content             |
+|                     |                  |          |                   |                        | spoofing via URL path in           |
+|                     |                  |          |                   |                        | default 404 page                   |
++                     +------------------+          +                   +------------------------+------------------------------------+
+|                     | CVE-2019-6975    |          |                   | 2.1.6, 2.0.11, 1.11.19 | python-django:                     |
+|                     |                  |          |                   |                        | memory exhaustion in               |
+|                     |                  |          |                   |                        | django.utils.numberformat.format() |
++---------------------+------------------+----------+-------------------+------------------------+------------------------------------+
+...
+
+ +
+ +

Single file

+

It's also possible to scan a single file.

+
$ trivy fs ~/src/github.com/aquasecurity/trivy-ci-test/Pipfile.lock
+
+

Client/Server mode

+

You must launch Trivy server in advance.

+
$ trivy server
+
+

Then, Trivy works as a client if you specify the --server option.

+
$ trivy fs --server http://localhost:4954 --severity CRITICAL ./integration/testdata/fixtures/fs/pom/
+
+
+Result + +
pom.xml (pom)
+=============
+Total: 4 (CRITICAL: 4)
+
++---------------------------------------------+------------------+----------+-------------------+--------------------------------+---------------------------------------+
+|                   LIBRARY                   | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |         FIXED VERSION          |                 TITLE                 |
++---------------------------------------------+------------------+----------+-------------------+--------------------------------+---------------------------------------+
+| com.fasterxml.jackson.core:jackson-databind | CVE-2017-17485   | CRITICAL | 2.9.1             | 2.8.11, 2.9.4                  | jackson-databind: Unsafe              |
+|                                             |                  |          |                   |                                | deserialization due to                |
+|                                             |                  |          |                   |                                | incomplete black list (incomplete     |
+|                                             |                  |          |                   |                                | fix for CVE-2017-15095)...            |
+|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2017-17485 |
++                                             +------------------+          +                   +--------------------------------+---------------------------------------+
+|                                             | CVE-2020-9546    |          |                   | 2.7.9.7, 2.8.11.6, 2.9.10.4    | jackson-databind: Serialization       |
+|                                             |                  |          |                   |                                | gadgets in shaded-hikari-config       |
+|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2020-9546  |
++                                             +------------------+          +                   +                                +---------------------------------------+
+|                                             | CVE-2020-9547    |          |                   |                                | jackson-databind: Serialization       |
+|                                             |                  |          |                   |                                | gadgets in ibatis-sqlmap              |
+|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2020-9547  |
++                                             +------------------+          +                   +                                +---------------------------------------+
+|                                             | CVE-2020-9548    |          |                   |                                | jackson-databind: Serialization       |
+|                                             |                  |          |                   |                                | gadgets in anteros-core               |
+|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2020-9548  |
++---------------------------------------------+------------------+----------+-------------------+--------------------------------+---------------------------------------+
+
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/scanning/git-repository/index.html b/v0.25.4/docs/vulnerability/scanning/git-repository/index.html new file mode 100644 index 0000000000..92a5c9a782 --- /dev/null +++ b/v0.25.4/docs/vulnerability/scanning/git-repository/index.html @@ -0,0 +1,3244 @@ + + + + + + + + + + + + + + + + + + + + + + + Git Repository - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Git Repository

+

Scan your remote git repository

+
$ trivy repo https://github.com/knqyf263/trivy-ci-test
+
+
+Result + +
2021-03-09T15:04:19.003+0200    INFO    Detecting cargo vulnerabilities...
+2021-03-09T15:04:19.005+0200    INFO    Detecting pipenv vulnerabilities...
+
+Cargo.lock
+==========
+Total: 7 (UNKNOWN: 7, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)
+
++----------+-------------------+----------+-------------------+------------------------------+---------------------------------------------+
+| LIBRARY  | VULNERABILITY ID  | SEVERITY | INSTALLED VERSION |        FIXED VERSION         |                    TITLE                    |
++----------+-------------------+----------+-------------------+------------------------------+---------------------------------------------+
+| ammonia  | RUSTSEC-2019-0001 | UNKNOWN  | 1.9.0             | >= 2.1.0                     | Uncontrolled recursion leads                |
+|          |                   |          |                   |                              | to abort in HTML serialization              |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2019-0001 |
++----------+-------------------+          +-------------------+------------------------------+---------------------------------------------+
+| openssl  | RUSTSEC-2016-0001 |          | 0.8.3             | >= 0.9.0                     | SSL/TLS MitM vulnerability                  |
+|          |                   |          |                   |                              | due to insecure defaults                    |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2016-0001 |
++----------+-------------------+          +-------------------+------------------------------+---------------------------------------------+
+| smallvec | RUSTSEC-2018-0018 |          | 0.6.9             | >= 0.6.13                    | smallvec creates uninitialized              |
+|          |                   |          |                   |                              | value of any type                           |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2018-0018 |
++          +-------------------+          +                   +------------------------------+---------------------------------------------+
+|          | RUSTSEC-2019-0009 |          |                   | >= 0.6.10                    | Double-free and use-after-free              |
+|          |                   |          |                   |                              | in SmallVec::grow()                         |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2019-0009 |
++          +-------------------+          +                   +                              +---------------------------------------------+
+|          | RUSTSEC-2019-0012 |          |                   |                              | Memory corruption in SmallVec::grow()       |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2019-0012 |
++          +-------------------+          +                   +------------------------------+---------------------------------------------+
+|          | RUSTSEC-2021-0003 |          |                   | >= 0.6.14, < 1.0.0, >= 1.6.1 | Buffer overflow in SmallVec::insert_many    |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2021-0003 |
++----------+-------------------+          +-------------------+------------------------------+---------------------------------------------+
+| tempdir  | RUSTSEC-2018-0017 |          | 0.3.7             |                              | `tempdir` crate has been                    |
+|          |                   |          |                   |                              | deprecated; use `tempfile` instead          |
+|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2018-0017 |
++----------+-------------------+----------+-------------------+------------------------------+---------------------------------------------+
+
+Pipfile.lock
+============
+Total: 20 (UNKNOWN: 3, LOW: 0, MEDIUM: 7, HIGH: 5, CRITICAL: 5)
+
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+|       LIBRARY       | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |     FIXED VERSION      |                 TITLE                 |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| django              | CVE-2019-19844   | CRITICAL | 2.0.9             | 3.0.1, 2.2.9, 1.11.27  | Django: crafted email address         |
+|                     |                  |          |                   |                        | allows account takeover               |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-19844 |
++                     +------------------+          +                   +------------------------+---------------------------------------+
+|                     | CVE-2020-7471    |          |                   | 3.0.3, 2.2.10, 1.11.28 | django: potential SQL injection       |
+|                     |                  |          |                   |                        | via StringAgg(delimiter)              |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-7471  |
++                     +------------------+----------+                   +------------------------+---------------------------------------+
+|                     | CVE-2019-6975    | HIGH     |                   | 2.1.6, 2.0.11, 1.11.19 | python-django: memory exhaustion in   |
+|                     |                  |          |                   |                        | django.utils.numberformat.format()    |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-6975  |
++                     +------------------+          +                   +------------------------+---------------------------------------+
+|                     | CVE-2020-9402    |          |                   | 3.0.4, 2.2.11, 1.11.29 | django: potential SQL injection       |
+|                     |                  |          |                   |                        | via "tolerance" parameter in          |
+|                     |                  |          |                   |                        | GIS functions and aggregates...       |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-9402  |
++                     +------------------+----------+                   +------------------------+---------------------------------------+
+|                     | CVE-2019-3498    | MEDIUM   |                   | 2.1.5, 2.0.10, 1.11.18 | python-django: Content spoofing       |
+|                     |                  |          |                   |                        | via URL path in default 404 page      |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-3498  |
++                     +------------------+          +                   +------------------------+---------------------------------------+
+|                     | CVE-2020-13254   |          |                   | 3.0.7, 2.2.13          | django: potential data leakage        |
+|                     |                  |          |                   |                        | via malformed memcached keys          |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-13254 |
++                     +------------------+          +                   +                        +---------------------------------------+
+|                     | CVE-2020-13596   |          |                   |                        | django: possible XSS via              |
+|                     |                  |          |                   |                        | admin ForeignKeyRawIdWidget           |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-13596 |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| django-cors-headers | pyup.io-37132    | UNKNOWN  | 2.5.2             | 3.0.0                  | In django-cors-headers                |
+|                     |                  |          |                   |                        | version 3.0.0,                        |
+|                     |                  |          |                   |                        | ``CORS_ORIGIN_WHITELIST``             |
+|                     |                  |          |                   |                        | requires URI schemes, and             |
+|                     |                  |          |                   |                        | optionally ports. This...             |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| djangorestframework | CVE-2020-25626   | MEDIUM   | 3.9.2             | 3.11.2                 | django-rest-framework: XSS            |
+|                     |                  |          |                   |                        | Vulnerability in API viewer           |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-25626 |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| httplib2            | CVE-2021-21240   | HIGH     | 0.12.1            | 0.19.0                 | python-httplib2: Regular              |
+|                     |                  |          |                   |                        | expression denial of                  |
+|                     |                  |          |                   |                        | service via malicious header          |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2021-21240 |
++                     +------------------+----------+                   +------------------------+---------------------------------------+
+|                     | CVE-2020-11078   | MEDIUM   |                   | 0.18.0                 | python-httplib2: CRLF injection       |
+|                     |                  |          |                   |                        | via an attacker controlled            |
+|                     |                  |          |                   |                        | unescaped part of uri for...          |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-11078 |
++                     +------------------+----------+                   +                        +---------------------------------------+
+|                     | pyup.io-38303    | UNKNOWN  |                   |                        | Httplib2 0.18.0 is an                 |
+|                     |                  |          |                   |                        | important security update to          |
+|                     |                  |          |                   |                        | patch a CWE-93 CRLF...                |
++---------------------+------------------+          +-------------------+------------------------+---------------------------------------+
+| jinja2              | pyup.io-39525    |          | 2.10.1            | 2.11.3                 | This affects the package              |
+|                     |                  |          |                   |                        | jinja2 from 0.0.0 and before          |
+|                     |                  |          |                   |                        | 2.11.3. The ReDOS...                  |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| py                  | CVE-2020-29651   | HIGH     | 1.8.0             |                        | python-py: ReDoS in the py.path.svnwc |
+|                     |                  |          |                   |                        | component via mailicious input        |
+|                     |                  |          |                   |                        | to blame functionality...             |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-29651 |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| pyyaml              | CVE-2019-20477   | CRITICAL |               5.1 |                        | PyYAML: command execution             |
+|                     |                  |          |                   |                        | through python/object/apply           |
+|                     |                  |          |                   |                        | constructor in FullLoader             |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-20477 |
++                     +------------------+          +                   +------------------------+---------------------------------------+
+|                     | CVE-2020-14343   |          |                   |                    5.4 | PyYAML: incomplete                    |
+|                     |                  |          |                   |                        | fix for CVE-2020-1747                 |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-14343 |
++                     +------------------+          +                   +------------------------+---------------------------------------+
+|                     | CVE-2020-1747    |          |                   | 5.3.1                  | PyYAML: arbitrary command             |
+|                     |                  |          |                   |                        | execution through python/object/new   |
+|                     |                  |          |                   |                        | when FullLoader is used               |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-1747  |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+| urllib3             | CVE-2019-11324   | HIGH     | 1.24.1            | 1.24.2                 | python-urllib3: Certification         |
+|                     |                  |          |                   |                        | mishandle when error should be thrown |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-11324 |
++                     +------------------+----------+                   +------------------------+---------------------------------------+
+|                     | CVE-2019-11236   | MEDIUM   |                   |                        | python-urllib3: CRLF injection        |
+|                     |                  |          |                   |                        | due to not encoding the               |
+|                     |                  |          |                   |                        | '\r\n' sequence leading to...         |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-11236 |
++                     +------------------+          +                   +------------------------+---------------------------------------+
+|                     | CVE-2020-26137   |          |                   | 1.25.9                 | python-urllib3: CRLF injection        |
+|                     |                  |          |                   |                        | via HTTP request method               |
+|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-26137 |
++---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+
+
+ +
+ +

Scanning Private Repositories

+

In order to scan private GitHub or GitLab repositories, the environment variable GITHUB_TOKEN or GITLAB_TOKEN must be set, respectively, with a valid token that has access to the private repository being scanned.

+

The GITHUB_TOKEN environment variable will take precedence over GITLAB_TOKEN, so if a private GitLab repository will be scanned, then GITHUB_TOKEN must be unset.

+

For example:

+
$ export GITHUB_TOKEN="your_private_github_token"
+$ trivy repo <your private GitHub repo URL>
+$
+$ # or
+$ export GITLAB_TOKEN="your_private_gitlab_token"
+$ trivy repo <your private GitLab repo URL>
+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/scanning/image/index.html b/v0.25.4/docs/vulnerability/scanning/image/index.html new file mode 100644 index 0000000000..2e2be1be20 --- /dev/null +++ b/v0.25.4/docs/vulnerability/scanning/image/index.html @@ -0,0 +1,3183 @@ + + + + + + + + + + + + + + + + + + + + + + + Container Image - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Image

+

Container Images

+

Simply specify an image name (and a tag).

+
$ trivy image [YOUR_IMAGE_NAME]
+
+

For example:

+
$ trivy image python:3.4-alpine
+
+
+Result + +
2019-05-16T01:20:43.180+0900    INFO    Updating vulnerability database...
+2019-05-16T01:20:53.029+0900    INFO    Detecting Alpine vulnerabilities...
+
+python:3.4-alpine3.9 (alpine 3.9.2)
+===================================
+Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)
+
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |
+|         |                  |          |                   |               | with long nonces               |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+
+ +
+ +

Tar Files

+
$ docker pull ruby:3.1-alpine3.15
+$ docker save ruby:3.1-alpine3.15 -o ruby-3.1.tar
+$ trivy image --input ruby-3.1.tar
+
+
+Result + +
2022-02-03T10:08:19.127Z        INFO    Detected OS: alpine
+2022-02-03T10:08:19.127Z        WARN    This OS version is not on the EOL list: alpine 3.15
+2022-02-03T10:08:19.127Z        INFO    Detecting Alpine vulnerabilities...
+2022-02-03T10:08:19.127Z        INFO    Number of language-specific files: 2
+2022-02-03T10:08:19.127Z        INFO    Detecting gemspec vulnerabilities...
+2022-02-03T10:08:19.128Z        INFO    Detecting node-pkg vulnerabilities...
+2022-02-03T10:08:19.128Z        WARN    This OS version is no longer supported by the distribution: alpine 3.15.0
+2022-02-03T10:08:19.128Z        WARN    The vulnerability detection may be insufficient because security updates are not provided
+
+ruby-3.1.tar (alpine 3.15.0)
+============================
+Total: 3 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 3, CRITICAL: 0)
+
++----------+------------------+----------+-------------------+---------------+---------------------------------------+
+| LIBRARY  | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |
++----------+------------------+----------+-------------------+---------------+---------------------------------------+
+| gmp      | CVE-2021-43618   | HIGH     | 6.2.1-r0          | 6.2.1-r1      | gmp: Integer overflow and resultant   |
+|          |                  |          |                   |               | buffer overflow via crafted input     |
+|          |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-43618 |
++----------+                  +          +                   +               +                                       +
+| gmp-dev  |                  |          |                   |               |                                       |
+|          |                  |          |                   |               |                                       |
+|          |                  |          |                   |               |                                       |
++----------+                  +          +                   +               +                                       +
+| libgmpxx |                  |          |                   |               |                                       |
+|          |                  |          |                   |               |                                       |
+|          |                  |          |                   |               |                                       |
++----------+------------------+----------+-------------------+---------------+---------------------------------------+
+
+Node.js (node-pkg)
+==================
+Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)
+
+
+Ruby (gemspec)
+==============
+Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)
+
+ +
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/scanning/index.html b/v0.25.4/docs/vulnerability/scanning/index.html new file mode 100644 index 0000000000..91682a140b --- /dev/null +++ b/v0.25.4/docs/vulnerability/scanning/index.html @@ -0,0 +1,3037 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+ + +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/docs/vulnerability/scanning/rootfs/index.html b/v0.25.4/docs/vulnerability/scanning/rootfs/index.html new file mode 100644 index 0000000000..2f993824a8 --- /dev/null +++ b/v0.25.4/docs/vulnerability/scanning/rootfs/index.html @@ -0,0 +1,3166 @@ + + + + + + + + + + + + + + + + + + + + + + + Rootfs - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Rootfs

+

Scan a root filesystem (such as a host machine, a virtual machine image, or an unpacked container image filesystem).

+
$ trivy rootfs /path/to/rootfs
+
+

From Inside Containers

+

Scan your container from inside the container.

+
$ docker run --rm -it alpine:3.11
+/ # curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin
+/ # trivy rootfs /
+
+
+Result + +
2021-03-08T05:22:26.378Z        INFO    Need to update DB
+2021-03-08T05:22:26.380Z        INFO    Downloading DB...
+20.37 MiB / 20.37 MiB [-------------------------------------------------------------------------------------------------------------------------------------] 100.00% 8.24 MiB p/s 2s
+2021-03-08T05:22:30.134Z        INFO    Detecting Alpine vulnerabilities...
+2021-03-08T05:22:30.138Z        INFO    Trivy skips scanning programming language libraries because no supported file was detected
+
+313430f09696 (alpine 3.11.7)
+============================
+Total: 6 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 6, CRITICAL: 0)
+
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+|   LIBRARY    | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+| libcrypto1.1 | CVE-2021-23839   | HIGH     | 1.1.1i-r0         | 1.1.1j-r0     | openssl: incorrect SSLv2              |
+|              |                  |          |                   |               | rollback protection                   |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |
+|              |                  |          |                   |               | overflow in CipherUpdate              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |
+|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |
++--------------+------------------+          +                   +               +---------------------------------------+
+| libssl1.1    | CVE-2021-23839   |          |                   |               | openssl: incorrect SSLv2              |
+|              |                  |          |                   |               | rollback protection                   |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |
+|              |                  |          |                   |               | overflow in CipherUpdate              |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |
++              +------------------+          +                   +               +---------------------------------------+
+|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |
+|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |
+|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |
++--------------+------------------+----------+-------------------+---------------+---------------------------------------+
+
+ +
+ +

Other Examples

+ + + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/getting-started/further/index.html b/v0.25.4/getting-started/further/index.html new file mode 100644 index 0000000000..fa255dfd17 --- /dev/null +++ b/v0.25.4/getting-started/further/index.html @@ -0,0 +1,3130 @@ + + + + + + + + + + + + + + + + + + + + + + + Further Reading - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + + +
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/getting-started/installation/index.html b/v0.25.4/getting-started/installation/index.html new file mode 100644 index 0000000000..add6c6ec4f --- /dev/null +++ b/v0.25.4/getting-started/installation/index.html @@ -0,0 +1,3497 @@ + + + + + + + + + + + + + + + + + + + + + + + Installation - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + + + + +
+
+ + + + +

Installation

+

RHEL/CentOS

+
+

Add repository setting to /etc/yum.repos.d.

+
$ sudo vim /etc/yum.repos.d/trivy.repo
+[trivy]
+name=Trivy repository
+baseurl=https://aquasecurity.github.io/trivy-repo/rpm/releases/$releasever/$basearch/
+gpgcheck=0
+enabled=1
+$ sudo yum -y update
+$ sudo yum -y install trivy
+
+
+
+
rpm -ivh https://github.com/aquasecurity/trivy/releases/download/v0.25.4/trivy_0.25.4_Linux-64bit.rpm
+
+
+
+

Debian/Ubuntu

+
+

Add repository setting to /etc/apt/sources.list.d.

+
sudo apt-get install wget apt-transport-https gnupg lsb-release
+wget -qO - https://aquasecurity.github.io/trivy-repo/deb/public.key | sudo apt-key add -
+echo deb https://aquasecurity.github.io/trivy-repo/deb $(lsb_release -sc) main | sudo tee -a /etc/apt/sources.list.d/trivy.list
+sudo apt-get update
+sudo apt-get install trivy
+
+
+
+
wget https://github.com/aquasecurity/trivy/releases/download/v0.25.4/trivy_0.25.4_Linux-64bit.deb
+sudo dpkg -i trivy_0.25.4_Linux-64bit.deb
+
+
+
+

Arch Linux

+

Package trivy-bin can be installed from the Arch User Repository.

+
+
pikaur -Sy trivy-bin
+
+
+
+
yay -Sy trivy-bin
+
+
+
+

Homebrew

+

You can use homebrew on macOS and Linux.

+
brew install aquasecurity/trivy/trivy
+
+

Nix/NixOS

+

You can use nix on Linux or macOS and on others unofficially.

+

Note that trivy is currently only in the unstable channels.

+
nix-env --install trivy
+
+

Or through your configuration on NixOS or with home-manager as usual

+

Install Script

+

This script downloads Trivy binary based on your OS and architecture.

+
curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin v0.25.4
+
+

Binary

+

Download the archive file for your operating system/architecture from here. +Unpack the archive, and put the binary somewhere in your $PATH (on UNIX-y systems, /usr/local/bin or the like). +Make sure it has execution bits turned on.

+

From source

+
mkdir -p $GOPATH/src/github.com/aquasecurity
+cd $GOPATH/src/github.com/aquasecurity
+git clone --depth 1 --branch v0.25.4 https://github.com/aquasecurity/trivy
+cd trivy/cmd/trivy/
+export GO111MODULE=on
+go install
+
+

Docker

+

Docker Hub

+

Replace [YOUR_CACHE_DIR] with the cache directory on your machine.

+
docker pull aquasec/trivy:0.25.4
+
+

Example:

+
+
docker run --rm -v [YOUR_CACHE_DIR]:/root/.cache/ aquasec/trivy:0.25.4 image [YOUR_IMAGE_NAME]
+
+
+
+
docker run --rm -v $HOME/Library/Caches:/root/.cache/ aquasec/trivy:0.25.4 image [YOUR_IMAGE_NAME
+
+
+
+

If you would like to scan the image on your host machine, you need to mount docker.sock.

+
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock \
+    -v $HOME/Library/Caches:/root/.cache/ aquasec/trivy:0.25.4 python:3.4-alpine
+
+

Please re-pull latest aquasec/trivy if an error occurred.

+
+Result + +
2019-05-16T01:20:43.180+0900    INFO    Updating vulnerability database...
+2019-05-16T01:20:53.029+0900    INFO    Detecting Alpine vulnerabilities...
+
+python:3.4-alpine3.9 (alpine 3.9.2)
+===================================
+Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)
+
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |
+|         |                  |          |                   |               | with long nonces               |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+
+ +
+ +

GitHub Container Registry

+

The same image is hosted on GitHub Container Registry as well.

+
docker pull ghcr.io/aquasecurity/trivy:0.25.4
+
+

Amazon ECR Public

+

The same image is hosted on Amazon ECR Public as well.

+
docker pull public.ecr.aws/aquasecurity/trivy:0.25.4
+
+

Helm

+

Installing from the the Aqua Chart Repository

+
helm repo add aquasecurity https://aquasecurity.github.io/helm-charts/
+helm repo update
+helm search repo trivy
+helm install my-trivy aquasecurity/trivy
+
+

Installing the Chart

+

To install the chart with the release name my-release:

+
helm install my-release .
+
+

The command deploys Trivy on the Kubernetes cluster in the default configuration. The Parameters +section lists the parameters that can be configured during installation.

+
+

Tip: List all releases using helm list.

+
+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/getting-started/overview/index.html b/v0.25.4/getting-started/overview/index.html new file mode 100644 index 0000000000..106198d2d5 --- /dev/null +++ b/v0.25.4/getting-started/overview/index.html @@ -0,0 +1,3055 @@ + + + + + + + + + + + + + + + + + + + + + + + Overview - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Overview

+

Trivy detects two types of security issues:

+
    +
  • Vulnerabilities
      +
    • OS packages (Alpine, Red Hat Universal Base Image, Red Hat Enterprise Linux, CentOS, AlmaLinux, Rocky Linux, CBL-Mariner, Oracle Linux, Debian, Ubuntu, Amazon Linux, openSUSE Leap, SUSE Enterprise Linux, Photon OS and Distroless)
    • +
    • Language-specific packages (Bundler, Composer, Pipenv, Poetry, npm, yarn, Cargo, NuGet, Maven, and Go)
    • +
    +
  • +
  • Misconfigurations
      +
    • Kubernetes
    • +
    • Docker
    • +
    • Terraform
    • +
    • CloudFormation
    • +
    • more coming soon
    • +
    +
  • +
+

Trivy can scan three different artifacts:

+ +

It is designed to be used in CI. Before pushing to a container registry or deploying your application, you can scan your local container image and other artifacts easily. +See Integrations for details.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/getting-started/quickstart/index.html b/v0.25.4/getting-started/quickstart/index.html new file mode 100644 index 0000000000..1e82f594a9 --- /dev/null +++ b/v0.25.4/getting-started/quickstart/index.html @@ -0,0 +1,3165 @@ + + + + + + + + + + + + + + + + + + + + + + + Quick Start - Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + +
+
+
+ + + + + + +
+
+
+ + + +
+
+
+ + + +
+
+
+ + +
+
+ + + + +

Quick Start

+

Scan image for vulnerabilities

+

Simply specify an image name (and a tag).

+
$ trivy image [YOUR_IMAGE_NAME]
+
+

For example:

+
$ trivy image python:3.4-alpine
+
+
+Result + +
2019-05-16T01:20:43.180+0900    INFO    Updating vulnerability database...
+2019-05-16T01:20:53.029+0900    INFO    Detecting Alpine vulnerabilities...
+
+python:3.4-alpine3.9 (alpine 3.9.2)
+===================================
+Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)
+
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |
+|         |                  |          |                   |               | with long nonces               |
++---------+------------------+----------+-------------------+---------------+--------------------------------+
+
+ +
+ +

For more details, see here.

+

Scan directory for misconfigurations

+

Simply specify a directory containing IaC files such as Terraform and Dockerfile.

+
$ trivy config [YOUR_IAC_DIR]
+
+

For example:

+
$ ls build/
+Dockerfile
+$ trivy config ./build
+
+
+Result + +
2021-07-09T10:06:29.188+0300    INFO    Need to update the built-in policies
+2021-07-09T10:06:29.188+0300    INFO    Downloading the built-in policies...
+2021-07-09T10:06:30.520+0300    INFO    Detected config files: 1
+
+Dockerfile (dockerfile)
+=======================
+Tests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)
+Failures: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)
+
++---------------------------+------------+----------------------+----------+------------------------------------------+
+|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |
+|                           |            |                      |          | Dockerfile should not be 'root'          |
+|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |
++---------------------------+------------+----------------------+----------+------------------------------------------+
+
+ +
+ +

For more details, see here.

+ + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/imgs/client-server.png b/v0.25.4/imgs/client-server.png new file mode 100644 index 0000000000..fce67eefdf Binary files /dev/null and b/v0.25.4/imgs/client-server.png differ diff --git a/v0.25.4/imgs/excalidraw/client-server.excalidraw b/v0.25.4/imgs/excalidraw/client-server.excalidraw new file mode 100644 index 0000000000..ad67667a9c --- /dev/null +++ b/v0.25.4/imgs/excalidraw/client-server.excalidraw @@ -0,0 +1,1151 @@ +{ + "type": "excalidraw", + "version": 2, + "source": "https://excalidraw.com", + "elements": [ + { + "id": "ribsikcWWSf8Aw4M6BOYJ", + "type": "rectangle", + "x": 458.6370544433594, + "y": 379.5105285644531, + "width": 169.21945190429688, + "height": 104.2457275390625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 698826281, + "version": 381, + "versionNonce": 413251305, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo", + "nXkZQsrtjmNqPM6SmPxrc", + "Ljv7RJF8FjyOJX3vZ2ou8", + "o_BKODe9vjtHWQsJ8F3tD", + "zTrormMP-N-W6thSxlTgK", + "fBva4zCGT2vIFPpTWC-oZ" + ] + }, + { + "id": "GkrbG--OvBT9zJ-w8E5oQ", + "type": "ellipse", + "x": 427.04335021972656, + "y": 65.240966796875, + "width": 215.20677185058594, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 995070601, + "version": 684, + "versionNonce": 78137383, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY" + ] + }, + { + "id": "KPLvdnBVoU3U5XGhCch-x", + "type": "text", + "x": 511.77996826171875, + "y": 407.1625671386719, + "width": 62, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 938497417, + "version": 253, + "versionNonce": 788328905, + "isDeleted": false, + "boundElementIds": null, + "text": "Trivy\nServer", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "Ry65W-Cczzy8M9JsouEgZ", + "type": "text", + "x": 488.6784362792969, + "y": 116.34368896484375, + "width": 89, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1676815783, + "version": 456, + "versionNonce": 14330695, + "isDeleted": false, + "boundElementIds": null, + "text": "GitHub\n(trivy-db)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "eJn9MVaNlcyj8-YPfrBSY", + "type": "arrow", + "x": 538.7528045696993, + "y": 220.23935960349465, + "width": 0.45618097890837817, + "height": 154.16252445127046, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1741763111, + "version": 1298, + "versionNonce": 267243689, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.45618097890837817, + 154.16252445127046 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "GkrbG--OvBT9zJ-w8E5oQ", + "focus": -0.03598869040285281, + "gap": 2.911871895302724 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -0.04563780983822428, + "gap": 5.10864450968802 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "2P02jU3j2eEc92lH0YSwm", + "type": "text", + "x": 575.9393615722656, + "y": 254.42640686035156, + "width": 327, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 501371753, + "version": 629, + "versionNonce": 185838183, + "isDeleted": false, + "boundElementIds": null, + "text": "1. Download Trivy DB\n(including vulnerability information)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "nXkZQsrtjmNqPM6SmPxrc", + "type": "arrow", + "x": 128.84802246093747, + "y": 395.4753877561888, + "width": 316.63877589590845, + "height": 0.1213064482017785, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 2075020231, + "version": 327, + "versionNonce": 1795630503, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 316.63877589590845, + 0.1213064482017785 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "2ZWTQQ2dQDWF8xj1BLdVG", + "focus": 1.483056059007069, + "gap": 12.799499511718778 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": 0.46421771350547186, + "gap": 12.273425031825923 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "OPRFQTrsfmF5a7us-mxkI", + "type": "draw", + "x": -60.78019714355469, + "y": 464.1100280880928, + "width": 72.64572143554688, + "height": 72.18890380859375, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1541066697, + "version": 569, + "versionNonce": 1115805895, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -39.526153564453125, + 16.35540771484375 + ], + [ + -32.219512939453125, + 72.170166015625 + ], + [ + 30.40386962890625, + 72.18890380859375 + ], + [ + 33.11956787109375, + 32.5743408203125 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "QzKnYI7o5Yxg_7szebL6Z", + "type": "draw", + "x": -37.06263732910158, + "y": 508.8429382443428, + "width": 16.976165771484375, + "height": 16.45367431640625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 2144447815, + "version": 203, + "versionNonce": 28982057, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 6.905059814453125, + -16.45367431640625 + ], + [ + 16.976165771484375, + -5.1099853515625 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "qqbEan2u1uU3loTdTvQ4B", + "type": "text", + "x": -184.67498779296875, + "y": 548.9957397580147, + "width": 230, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1619652615, + "version": 833, + "versionNonce": 981018599, + "isDeleted": false, + "boundElementIds": null, + "text": "6. Analyze pulled layers", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "GgiFj7vEEZT-VPfKiX6oo", + "type": "rectangle", + "x": -48.80625915527344, + "y": 386.3571411073208, + "width": 169.21945190429688, + "height": 104.2457275390625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1005158727, + "version": 500, + "versionNonce": 1358533383, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo", + "nXkZQsrtjmNqPM6SmPxrc", + "2tbWET6O9G38YibdIyLpy", + "FuK6iJ6YprzRoh4wg1UHf", + "o_BKODe9vjtHWQsJ8F3tD", + "fBva4zCGT2vIFPpTWC-oZ" + ] + }, + { + "id": "qQZYQjma-4h8rOrxn5yBo", + "type": "text", + "x": 4.3366546630859375, + "y": 414.00917968153954, + "width": 57, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1918851753, + "version": 381, + "versionNonce": 56771817, + "isDeleted": false, + "boundElementIds": null, + "text": "Trivy\nClient", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "vtOTfv319aihVmgTMMbQG", + "type": "ellipse", + "x": -95.58086395263672, + "y": 68.13672637939453, + "width": 249.63902282714844, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#228be6", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1265127495, + "version": 929, + "versionNonce": 1316732873, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "2tbWET6O9G38YibdIyLpy", + "FuK6iJ6YprzRoh4wg1UHf" + ] + }, + { + "id": "bz64cTcmJtjZotVar2MHr", + "type": "text", + "x": -73.4975357055664, + "y": 108.37564849853516, + "width": 202, + "height": 74, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 976812969, + "version": 670, + "versionNonce": 938982727, + "isDeleted": false, + "boundElementIds": null, + "text": "Container Registries\nor\nContainer Engines", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 67 + }, + { + "id": "Z5DzSXSTeTNfyo9GRr57B", + "type": "ellipse", + "x": 871.677619934082, + "y": 347.7999496459961, + "width": 215.20677185058594, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#15aabf", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1020418857, + "version": 836, + "versionNonce": 845340329, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "Ljv7RJF8FjyOJX3vZ2ou8", + "zTrormMP-N-W6thSxlTgK" + ] + }, + { + "id": "SGILIw_oLMs1yuieBWcoP", + "type": "text", + "x": 898.8127059936523, + "y": 398.90267181396484, + "width": 158, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1953695719, + "version": 653, + "versionNonce": 1086225511, + "isDeleted": false, + "boundElementIds": [ + "zTrormMP-N-W6thSxlTgK" + ], + "text": "Cache Backend\n(Local or Redis)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "Ljv7RJF8FjyOJX3vZ2ou8", + "type": "arrow", + "x": 635.243173087202, + "y": 408.1721813855087, + "width": 237.82178502385182, + "height": 0.48828450950475144, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 744746601, + "version": 617, + "versionNonce": 230891913, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 237.82178502385182, + -0.48828450950475144 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -0.4450219327551968, + "gap": 7.386666739545717 + }, + "endBinding": { + "elementId": "Z5DzSXSTeTNfyo9GRr57B", + "focus": 0.21564885268585596, + "gap": 1.0335001891177882 + }, + "startArrowhead": "arrow", + "endArrowhead": "arrow" + }, + { + "id": "BlRXUB6fETT_zZD6O1fNL", + "type": "text", + "x": -163.05282592773438, + "y": 268.6500244140625, + "width": 124, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 609582183, + "version": 841, + "versionNonce": 2090882951, + "isDeleted": false, + "boundElementIds": null, + "text": "2. Download\n manifest", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "2tbWET6O9G38YibdIyLpy", + "type": "arrow", + "x": -12.186006749219864, + "y": 221.1919311337398, + "width": 0.45618097890837817, + "height": 154.16252445127046, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1740746569, + "version": 1437, + "versionNonce": 1574439017, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.45618097890837817, + 154.16252445127046 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "vtOTfv319aihVmgTMMbQG", + "focus": 0.3337009650548285, + "gap": 5.11281200236435 + }, + "endBinding": { + "elementId": "GgiFj7vEEZT-VPfKiX6oo", + "focus": -0.5585687247500966, + "gap": 11.002685522310514 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "2ZWTQQ2dQDWF8xj1BLdVG", + "type": "text", + "x": 141.64752197265625, + "y": 364.4148864746094, + "width": 294, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1932287977, + "version": 912, + "versionNonce": 299486887, + "isDeleted": false, + "boundElementIds": [ + "nXkZQsrtjmNqPM6SmPxrc" + ], + "text": "3. Ask missing layers in cache", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "pIwVlwytOx1ZJ4aOCvtRF", + "type": "text", + "x": 636.46630859375, + "y": 352.5987548828125, + "width": 246, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 973317671, + "version": 871, + "versionNonce": 1819087689, + "isDeleted": false, + "boundElementIds": null, + "text": "4. Return existing layers", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "FuK6iJ6YprzRoh4wg1UHf", + "type": "arrow", + "x": 75.37933138554581, + "y": 220.52838743256788, + "width": 0.45618097890837817, + "height": 154.16252445127046, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1148774855, + "version": 1487, + "versionNonce": 722952647, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.45618097890837817, + 154.16252445127046 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "vtOTfv319aihVmgTMMbQG", + "focus": -0.36784928325571326, + "gap": 5.485033392258245 + }, + "endBinding": { + "elementId": "GgiFj7vEEZT-VPfKiX6oo", + "focus": 0.4745035772454494, + "gap": 11.666229223482446 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "jgdyeMn1ZO33kPci2KoGL", + "type": "text", + "x": 94.91287231445312, + "y": 265.060302734375, + "width": 162, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1318802377, + "version": 872, + "versionNonce": 1037943337, + "isDeleted": false, + "boundElementIds": null, + "text": "5. Pull only\n missing layers", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "o_BKODe9vjtHWQsJ8F3tD", + "type": "arrow", + "x": 128.61206957157697, + "y": 440.13062341766545, + "width": 316.63877589590845, + "height": 0.1213064482017785, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 20958471, + "version": 415, + "versionNonce": 1769312487, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 316.63877589590845, + 0.1213064482017785 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "GgiFj7vEEZT-VPfKiX6oo", + "focus": 0.030966433153118762, + "gap": 8.19887682255353 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -0.16596748618058757, + "gap": 13.386208975873956 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "6DaFskX4dI8KM57tYJKwz", + "type": "text", + "x": 151.09302660282708, + "y": 409.41115607163283, + "width": 259, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 221555433, + "version": 1091, + "versionNonce": 1058379017, + "isDeleted": false, + "boundElementIds": null, + "text": "7. Send the analysis result", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "zTrormMP-N-W6thSxlTgK", + "type": "arrow", + "x": 639.0015349036082, + "y": 455.7986607407429, + "width": 233.13104569613938, + "height": 0.2533468001336132, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1122927111, + "version": 471, + "versionNonce": 377543687, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 233.13104569613938, + 0.2533468001336132 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": 0.4608119841777207, + "gap": 11.145028555951967 + }, + "endBinding": { + "elementId": "Z5DzSXSTeTNfyo9GRr57B", + "focus": -0.42458037983475105, + "gap": 8.237658674598492 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "2sst3d11OgZLJZ3vdmH15", + "type": "text", + "x": 709.851318359375, + "y": 424.4541015625, + "width": 82, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1801175527, + "version": 1132, + "versionNonce": 865078249, + "isDeleted": false, + "boundElementIds": null, + "text": "8. Store", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "QsQ0GcuViNzFPK5QPICis", + "type": "text", + "x": 408.48883056640625, + "y": 561.8040618896484, + "width": 254, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 773954023, + "version": 992, + "versionNonce": 419481159, + "isDeleted": false, + "boundElementIds": null, + "text": "9. Detect security issues", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "fBva4zCGT2vIFPpTWC-oZ", + "type": "arrow", + "x": 448.39657694205636, + "y": 484.4299201560043, + "width": 322.1210694778896, + "height": 0.5052042161862573, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 184790569, + "version": 677, + "versionNonce": 151709097, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -322.1210694778896, + -0.5052042161862573 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -1.0131990709910756, + "gap": 10.240477501303019 + }, + "endBinding": { + "elementId": "GgiFj7vEEZT-VPfKiX6oo", + "focus": 0.8669472708483955, + "gap": 5.862314715143327 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "PALQlCWrOXdjqBkRKhS6D", + "type": "draw", + "x": 523.952392578125, + "y": 487.95794677734375, + "width": 72.486083984375, + "height": 62.78338623046875, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#15aabf", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 273802089, + "version": 310, + "versionNonce": 230581607, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -23.2962646484375, + 36.8623046875 + ], + [ + -3.4830322265625, + 59.561767578125 + ], + [ + 29.205810546875, + 62.78338623046875 + ], + [ + 49.1898193359375, + 49.74090576171875 + ], + [ + 45.6522216796875, + 21.439453125 + ], + [ + 24.2618408203125, + 1.5714111328125 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "vP9i2PUtjapBX142LXX7m", + "type": "draw", + "x": 552.87939453125, + "y": 504.59832763671875, + "width": 16.5072021484375, + "height": 18.1295166015625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#15aabf", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 786227753, + "version": 48, + "versionNonce": 2144487561, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.4810791015625, + -18.1295166015625 + ], + [ + 16.5072021484375, + -13.106201171875 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "2XUWMZRUNlhKGsJGNjK9k", + "type": "text", + "x": 154.5665283203125, + "y": 450.849365234375, + "width": 258, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 826013511, + "version": 1180, + "versionNonce": 1404772487, + "isDeleted": false, + "boundElementIds": null, + "text": "10. Return the scan result", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + } + ], + "appState": { + "gridSize": null, + "viewBackgroundColor": "#ffffff" + } +} \ No newline at end of file diff --git a/v0.25.4/imgs/excalidraw/fs.excalidraw b/v0.25.4/imgs/excalidraw/fs.excalidraw new file mode 100644 index 0000000000..bd97566531 --- /dev/null +++ b/v0.25.4/imgs/excalidraw/fs.excalidraw @@ -0,0 +1,397 @@ +{ + "type": "excalidraw", + "version": 2, + "source": "https://excalidraw.com", + "elements": [ + { + "id": "ribsikcWWSf8Aw4M6BOYJ", + "type": "rectangle", + "x": 528.53466796875, + "y": 377.9640197753906, + "width": 169.21945190429688, + "height": 104.2457275390625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 698826281, + "version": 274, + "versionNonce": 942385065, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo" + ] + }, + { + "id": "GkrbG--OvBT9zJ-w8E5oQ", + "type": "ellipse", + "x": 496.9409637451172, + "y": 63.6944580078125, + "width": 215.20677185058594, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 995070601, + "version": 595, + "versionNonce": 1870840679, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY" + ] + }, + { + "id": "KPLvdnBVoU3U5XGhCch-x", + "type": "text", + "x": 585.4711608886719, + "y": 418.1110534667969, + "width": 48, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 938497417, + "version": 119, + "versionNonce": 1368050313, + "isDeleted": false, + "boundElementIds": null, + "text": "Trivy", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "Ry65W-Cczzy8M9JsouEgZ", + "type": "text", + "x": 558.5760498046875, + "y": 114.79718017578125, + "width": 89, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1676815783, + "version": 368, + "versionNonce": 2034482823, + "isDeleted": false, + "boundElementIds": null, + "text": "GitHub\n(trivy-db)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "eJn9MVaNlcyj8-YPfrBSY", + "type": "arrow", + "x": 608.6504180950899, + "y": 218.69285081443215, + "width": 0.45618097890837817, + "height": 154.16252445127046, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1741763111, + "version": 1069, + "versionNonce": 2093125993, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.45618097890837817, + 154.16252445127046 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "GkrbG--OvBT9zJ-w8E5oQ", + "focus": -0.035986229233252585, + "gap": 2.9120411440381986 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -0.04563780983822369, + "gap": 5.10864450968802 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "2P02jU3j2eEc92lH0YSwm", + "type": "text", + "x": 637.9371185302734, + "y": 248.28482055664062, + "width": 327, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 501371753, + "version": 360, + "versionNonce": 326653351, + "isDeleted": false, + "boundElementIds": null, + "text": "1. Download Trivy DB\n(including vulnerability information)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "zdNQvzJczyD9GSExNdKS1", + "type": "draw", + "x": 513.9153137207031, + "y": 461.14288330078125, + "width": 72.64572143554688, + "height": 72.18890380859375, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1270145927, + "version": 459, + "versionNonce": 1094761993, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -39.526153564453125, + 16.35540771484375 + ], + [ + -32.219512939453125, + 72.170166015625 + ], + [ + 30.40386962890625, + 72.18890380859375 + ], + [ + 33.11956787109375, + 32.5743408203125 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "YK7xYiSKb1RwCCobsRAXm", + "type": "text", + "x": 391.5774230957031, + "y": 541.0142517089844, + "width": 280, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 2027931817, + "version": 510, + "versionNonce": 1538345895, + "isDeleted": false, + "boundElementIds": null, + "text": "3. Traverse directories\nand look for necessary files", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "Z_DiM_TKY2bBa4Q5VEWgI", + "type": "text", + "x": 684.9671020507812, + "y": 621.1561279296875, + "width": 160, + "height": 25, + "angle": 0, + "strokeColor": "#1864ab", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1365660617, + "version": 564, + "versionNonce": 2113117703, + "isDeleted": false, + "boundElementIds": null, + "text": "Local Filesystem", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "kqEATPhet5tYxzkEOFZng", + "type": "text", + "x": 571.0751342773438, + "y": 494.0994567871094, + "width": 254, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 130557095, + "version": 654, + "versionNonce": 2037434313, + "isDeleted": false, + "boundElementIds": null, + "text": "4. Detect security issues", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "K0XdIaMYVmUP2kGc8Oe1O", + "type": "rectangle", + "x": 360.9377136230469, + "y": 357.07373046875, + "width": 495.45401000976557, + "height": 297.8450317382812, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1367853545, + "version": 339, + "versionNonce": 314224297, + "isDeleted": false, + "boundElementIds": null + }, + { + "id": "_vOsyHICDRWn01MF3g7rB", + "type": "draw", + "x": 539.7380981445312, + "y": 501.50762939453125, + "width": 16.976165771484375, + "height": 16.45367431640625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1322966281, + "version": 82, + "versionNonce": 244034663, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 6.905059814453125, + -16.45367431640625 + ], + [ + 16.976165771484375, + -5.1099853515625 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + } + ], + "appState": { + "gridSize": null, + "viewBackgroundColor": "#ffffff" + } +} \ No newline at end of file diff --git a/v0.25.4/imgs/excalidraw/image.excalidraw b/v0.25.4/imgs/excalidraw/image.excalidraw new file mode 100644 index 0000000000..005aa44462 --- /dev/null +++ b/v0.25.4/imgs/excalidraw/image.excalidraw @@ -0,0 +1,504 @@ +{ + "type": "excalidraw", + "version": 2, + "source": "https://excalidraw.com", + "elements": [ + { + "id": "ribsikcWWSf8Aw4M6BOYJ", + "type": "rectangle", + "x": 528.53466796875, + "y": 359.7196350097656, + "width": 169.21945190429688, + "height": 104.2457275390625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 698826281, + "version": 235, + "versionNonce": 865905065, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo" + ] + }, + { + "id": "GkrbG--OvBT9zJ-w8E5oQ", + "type": "ellipse", + "x": 382.4654998779297, + "y": 70.28388977050781, + "width": 215.20677185058594, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 995070601, + "version": 442, + "versionNonce": 1305668297, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY" + ] + }, + { + "id": "KPLvdnBVoU3U5XGhCch-x", + "type": "text", + "x": 585.4711608886719, + "y": 399.8666687011719, + "width": 48, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 938497417, + "version": 82, + "versionNonce": 463601353, + "isDeleted": false, + "boundElementIds": null, + "text": "Trivy", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "Ry65W-Cczzy8M9JsouEgZ", + "type": "text", + "x": 445.5017395019531, + "y": 121.72871398925781, + "width": 89, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1676815783, + "version": 306, + "versionNonce": 1721298503, + "isDeleted": false, + "boundElementIds": null, + "text": "GitHub\n(trivy-db)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "eJn9MVaNlcyj8-YPfrBSY", + "type": "arrow", + "x": 497.981827043938, + "y": 226.98470679602065, + "width": 90.39040277767413, + "height": 127.08286800676547, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1741763111, + "version": 591, + "versionNonce": 1564262983, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 90.39040277767413, + 127.08286800676547 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "GkrbG--OvBT9zJ-w8E5oQ", + "focus": 0.41046776258752976, + "gap": 4.7596344319156 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": 0.1341309277800711, + "gap": 5.652060206979513 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "2P02jU3j2eEc92lH0YSwm", + "type": "text", + "x": 181.22366333007812, + "y": 252.094970703125, + "width": 327, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 501371753, + "version": 281, + "versionNonce": 1175555431, + "isDeleted": false, + "boundElementIds": null, + "text": "1. Download Trivy DB\n(including vulnerability information)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "P3WUTj2Q9se-JE7t3AUeq", + "type": "ellipse", + "x": 635.5376052856445, + "y": 68.77783966064453, + "width": 286.11024475097656, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#228be6", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1633931305, + "version": 684, + "versionNonce": 1011691465, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo" + ] + }, + { + "id": "2q_e-oMWU2gv7ZEClixAx", + "type": "text", + "x": 680.7248458862305, + "y": 102.90502166748047, + "width": 186, + "height": 74, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 866083559, + "version": 676, + "versionNonce": 1669555559, + "isDeleted": false, + "boundElementIds": null, + "text": "Container Registry\nor\nContainer Engine", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 67 + }, + { + "id": "JinTKutXOSTzURP969rwo", + "type": "arrow", + "x": 725.3393330640303, + "y": 216.94283962355922, + "width": 69.9915382406898, + "height": 134.02688987715163, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1348821927, + "version": 938, + "versionNonce": 1580551495, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -69.9915382406898, + 134.02688987715163 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "P3WUTj2Q9se-JE7t3AUeq", + "focus": 0.10510087993199528, + "gap": 1.4587528984692284 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": 0.0931277668871816, + "gap": 8.74990550905477 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "kHnEt-AjbEzMxB61VSDc2", + "type": "text", + "x": 723.4168395996094, + "y": 258.063232421875, + "width": 295, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1080814281, + "version": 613, + "versionNonce": 1064224615, + "isDeleted": false, + "boundElementIds": null, + "text": "2. Pull missing layers in cache", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "zdNQvzJczyD9GSExNdKS1", + "type": "draw", + "x": 524.4000854492188, + "y": 435.25982666015625, + "width": 72.64572143554688, + "height": 72.18890380859375, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1270145927, + "version": 331, + "versionNonce": 1090245193, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -39.526153564453125, + 16.35540771484375 + ], + [ + -32.219512939453125, + 72.170166015625 + ], + [ + 30.40386962890625, + 72.18890380859375 + ], + [ + 33.11956787109375, + 32.5743408203125 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "13A9Y6sL_9DQ1KskiX5Oj", + "type": "draw", + "x": 545.8597412109375, + "y": 483.20318603515625, + "width": 25.76263427734375, + "height": 16.2581787109375, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 788909033, + "version": 85, + "versionNonce": 991433415, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 13.24993896484375, + -16.2581787109375 + ], + [ + 25.76263427734375, + -5.01812744140625 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "YK7xYiSKb1RwCCobsRAXm", + "type": "text", + "x": 261.88555908203125, + "y": 379.65887451171875, + "width": 249, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 2027931817, + "version": 255, + "versionNonce": 809279785, + "isDeleted": false, + "boundElementIds": null, + "text": "3. Analyze layers &\nStore informatin in cache", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "Z_DiM_TKY2bBa4Q5VEWgI", + "type": "text", + "x": 404.58673095703125, + "y": 522.828125, + "width": 144, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1365660617, + "version": 327, + "versionNonce": 2016944615, + "isDeleted": false, + "boundElementIds": null, + "text": "4. Apply layers", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "kqEATPhet5tYxzkEOFZng", + "type": "text", + "x": 598.8711547851562, + "y": 480.22222900390625, + "width": 257, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 130557095, + "version": 539, + "versionNonce": 562048487, + "isDeleted": false, + "boundElementIds": null, + "text": "5. Detect security issues", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + } + ], + "appState": { + "gridSize": null, + "viewBackgroundColor": "#ffffff" + } +} \ No newline at end of file diff --git a/v0.25.4/imgs/excalidraw/misconf.excalidraw b/v0.25.4/imgs/excalidraw/misconf.excalidraw new file mode 100644 index 0000000000..ea489369dc --- /dev/null +++ b/v0.25.4/imgs/excalidraw/misconf.excalidraw @@ -0,0 +1,352 @@ +{ + "type": "excalidraw", + "version": 2, + "source": "https://excalidraw.com", + "elements": [ + { + "type": "rectangle", + "version": 573, + "versionNonce": 2034670720, + "isDeleted": false, + "id": "BkXuq_6BxgqZGZWc8oCtu", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 599.211669921875, + "y": 376.32061767578125, + "strokeColor": "#000000", + "backgroundColor": "#fd7e14", + "width": 867.8921508789062, + "height": 151.39703369140625, + "seed": 1632394695, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 572, + "versionNonce": 425683840, + "isDeleted": false, + "id": "YQURTHNPSe05RPSlYRcok", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 983.89404296875, + "y": 399.98724365234375, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 88, + "height": 45, + "seed": 891391049, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 36, + "fontFamily": 1, + "text": "Trivy", + "baseline": 32, + "textAlign": "left", + "verticalAlign": "top" + }, + { + "type": "text", + "version": 822, + "versionNonce": 1061096576, + "isDeleted": false, + "id": "6dpF2EyZBtYgO6MrvGj0-", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 771.2554931640625, + "y": 469.7777099609375, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 507, + "height": 35, + "seed": 687997545, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Vulnerability/Misconfiguration Scanner", + "baseline": 25, + "textAlign": "left", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 763, + "versionNonce": 560331648, + "isDeleted": false, + "id": "cpnTMy7L2AUg9IDJppF4H", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 602.28369140625, + "y": 258.8445587158203, + "strokeColor": "#000000", + "backgroundColor": "#fab005", + "width": 397.493408203125, + "height": 103.28388977050778, + "seed": 77164935, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 1072, + "versionNonce": 212434048, + "isDeleted": false, + "id": "9-blmNVtLesthMSY_f60t", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 630.9301147460938, + "y": 292.4002990722656, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 331, + "height": 35, + "seed": 860091815, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Infrastructure as Code", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 1194, + "versionNonce": 131337088, + "isDeleted": false, + "id": "gugZxhi7ThlcjWY_MFO7q", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1021.5928955078125, + "y": 261.56090545654297, + "strokeColor": "#000000", + "backgroundColor": "#be4bdb", + "width": 441.0702514648438, + "height": 99.05134582519533, + "seed": 1232790121, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 1270, + "versionNonce": 591785088, + "isDeleted": false, + "id": "K48gtpesBxIGJxLTnI2CB", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1173.3179931640625, + "y": 294.12510681152344, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 137, + "height": 35, + "seed": 449264361, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Filesystem", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 1319, + "versionNonce": 1264839808, + "isDeleted": false, + "id": "BYJwfkhd1BilbLQGc973f", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1233.3157348632812, + "y": 168.29967880249023, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 229.03393554687523, + "height": 77.80606079101562, + "seed": 1923498546, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 659, + "versionNonce": 2122259328, + "isDeleted": false, + "id": "eedUyCpr8i1aY_3PHsHAB", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1241.1352844238281, + "y": 191.2939567565918, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 216, + "height": 35, + "seed": 595309038, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Misconfiguration", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "middle" + }, + { + "type": "rectangle", + "version": 1397, + "versionNonce": 20077696, + "isDeleted": false, + "id": "SPkrBrH6DGvkgQXtZQjIJ", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1023.8157043457031, + "y": 168.7816276550293, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "width": 200.7496337890626, + "height": 77.80606079101562, + "seed": 1896460914, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 840, + "versionNonce": 655338368, + "isDeleted": false, + "id": "n06MNIqirDmVZBkDg_UPV", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1040.526611328125, + "y": 194.3111228942871, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 160, + "height": 35, + "seed": 1131832750, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Vulnerability", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "middle" + }, + { + "type": "rectangle", + "version": 1441, + "versionNonce": 1393118080, + "isDeleted": false, + "id": "8SHSNGf7PNddFLi2ZA3Vi", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 673.6463928222656, + "y": 167.8159294128418, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 278.48516845703136, + "height": 77.80606079101562, + "seed": 1986948530, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 851, + "versionNonce": 2114620544, + "isDeleted": false, + "id": "3Z5w3RXdgpvP43dlHqq26", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 701.5146789550781, + "y": 189.60757064819336, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 216, + "height": 35, + "seed": 1077804654, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Misconfiguration", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "middle" + } + ], + "appState": { + "gridSize": null, + "viewBackgroundColor": "#ffffff" + } +} \ No newline at end of file diff --git a/v0.25.4/imgs/excalidraw/overview.excalidraw b/v0.25.4/imgs/excalidraw/overview.excalidraw new file mode 100644 index 0000000000..71b042667e --- /dev/null +++ b/v0.25.4/imgs/excalidraw/overview.excalidraw @@ -0,0 +1,508 @@ +{ + "type": "excalidraw", + "version": 2, + "source": "https://excalidraw.com", + "elements": [ + { + "type": "rectangle", + "version": 476, + "versionNonce": 916788210, + "isDeleted": false, + "id": "BkXuq_6BxgqZGZWc8oCtu", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 599.211669921875, + "y": 376.32061767578125, + "strokeColor": "#000000", + "backgroundColor": "#fd7e14", + "width": 1076.4584350585938, + "height": 151.39703369140625, + "seed": 1632394695, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 423, + "versionNonce": 931200686, + "isDeleted": false, + "id": "YQURTHNPSe05RPSlYRcok", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1119.1937866210938, + "y": 403.56756591796875, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 88, + "height": 45, + "seed": 891391049, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 36, + "fontFamily": 1, + "text": "Trivy", + "baseline": 32, + "textAlign": "left", + "verticalAlign": "top" + }, + { + "type": "text", + "version": 758, + "versionNonce": 813811122, + "isDeleted": false, + "id": "6dpF2EyZBtYgO6MrvGj0-", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 922.1328735351562, + "y": 470.18975830078125, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 507, + "height": 35, + "seed": 687997545, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Vulnerability/Misconfiguration Scanner", + "baseline": 25, + "textAlign": "left", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 595, + "versionNonce": 1705780846, + "isDeleted": false, + "id": "cpnTMy7L2AUg9IDJppF4H", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 597.4796142578125, + "y": 258.9286651611328, + "strokeColor": "#000000", + "backgroundColor": "#fab005", + "width": 349.1224975585937, + "height": 103.28388977050778, + "seed": 77164935, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 921, + "versionNonce": 929185650, + "isDeleted": false, + "id": "9-blmNVtLesthMSY_f60t", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 655.6057739257812, + "y": 292.4844055175781, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 238, + "height": 35, + "seed": 860091815, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Container Images", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 853, + "versionNonce": 377039022, + "isDeleted": false, + "id": "gugZxhi7ThlcjWY_MFO7q", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 955.929443359375, + "y": 262.11351776123047, + "strokeColor": "#000000", + "backgroundColor": "#be4bdb", + "width": 359.85211181640625, + "height": 99.05134582519533, + "seed": 1232790121, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 1065, + "versionNonce": 126714162, + "isDeleted": false, + "id": "K48gtpesBxIGJxLTnI2CB", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1064.449462890625, + "y": 296.9230194091797, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 137, + "height": 35, + "seed": 449264361, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Filesystem", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 896, + "versionNonce": 585884398, + "isDeleted": false, + "id": "La6f87LDZ0uEIZB947bXo", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1329.0839233398438, + "y": 264.9097213745117, + "strokeColor": "#000000", + "backgroundColor": "#12b886", + "width": 346.5517578125, + "height": 96.3990020751953, + "seed": 2005637801, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 1186, + "versionNonce": 1013615346, + "isDeleted": false, + "id": "aOgRPVQ81jhOfkvzjWTMF", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1392.300048828125, + "y": 294.1288604736328, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "width": 223, + "height": 35, + "seed": 1284472935, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Git Repositories", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "top" + }, + { + "type": "rectangle", + "version": 974, + "versionNonce": 1011959534, + "isDeleted": false, + "id": "BYJwfkhd1BilbLQGc973f", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1141.5093994140625, + "y": 171.09759140014648, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 169.93957519531259, + "height": 77.80606079101562, + "seed": 1923498546, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 403, + "versionNonce": 1635608306, + "isDeleted": false, + "id": "eedUyCpr8i1aY_3PHsHAB", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1149.8379821777344, + "y": 197.31159591674805, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 155, + "height": 25, + "seed": 595309038, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 20, + "fontFamily": 1, + "text": "Misconfiguration", + "baseline": 18, + "textAlign": "center", + "verticalAlign": "middle" + }, + { + "type": "rectangle", + "version": 1035, + "versionNonce": 1646453614, + "isDeleted": false, + "id": "SPkrBrH6DGvkgQXtZQjIJ", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 959.9851989746094, + "y": 170.4835319519043, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "width": 169.93957519531259, + "height": 77.80606079101562, + "seed": 1896460914, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 532, + "versionNonce": 1887556210, + "isDeleted": false, + "id": "n06MNIqirDmVZBkDg_UPV", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 988.8137817382812, + "y": 196.69753646850586, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 114, + "height": 25, + "seed": 1131832750, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 20, + "fontFamily": 1, + "text": "Vulnerability", + "baseline": 18, + "textAlign": "center", + "verticalAlign": "middle" + }, + { + "type": "rectangle", + "version": 1072, + "versionNonce": 789595566, + "isDeleted": false, + "id": "0JP6OL7EFfoH4E4vFARFl", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1508.9087371826172, + "y": 170.7038917541504, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 169.93957519531259, + "height": 77.80606079101562, + "seed": 101784622, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 496, + "versionNonce": 1027781682, + "isDeleted": false, + "id": "jRmlh5MZuRKm3FtbC6qdZ", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1517.237319946289, + "y": 196.91789627075195, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 155, + "height": 25, + "seed": 1950385586, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 20, + "fontFamily": 1, + "text": "Misconfiguration", + "baseline": 18, + "textAlign": "center", + "verticalAlign": "middle" + }, + { + "type": "rectangle", + "version": 1133, + "versionNonce": 882335726, + "isDeleted": false, + "id": "EQRF92xU4o9CfeHHvbd-a", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1327.384536743164, + "y": 170.0898323059082, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "width": 169.93957519531259, + "height": 77.80606079101562, + "seed": 1379493486, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 569, + "versionNonce": 184638962, + "isDeleted": false, + "id": "_04YR8geM-ar9vZhNZtSj", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 1356.213119506836, + "y": 196.30383682250977, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 114, + "height": 25, + "seed": 357105522, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 20, + "fontFamily": 1, + "text": "Vulnerability", + "baseline": 18, + "textAlign": "center", + "verticalAlign": "middle" + }, + { + "type": "rectangle", + "version": 1215, + "versionNonce": 650195502, + "isDeleted": false, + "id": "8SHSNGf7PNddFLi2ZA3Vi", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 599.9767150878906, + "y": 169.0025749206543, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "width": 344.1738281250001, + "height": 77.80606079101562, + "seed": 1986948530, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [] + }, + { + "type": "text", + "version": 680, + "versionNonce": 113561522, + "isDeleted": false, + "id": "3Z5w3RXdgpvP43dlHqq26", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "angle": 0, + "x": 700.3721618652344, + "y": 190.79421615600586, + "strokeColor": "#000000", + "backgroundColor": "#82c91e", + "width": 160, + "height": 35, + "seed": 1077804654, + "groupIds": [], + "strokeSharpness": "sharp", + "boundElementIds": [], + "fontSize": 28, + "fontFamily": 1, + "text": "Vulnerability", + "baseline": 25, + "textAlign": "center", + "verticalAlign": "middle" + } + ], + "appState": { + "gridSize": null, + "viewBackgroundColor": "#ffffff" + } +} \ No newline at end of file diff --git a/v0.25.4/imgs/excalidraw/repo.excalidraw b/v0.25.4/imgs/excalidraw/repo.excalidraw new file mode 100644 index 0000000000..72fcf1b479 --- /dev/null +++ b/v0.25.4/imgs/excalidraw/repo.excalidraw @@ -0,0 +1,631 @@ +{ + "type": "excalidraw", + "version": 2, + "source": "https://excalidraw.com", + "elements": [ + { + "id": "ribsikcWWSf8Aw4M6BOYJ", + "type": "rectangle", + "x": 458.6370544433594, + "y": 379.5105285644531, + "width": 169.21945190429688, + "height": 104.2457275390625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 698826281, + "version": 360, + "versionNonce": 899087049, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo", + "nXkZQsrtjmNqPM6SmPxrc" + ] + }, + { + "id": "GkrbG--OvBT9zJ-w8E5oQ", + "type": "ellipse", + "x": 427.04335021972656, + "y": 65.240966796875, + "width": 215.20677185058594, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#fa5252", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 995070601, + "version": 679, + "versionNonce": 1333899847, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY" + ] + }, + { + "id": "KPLvdnBVoU3U5XGhCch-x", + "type": "text", + "x": 515.5735473632812, + "y": 419.6575622558594, + "width": 48, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 938497417, + "version": 202, + "versionNonce": 677296553, + "isDeleted": false, + "boundElementIds": null, + "text": "Trivy", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "Ry65W-Cczzy8M9JsouEgZ", + "type": "text", + "x": 488.6784362792969, + "y": 116.34368896484375, + "width": 89, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1676815783, + "version": 451, + "versionNonce": 490852711, + "isDeleted": false, + "boundElementIds": null, + "text": "GitHub\n(trivy-db)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "eJn9MVaNlcyj8-YPfrBSY", + "type": "arrow", + "x": 538.7528045696993, + "y": 220.23935960349465, + "width": 0.45618097890837817, + "height": 154.16252445127046, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1741763111, + "version": 1292, + "versionNonce": 764124297, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.45618097890837817, + 154.16252445127046 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "GkrbG--OvBT9zJ-w8E5oQ", + "focus": -0.03598869040285281, + "gap": 2.911871895302724 + }, + "endBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -0.04563780983822428, + "gap": 5.10864450968802 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "2P02jU3j2eEc92lH0YSwm", + "type": "text", + "x": 190.61294555664062, + "y": 255.17030334472656, + "width": 327, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 501371753, + "version": 569, + "versionNonce": 2012286087, + "isDeleted": false, + "boundElementIds": null, + "text": "1. Download Trivy DB\n(including vulnerability information)", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "YK7xYiSKb1RwCCobsRAXm", + "type": "text", + "x": 588.7474975585938, + "y": 488.1255798339844, + "width": 280, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 2027931817, + "version": 628, + "versionNonce": 30461609, + "isDeleted": false, + "boundElementIds": null, + "text": "3. Traverse directories\nand look for necessary files", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "Z_DiM_TKY2bBa4Q5VEWgI", + "type": "text", + "x": 877.162353515625, + "y": 618.5094604492188, + "width": 160, + "height": 25, + "angle": 0, + "strokeColor": "#1864ab", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1365660617, + "version": 647, + "versionNonce": 760156423, + "isDeleted": false, + "boundElementIds": null, + "text": "Local Filesystem", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + }, + { + "id": "K0XdIaMYVmUP2kGc8Oe1O", + "type": "rectangle", + "x": 360.9377136230469, + "y": 357.07373046875, + "width": 695.5669860839844, + "height": 297.8450317382812, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1367853545, + "version": 417, + "versionNonce": 1598611913, + "isDeleted": false, + "boundElementIds": null + }, + { + "id": "9cBakj4Z-FKXwYYdweyW1", + "type": "ellipse", + "x": 774.155647277832, + "y": 56.2083175778389, + "width": 215.20677185058594, + "height": 152.14088439941406, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#4c6ef5", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1010956009, + "version": 673, + "versionNonce": 825999529, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "vGa683rpZ9AztfvrVvEyD" + ] + }, + { + "id": "5y2AKGYkXhCldwQOecwl6", + "type": "text", + "x": 806.7732543945312, + "y": 106.18511658906937, + "width": 147, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1289267591, + "version": 83, + "versionNonce": 1127203721, + "isDeleted": false, + "boundElementIds": null, + "text": "Remote\nGit Repository", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "vGa683rpZ9AztfvrVvEyD", + "type": "arrow", + "x": 884.4609964246083, + "y": 220.86864013003574, + "width": 0.45618097890837817, + "height": 154.16252445127046, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1762737031, + "version": 1200, + "versionNonce": 457627015, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 0.45618097890837817, + 154.16252445127046 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "9cBakj4Z-FKXwYYdweyW1", + "focus": -0.022674122391029432, + "gap": 12.541597764893623 + }, + "endBinding": { + "elementId": "4_okkFmweGK_2DBTmRp4i", + "focus": 0.047202684587572305, + "gap": 3.295263653270979 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "4_okkFmweGK_2DBTmRp4i", + "type": "rectangle", + "x": 796.4703521728516, + "y": 378.3264282345772, + "width": 169.21945190429688, + "height": 104.2457275390625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "#4c6ef5", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 853231143, + "version": 387, + "versionNonce": 1096837737, + "isDeleted": false, + "boundElementIds": [ + "eJn9MVaNlcyj8-YPfrBSY", + "JinTKutXOSTzURP969rwo", + "vGa683rpZ9AztfvrVvEyD", + "nXkZQsrtjmNqPM6SmPxrc" + ] + }, + { + "id": "zvgwnUmSms_XcbMDespIP", + "type": "text", + "x": 847.181640625, + "y": 404.5675476193428, + "width": 72, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1769283399, + "version": 307, + "versionNonce": 1392544935, + "isDeleted": false, + "boundElementIds": null, + "text": "Git\nProject", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "center", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "f0kayc0oXZazxPJKizaM1", + "type": "text", + "x": 916.8968811035156, + "y": 253.85886842012405, + "width": 258, + "height": 50, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 49135625, + "version": 649, + "versionNonce": 1150891337, + "isDeleted": false, + "boundElementIds": null, + "text": "2. Clone Git Repository\n to local temp directory", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 43 + }, + { + "id": "nXkZQsrtjmNqPM6SmPxrc", + "type": "arrow", + "x": 640.9059448242188, + "y": 429.34260255098343, + "width": 146.4581298828125, + "height": 0.93572998046875, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 2075020231, + "version": 93, + "versionNonce": 1421238215, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 146.4581298828125, + -0.93572998046875 + ] + ], + "lastCommittedPoint": null, + "startBinding": { + "elementId": "ribsikcWWSf8Aw4M6BOYJ", + "focus": -0.031650787945314215, + "gap": 13.0494384765625 + }, + "endBinding": { + "elementId": "4_okkFmweGK_2DBTmRp4i", + "focus": 0.050151997400131744, + "gap": 9.106277465820312 + }, + "startArrowhead": null, + "endArrowhead": "arrow" + }, + { + "id": "OPRFQTrsfmF5a7us-mxkI", + "type": "draw", + "x": 446.98912048339844, + "y": 467.28928834199905, + "width": 72.64572143554688, + "height": 72.18890380859375, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 1541066697, + "version": 504, + "versionNonce": 1115999975, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + -39.526153564453125, + 16.35540771484375 + ], + [ + -32.219512939453125, + 72.170166015625 + ], + [ + 30.40386962890625, + 72.18890380859375 + ], + [ + 33.11956787109375, + 32.5743408203125 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "QzKnYI7o5Yxg_7szebL6Z", + "type": "draw", + "x": 472.81190490722656, + "y": 507.65403443574905, + "width": 16.976165771484375, + "height": 16.45367431640625, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "round", + "seed": 2144447815, + "version": 127, + "versionNonce": 807483145, + "isDeleted": false, + "boundElementIds": null, + "points": [ + [ + 0, + 0 + ], + [ + 6.905059814453125, + -16.45367431640625 + ], + [ + 16.976165771484375, + -5.1099853515625 + ] + ], + "lastCommittedPoint": null, + "startBinding": null, + "endBinding": null, + "startArrowhead": null, + "endArrowhead": null + }, + { + "id": "qqbEan2u1uU3loTdTvQ4B", + "type": "text", + "x": 376.983642578125, + "y": 561.5254028439522, + "width": 254, + "height": 25, + "angle": 0, + "strokeColor": "#000000", + "backgroundColor": "transparent", + "fillStyle": "hachure", + "strokeWidth": 1, + "strokeStyle": "solid", + "roughness": 1, + "opacity": 100, + "groupIds": [], + "strokeSharpness": "sharp", + "seed": 1619652615, + "version": 718, + "versionNonce": 1190681095, + "isDeleted": false, + "boundElementIds": null, + "text": "4. Detect security issues", + "fontSize": 20, + "fontFamily": 1, + "textAlign": "left", + "verticalAlign": "top", + "baseline": 18 + } + ], + "appState": { + "gridSize": null, + "viewBackgroundColor": "#ffffff" + } +} \ No newline at end of file diff --git a/v0.25.4/imgs/fs.png b/v0.25.4/imgs/fs.png new file mode 100644 index 0000000000..2a6acb83d0 Binary files /dev/null and b/v0.25.4/imgs/fs.png differ diff --git a/v0.25.4/imgs/gitlab-codequality.png b/v0.25.4/imgs/gitlab-codequality.png new file mode 100644 index 0000000000..b7069b8af7 Binary files /dev/null and b/v0.25.4/imgs/gitlab-codequality.png differ diff --git a/v0.25.4/imgs/image.png b/v0.25.4/imgs/image.png new file mode 100644 index 0000000000..e014f0c7b6 Binary files /dev/null and b/v0.25.4/imgs/image.png differ diff --git a/v0.25.4/imgs/logo-horizontal.svg b/v0.25.4/imgs/logo-horizontal.svg new file mode 100644 index 0000000000..fb169f58c8 --- /dev/null +++ b/v0.25.4/imgs/logo-horizontal.svg @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/v0.25.4/imgs/logo-white.svg b/v0.25.4/imgs/logo-white.svg new file mode 100644 index 0000000000..4aa8d97280 --- /dev/null +++ b/v0.25.4/imgs/logo-white.svg @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/v0.25.4/imgs/logo.png b/v0.25.4/imgs/logo.png new file mode 100644 index 0000000000..3048e8ce67 Binary files /dev/null and b/v0.25.4/imgs/logo.png differ diff --git a/v0.25.4/imgs/misconf-demo.gif b/v0.25.4/imgs/misconf-demo.gif new file mode 100644 index 0000000000..10c25e814f Binary files /dev/null and b/v0.25.4/imgs/misconf-demo.gif differ diff --git a/v0.25.4/imgs/misconf.png b/v0.25.4/imgs/misconf.png new file mode 100644 index 0000000000..2b52ceff00 Binary files /dev/null and b/v0.25.4/imgs/misconf.png differ diff --git a/v0.25.4/imgs/overview.png b/v0.25.4/imgs/overview.png new file mode 100644 index 0000000000..a73bb64922 Binary files /dev/null and b/v0.25.4/imgs/overview.png differ diff --git a/v0.25.4/imgs/repo.png b/v0.25.4/imgs/repo.png new file mode 100644 index 0000000000..80b80689d0 Binary files /dev/null and b/v0.25.4/imgs/repo.png differ diff --git a/v0.25.4/imgs/vuln-demo.gif b/v0.25.4/imgs/vuln-demo.gif new file mode 100644 index 0000000000..f48a93e904 Binary files /dev/null and b/v0.25.4/imgs/vuln-demo.gif differ diff --git a/v0.25.4/imgs/vulnerability.png b/v0.25.4/imgs/vulnerability.png new file mode 100644 index 0000000000..0c197103c2 Binary files /dev/null and b/v0.25.4/imgs/vulnerability.png differ diff --git a/v0.25.4/index.html b/v0.25.4/index.html new file mode 100644 index 0000000000..033f8b39ce --- /dev/null +++ b/v0.25.4/index.html @@ -0,0 +1,3039 @@ + + + + + + + + + + + + + + + + + + + + + + + Trivy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ +
+ + + + + + + + +
+ + + + + + + +
+ +
+ + + + +
+
+ + + + + + + + + + + + + + +
+
+ + + + +

logo

+

Trivy (tri pronounced like trigger, vy pronounced like envy) is a simple and comprehensive vulnerability/misconfiguration scanner for containers and other artifacts. +A software vulnerability is a glitch, flaw, or weakness present in the software or in an Operating System. +Trivy detects vulnerabilities of OS packages (Alpine, RHEL, CentOS, etc.) and language-specific packages (Bundler, Composer, npm, yarn, etc.). +In addition, Trivy scans Infrastructure as Code (IaC) files such as Terraform and Kubernetes, to detect potential configuration issues that expose your deployments to the risk of attack. +Trivy is easy to use. Just install the binary and you're ready to scan. +All you need to do for scanning is to specify a target such as an image name of the container.

+
+ +
+ +
+

Demo

+
+ +
+ +
Demo: Vulnerability Detection
+
+ +
+ +
Demo: Misconfiguration Detection
+
+ +
+

Trivy is an Aqua Security open source project.
+Learn about our open source work and portfolio here.
+Contact us about any matter by opening a GitHub Discussion here

+ + + + + + + +
+ +
+
+ +
+ + + +
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/v0.25.4/search/search_index.json b/v0.25.4/search/search_index.json new file mode 100644 index 0000000000..34cebb5ba0 --- /dev/null +++ b/v0.25.4/search/search_index.json @@ -0,0 +1 @@ +{"config":{"indexing":"full","lang":["en"],"min_search_length":3,"prebuild_index":false,"separator":"[\\s\\-]+","tags":false},"docs":[{"location":"","text":"

Trivy (tri pronounced like trigger, vy pronounced like envy) is a simple and comprehensive vulnerability/misconfiguration scanner for containers and other artifacts. A software vulnerability is a glitch, flaw, or weakness present in the software or in an Operating System. Trivy detects vulnerabilities of OS packages (Alpine, RHEL, CentOS, etc.) and language-specific packages (Bundler, Composer, npm, yarn, etc.). In addition, Trivy scans Infrastructure as Code (IaC) files such as Terraform and Kubernetes, to detect potential configuration issues that expose your deployments to the risk of attack. Trivy is easy to use. Just install the binary and you're ready to scan. All you need to do for scanning is to specify a target such as an image name of the container.

","title":"HOME"},{"location":"#demo","text":"Demo: Vulnerability Detection Demo: Misconfiguration Detection

Trivy is an Aqua Security open source project. Learn about our open source work and portfolio here. Contact us about any matter by opening a GitHub Discussion here

","title":"Demo"},{"location":"community/cks/","text":"

Community Resources

  • Trivy Video overview (short)
  • Example questions from the exam
  • More example questions

Aqua Security Blog posts

  • Supply chain security best practices
  • Supply chain attacks
  • If you know of interesting resources, please start a PR to add those to the list.
","title":"CKS preparation resources"},{"location":"community/credit/","text":"

Teppei Fukuda (knqyf263)

","title":"Author"},{"location":"community/credit/#contributors","text":"

Thanks to all contributors

","title":"Contributors"},{"location":"community/references/","text":"

There are external blogs and evaluations.

","title":"Additional References"},{"location":"community/references/#blogs","text":"
  • Trivy Vulnerability Scanner Joins the Aqua Open-source Family
  • Trivy Image Vulnerability Scanner Now Under Apache 2.0 License
  • DevSecOps with Trivy and GitHub Actions
  • Find Image Vulnerabilities Using GitHub and Aqua Security Trivy Action
  • Using Trivy to Discover Vulnerabilities in VS Code Projects
  • the vulnerability remediation lifecycle of Alpine containers
  • Continuous Container Vulnerability Testing with Trivy
  • Open Source CVE Scanner Round-Up: Clair vs Anchore vs Trivy
  • Docker Image Security: Static Analysis Tool Comparison \u2013 Anchore Engine vs Clair vs Trivy
","title":"Blogs"},{"location":"community/references/#links","text":"
  • Research Spike: evaluate Trivy for scanning running containers
  • Istio evaluates scanners
","title":"Links"},{"location":"community/references/#presentations","text":"
  • Aqua Security YouTube Channel
    • Trivy - container image scanning
    • Using Trivy in client server mode
    • Tweaking Trivy output to fit your workflow
    • How does a vulnerability scanner identify packages?
  • CNCF Webinar 2020
    • Trivy Open Source Scanner for Container Images \u2013 Just Download and Run!
  • KubeCon + CloudNativeCon Europe 2020 Virtual
    • Handling Container Vulnerabilities with Open Policy Agent - Teppei Fukuda, Aqua Security
","title":"Presentations"},{"location":"community/tools/","text":"

The open source community has been hard at work developing new tools for Trivy. You can check out some of them here.

Have you created a tool that\u2019s not listed? Add the name and description of your integration and open a pull request in the GitHub repository to get your change merged.

","title":"Community Tools"},{"location":"community/tools/#github-actions","text":"Actions Description gitrivy GitHub Issue + Trivy trivy-github-issues GitHub Actions for creating GitHub Issues according to the Trivy scanning result","title":"GitHub Actions"},{"location":"community/tools/#semaphore","text":"Name Description Continuous Vulnerability Testing with Trivy Tutorial on scanning code, containers, infrastructure, and Kubernetes with Semaphore CI/CD.","title":"Semaphore"},{"location":"community/tools/#circleci","text":"Orb Description fifteen5/trivy-orb Orb for running Trivy, a security scanner","title":"CircleCI"},{"location":"community/tools/#others","text":"Name Description Trivy Vulnerability Explorer Explore trivy vulnerability reports in your browser and create .trivyignore files interactively. Can be integrated in your CI/CD tooling with deep links.","title":"Others"},{"location":"community/contribute/issue/","text":"

Thank you for taking interest in contributing to Trivy!

  • Feel free to open issues for any reason. When you open a new issue, you'll have to select an issue kind: bug/feature/support and fill the required information based on the selected template.
  • Please spend a small amount of time giving due diligence to the issue tracker. Your issue might be a duplicate. If it is, please add your comment to the existing issue.
  • Remember that users might search for your issue in the future, so please give it a meaningful title to help others.
  • The issue should clearly explain the reason for opening, the proposal if you have any, and any relevant technical information.
","title":"Issues"},{"location":"community/contribute/pr/","text":"

Thank you for taking interest in contributing to Trivy!

  1. Every Pull Request should have an associated bug or feature issue unless you are fixing a trivial documentation issue.
  2. Please add the associated Issue link in the PR description.
  3. Your PR is more likely to be accepted if it focuses on just one change.
  4. There's no need to add or tag reviewers.
  5. If a reviewer commented on your code or asked for changes, please remember to respond with comment. Do not mark discussion as resolved. It's up to reviewer to mark it resolved (in case if suggested fix addresses problem properly). PRs with unresolved issues should not be merged (even if the comment is unclear or requires no action from your side).
  6. Please include a comment with the results before and after your change.
  7. Your PR is more likely to be accepted if it includes tests (We have not historically been very strict about tests, but we would like to improve this!).
  8. If your PR affects the user experience in some way, please update the README.md and the CLI help accordingly.
","title":"Pull Requests"},{"location":"community/contribute/pr/#title","text":"

It is not that strict, but we use the title conventions in this repository. Each commit message doesn't have to follow the conventions as long as it is clear and descriptive since it will be squashed and merged.

","title":"Title"},{"location":"community/contribute/pr/#format-of-the-title","text":"
<type>(<scope>): <subject>\n

The type and scope should always be lowercase as shown below.

Allowed <type> values:

  • feat for a new feature for the user, not a new feature for build script. Such commit will trigger a release bumping a MINOR version.
  • fix for a bug fix for the user, not a fix to a build script. Such commit will trigger a release bumping a PATCH version.
  • perf for performance improvements. Such commit will trigger a release bumping a PATCH version.
  • docs for changes to the documentation.
  • style for formatting changes, missing semicolons, etc.
  • refactor for refactoring production code, e.g. renaming a variable.
  • test for adding missing tests, refactoring tests; no production code change.
  • build for updating build configuration, development tools or other changes irrelevant to the user.
  • chore for updates that do not apply to the above, such as dependency updates.

Example <scope> values:

  • alpine
  • redhat
  • ruby
  • python
  • terraform
  • report
  • etc.

The <scope> can be empty (e.g. if the change is a global or difficult to assign to a single component), in which case the parentheses are omitted.

","title":"Format of the title"},{"location":"community/contribute/pr/#example-titles","text":"
feat(alma): add support for AlmaLinux\n
fix(oracle): handle advisories with ksplice versions\n
docs(misconf): add comparison with Conftest and TFsec\n
chore(deps): bump go.uber.org/zap from 1.19.1 to 1.20.0\n

NOTE: please do not use chore(deps): update fanal and something like that if you add new features or fix bugs in Trivy-related projects. The PR title should describe what the PR adds or fixes even though it just updates the dependency in Trivy.

","title":"Example titles"},{"location":"community/contribute/pr/#unit-tests","text":"

Your PR must pass all the unit tests. You can test it as below.

$ make test\n
","title":"Unit tests"},{"location":"community/contribute/pr/#integration-tests","text":"

Your PR must pass all the integration tests. You can test it as below.

$ make test-integration\n
","title":"Integration tests"},{"location":"community/contribute/pr/#documentation","text":"

You can build the documents as below and view it at http://localhost:8000.

$ make mkdocs-serve\n
","title":"Documentation"},{"location":"community/contribute/pr/#understand-where-your-pull-request-belongs","text":"

Trivy is composed of several repositories that work together:

  • Trivy is the client-side, user-facing, command line tool.
  • vuln-list is a vulnerabilities database, aggregated from different sources, and normalized for easy consumption. Think of this as the \"server\" side of the trivy command line tool. There should be no pull requests to this repo
  • vuln-list-update is the code that maintains the vuln-list database.
  • trivy-db maintains the vulnerability database pulled by Trivy CLI.
  • fanal is a library for extracting system information from containers. It is being used by Trivy to find testable subjects in the container image.
  • go-dep-parser is a library for parsing lock files such as package-lock.json and Gemfile.lock.
","title":"Understand where your pull request belongs"},{"location":"community/maintainer/help-wanted/","text":"

We use two labels help wanted and good first issue to identify issues that have been specially groomed for new contributors. The good first issue label is a subset of help wanted label, indicating that members have committed to providing extra assistance for new contributors. All good first issue items also have the help wanted label.

","title":"Overview"},{"location":"community/maintainer/help-wanted/#help-wanted","text":"

Items marked with the help wanted label need to ensure that they are:

  • Low Barrier to Entry

It should be tractable for new contributors. Documentation on how that type of change should be made should already exist.

  • Clear Task

The task is agreed upon and does not require further discussions in the community. Call out if that area of code is untested and requires new fixtures.

API / CLI behavior is decided and included in the OP issue, for example: \"The new command syntax is trivy --format yaml IMAGE_NAME\"_ with expected validations called out.

  • Goldilocks priority

Not too high that a core contributor should do it, but not too low that it isn't useful enough for a core contributor to spend time to review it, answer questions, help get it into a release, etc.

  • Up-To-Date

Often these issues become obsolete and have already been done, are no longer desired, no longer make sense, have changed priority or difficulty , etc.

","title":"Help Wanted"},{"location":"community/maintainer/help-wanted/#good-first-issue","text":"

Items marked with the good first issue label are intended for first-time contributors. It indicates that members will keep an eye out for these pull requests and shepherd it through our processes.

These items need to ensure that they follow the guidelines for help wanted labels (above) in addition to meeting the following criteria:

  • No Barrier to Entry

The task is something that a new contributor can tackle without advanced setup, or domain knowledge.

  • Solution Explained

The recommended solution is clearly described in the issue.

  • Provides Context

If background knowledge is required, this should be explicitly mentioned and a list of suggested readings included.

  • Gives Examples

Link to examples of similar implementations so new contributors have a reference guide for their changes.

  • Identifies Relevant Code

The relevant code and tests to be changed should be linked in the issue.

  • Ready to Test

There should be existing tests that can be modified, or existing test cases fit to be copied. If the area of code doesn't have tests, before labeling the issue, add a test fixture. This prep often makes a great help wanted task!

","title":"Good First Issue"},{"location":"community/maintainer/triage/","text":"

Triage is an important part of maintaining the health of the trivy repo. A well organized repo allows maintainers to prioritize feature requests, fix bugs, and respond to users facing difficulty with the tool as quickly as possible.

Triage includes:

  • Labeling issues
  • Responding to issues
  • Closing issues
","title":"Triage"},{"location":"community/maintainer/triage/#daily-triage","text":"

Daily triage has two goals:

  1. Responsiveness for new issues
  2. Responsiveness when explicitly requested information was provided

It covers:

  1. Issues without a kind/ or triage/ label
  2. Issues without a priority/ label
  3. triage/needs-information issues which the user has followed up on, and now require a response.
","title":"Daily Triage"},{"location":"community/maintainer/triage/#categorization","text":"

The most important level of categorizing the issue is defining what type it is. We typically want at least one of the following labels on every issue, and some issues may fall into multiple categories:

  • triage/support - The default for most incoming issues
  • kind/bug - When it\u2019s a bug or we aren\u2019t delivering the best user experience

Other possibilities: - kind/feature- Identify new feature requests - kind/testing - Update or fix unit/integration tests - kind/cleanup - Cleaning up/refactoring the codebase - kind/documentation - Updates or additions to trivy documentation

If the issue is specific to a driver for OS packages or libraries:

co/[driver for OS packages]

  • co/alpine
  • co/amazon
  • co/debian
  • co/oracle
  • co/photon
  • co/redhat
  • co/suse
  • co/ubuntu

co/[driver for libraries of programming languages]

  • co/bundler
  • co/cargo
  • co/composer
  • co/npm
  • co/yarn
  • co/pipenv
  • co/poetry

Help wanted?

Good First Issue - bug has a proposed solution, can be implemented w/o further discussion.

Help wanted - if the bug could use help from a contributor

","title":"Categorization"},{"location":"community/maintainer/triage/#prioritization","text":"

If the issue is not triage/support, it needs a priority label.

priority/critical-urgent - someones top priority ASAP, such as security issue, user-visible bug, or build breakage. Rarely used.

priority/important-soon: in time for the next two releases. It should be attached to a milestone.

priority/important-longterm: 2-4 releases from now

priority/backlog: agreed that this would be good to have, but no one is available at the moment. Consider tagging as help wanted

priority/awaiting-more-evidence: may be useful, but there is not yet enough support.

","title":"Prioritization"},{"location":"community/maintainer/triage/#weekly-triage","text":"

Weekly triage has three goals:

  1. Catching up on unresponded issues
  2. Reviewing and closing PR\u2019s
  3. Closing stale issues
","title":"Weekly Triage"},{"location":"community/maintainer/triage/#post-release-triage","text":"

Post-release triage occurs after a major release (around every 4-6 weeks). It focuses on:

  1. Closing bugs that have been resolved by the release
  2. Reprioritizing bugs that have not been resolved by the release
  3. Letting users know if we believe that there is still an issue

This includes reviewing:

  1. Every issue that hasn\u2019t been touched in the last 2 days
  2. Re-evaluation of long-term issues
  3. Re-evaluation of short-term issues
","title":"Post-Release Triage"},{"location":"community/maintainer/triage/#responding-to-issues","text":"","title":"Responding to Issues"},{"location":"community/maintainer/triage/#needs-more-information","text":"

A sample response to ask for more info:

I don\u2019t yet have a clear way to replicate this issue. Do you mind adding some additional details. Here is additional information that would be helpful:

* The exact trivy command line used

* The exact image you want to scan

* The full output of the trivy command, preferably with --debug for extra logging.

Thank you for sharing your experience!

Then: Label with triage/needs-information.

","title":"Needs More Information"},{"location":"community/maintainer/triage/#issue-might-be-resolved","text":"

If you think a release may have resolved an issue, ask the author to see if their issue has been resolved:

Could you please check to see if trivy addresses this issue? We've made some changes with how this is handled, and improved the trivy logs output to help us debug tricky cases like this.

Then: Label with triage/needs-information.

","title":"Issue might be resolved"},{"location":"community/maintainer/triage/#closing-with-care","text":"

Issues typically need to be closed for the following reasons:

  • The issue has been addressed
  • The issue is a duplicate of an existing issue
  • There has been a lack of information over a long period of time

In any of these situations, we aim to be kind when closing the issue, and offer the author action items should they need to reopen their issue or still require a solution.

Samples responses for these situations include:

","title":"Closing with Care"},{"location":"community/maintainer/triage/#issue-has-been-addressed","text":"

@author: I believe this issue is now addressed by trivy v1.0.0, as it . If you still see this issue with trivy v1.0 or higher, please reopen this issue.

Thank you for reporting this issue!

Then: Close the issue

","title":"Issue has been addressed"},{"location":"community/maintainer/triage/#duplicate-issue","text":"

This issue appears to be a duplicate of #X, do you mind if we move the conversation there?

This way we can centralize the content relating to the issue. If you feel that this issue is not in fact a duplicate, please re-open it. If you have additional information to share, please add it to the new issue.

Thank you for reporting this!

Then: Label with triage/duplicate and close the issue.

","title":"Duplicate Issue"},{"location":"community/maintainer/triage/#lack-of-information","text":"

If an issue hasn't been active for more than four weeks, and the author has been pinged at least once, then the issue can be closed.

Hey @author -- hopefully it's OK if I close this - there wasn't enough information to make it actionable, and some time has already passed. If you are able to provide additional details, you may reopen it at any point.

Here is additional information that may be helpful to us:

* Whether the issue occurs with the latest trivy release

* The exact trivy command line used

* The exact image you want to scan

* The full output of the trivy command, preferably with --debug for extra logging.

Thank you for sharing your experience!

Then: Close the issue.

","title":"Lack of Information"},{"location":"community/maintainer/triage/#help-wanted-issues","text":"

We use two labels help wanted and good first issue to identify issues that have been specially groomed for new contributors.

We have specific guidelines for how to use these labels. If you see an issue that satisfies these guidelines, you can add the help wanted label and the good first issue label. Please note that adding the good first issue label must also add the help wanted label.

If an issue has these labels but does not satisfy the guidelines, please ask for more details to be added to the issue or remove the labels.

","title":"Help Wanted issues"},{"location":"docs/","text":"

Trivy detects two types of security issues:

  • Vulnerabilities
  • Misconfigurations

Trivy can scan three different artifacts:

  • Container Images
  • Filesystem and Rootfs
  • Git Repositories

Trivy can be run in two different modes:

  • Standalone
  • Client/Server

It is designed to be used in CI. Before pushing to a container registry or deploying your application, you can scan your local container image and other artifacts easily. See Integrations for details.

","title":"Docs"},{"location":"docs/#features","text":"
  • Comprehensive vulnerability detection
    • OS packages (Alpine, Red Hat Universal Base Image, Red Hat Enterprise Linux, CentOS, AlmaLinux, Rocky Linux, CBL-Mariner, Oracle Linux, Debian, Ubuntu, Amazon Linux, openSUSE Leap, SUSE Enterprise Linux, Photon OS and Distroless)
    • Language-specific packages (Bundler, Composer, Pipenv, Poetry, npm, yarn, Cargo, NuGet, Maven, and Go)
  • Detect IaC misconfigurations
    • A wide variety of built-in policies are provided out of the box:
      • Kubernetes
      • Docker
      • Terraform
      • more coming soon
    • Support custom policies
  • Simple
    • Specify only an image name, a directory containing IaC configs, or an artifact name
    • See Quick Start
  • Fast
    • The first scan will finish within 10 seconds (depending on your network). Consequent scans will finish in single seconds.
    • Unlike other scanners that take long to fetch vulnerability information (~10 minutes) on the first run, and encourage you to maintain a durable vulnerability database, Trivy is stateless and requires no maintenance or preparation.
  • Easy installation
    • apt-get install, yum install and brew install is possible (See Installation)
    • No pre-requisites such as installation of DB, libraries, etc.
  • High accuracy
    • Especially Alpine Linux and RHEL/CentOS
    • Other OSes are also high
  • DevSecOps
    • Suitable for CI such as Travis CI, CircleCI, Jenkins, GitLab CI, etc.
    • See CI Example
  • Support multiple formats
    • container image
      • A local image in Docker Engine which is running as a daemon
      • A local image in Podman (>=2.0) which is exposing a socket
      • A remote image in Docker Registry such as Docker Hub, ECR, GCR and ACR
      • A tar archive stored in the docker save / podman save formatted file
      • An image directory compliant with OCI Image Format
    • local filesystem and rootfs
    • remote git repository
  • SBOM (Software Bill of Materials) support
    • CycloneDX

Please see LICENSE for Trivy licensing information.

","title":"Features"},{"location":"docs/advanced/air-gap/","text":"

Trivy can be used in air-gapped environments. Note that an allowlist is here.

","title":"Air-Gapped Environment"},{"location":"docs/advanced/air-gap/#air-gapped-environment-for-vulnerabilities","text":"","title":"Air-Gapped Environment for vulnerabilities"},{"location":"docs/advanced/air-gap/#download-the-vulnerability-database","text":"

At first, you need to download the vulnerability database for use in air-gapped environments. Please follow oras installation instruction.

Download db.tar.gz:

$ oras pull ghcr.io/aquasecurity/trivy-db:2 -a\n
","title":"Download the vulnerability database"},{"location":"docs/advanced/air-gap/#transfer-the-db-file-into-the-air-gapped-environment","text":"

The way of transfer depends on the environment.

$ rsync -av -e ssh /path/to/db.tar.gz [user]@[host]:dst\n
","title":"Transfer the DB file into the air-gapped environment"},{"location":"docs/advanced/air-gap/#put-the-db-file-in-trivys-cache-directory","text":"

You have to know where to put the DB file. The following command shows the default cache directory.

$ ssh user@host\n$ trivy -h | grep cache\n   --cache-dir value  cache directory (default: \"/home/myuser/.cache/trivy\") [$TRIVY_CACHE_DIR]\n

Put the DB file in the cache directory + /db.

$ mkdir -p /home/myuser/.cache/trivy/db\n$ cd /home/myuser/.cache/trivy/db\n$ tar xvf /path/to/db.tar.gz -C /home/myuser/.cache/trivy/db\nx trivy.db\nx metadata.json\n$ rm /path/to/db.tar.gz\n

In an air-gapped environment it is your responsibility to update the Trivy database on a regular basis, so that the scanner can detect recently-identified vulnerabilities.

","title":"Put the DB file in Trivy's cache directory"},{"location":"docs/advanced/air-gap/#run-trivy-with-skip-update-and-offline-scan-option","text":"

In an air-gapped environment, specify --skip-update so that Trivy doesn't attempt to download the latest database file. In addition, if you want to scan Java dependencies such as JAR and pom.xml, you need to specify --offline-scan since Trivy tries to issue API requests for scanning Java applications by default.

$ trivy image --skip-update --offline-scan alpine:3.12\n
","title":"Run Trivy with --skip-update and --offline-scan option"},{"location":"docs/advanced/air-gap/#air-gapped-environment-for-misconfigurations","text":"","title":"Air-Gapped Environment for misconfigurations"},{"location":"docs/advanced/air-gap/#download-misconfiguration-policies","text":"

At first, you need to download misconfiguration policies for use in air-gapped environments. Please follow oras installation instruction.

Download bundle.tar.gz:

$ oras pull ghcr.io/aquasecurity/appshield:latest -a\n
","title":"Download misconfiguration policies"},{"location":"docs/advanced/air-gap/#transfer-misconfiguration-policies-into-the-air-gapped-environment","text":"

The way of transfer depends on the environment.

$ rsync -av -e ssh /path/to/bundle.tar.gz [user]@[host]:dst\n
","title":"Transfer misconfiguration policies into the air-gapped environment"},{"location":"docs/advanced/air-gap/#put-the-misconfiguration-policies-in-trivys-cache-directory","text":"

You have to know where to put the misconfiguration policies file. The following command shows the default cache directory.

$ ssh user@host\n$ trivy -h | grep cache\n   --cache-dir value  cache directory (default: \"/home/myuser/.cache/trivy\") [$TRIVY_CACHE_DIR]\n

Put the misconfiguration policies file in the cache directory + /policy/content.

$ mkdir -p /home/myuser/.cache/trivy/policy/content\n$ cd /home/myuser/.cache/trivy/policy/content\n$ mv /path/to/bundle.tar.gz .\n

Then, decompress it. bundle.tar.gz file includes two folders: docker, kubernetes and file: .manifest.

$ tar xvf bundle.tar.gz \nx ./docker/\n...\nx ./kubernetes/\n...\nx ./.manifest\n$ rm bundle.tar.gz\n

In an air-gapped environment it is your responsibility to update policies on a regular basis, so that the scanner can detect recently-identified misconfigurations.

","title":"Put the misconfiguration policies in Trivy's cache directory"},{"location":"docs/advanced/air-gap/#run-trivy-with-skip-policy-update-option","text":"

In an air-gapped environment, specify --skip-policy-update so that Trivy doesn't attempt to download the latest misconfiguration policies.

$ trivy conf --skip-policy-update /path/to/conf\n
","title":"Run Trivy with --skip-policy-update option"},{"location":"docs/advanced/plugins/","text":"

Trivy provides a plugin feature to allow others to extend the Trivy CLI without the need to change the Trivycode base. This plugin system was inspired by the plugin system used in kubectl, Helm, and Conftest.

","title":"Plugins"},{"location":"docs/advanced/plugins/#overview","text":"

Trivy plugins are add-on tools that integrate seamlessly with Trivy. They provide a way to extend the core feature set of Trivy, but without requiring every new feature to be written in Go and added to the core tool.

  • They can be added and removed from a Trivy installation without impacting the core Trivy tool.
  • They can be written in any programming language.
  • They integrate with Trivy, and will show up in Trivy help and subcommands.

Warning

Trivy plugins available in public are not audited for security. You should install and run third-party plugins at your own risk, since they are arbitrary programs running on your machine.

","title":"Overview"},{"location":"docs/advanced/plugins/#installing-a-plugin","text":"

A plugin can be installed using the trivy plugin install command. This command takes a url and will download the plugin and install it in the plugin cache.

Trivy adheres to the XDG specification, so the location depends on whether XDG_DATA_HOME is set. Trivy will now search XDG_DATA_HOME for the location of the Trivy plugins cache. The preference order is as follows:

  • XDG_DATA_HOME if set and .trivy/plugins exists within the XDG_DATA_HOME dir
  • ~/.trivy/plugins

Under the hood Trivy leverages go-getter to download plugins. This means the following protocols are supported for downloading plugins:

  • OCI Registries
  • Local Files
  • Git
  • HTTP/HTTPS
  • Mercurial
  • Amazon S3
  • Google Cloud Storage

For example, to download the Kubernetes Trivy plugin you can execute the following command:

$ trivy plugin install github.com/aquasecurity/trivy-plugin-kubectl\n
","title":"Installing a Plugin"},{"location":"docs/advanced/plugins/#using-plugins","text":"

Once the plugin is installed, Trivy will load all available plugins in the cache on the start of the next Trivy execution. A plugin will be made in the Trivy CLI based on the plugin name. To display all plugins, you can list them by trivy --help

$ trivy --help\nNAME:\n   trivy - A simple and comprehensive vulnerability scanner for containers\n\nUSAGE:\n   trivy [global options] command [command options] target\n\nVERSION:\n   dev\n\nCOMMANDS:\n   image, i          scan an image\n   filesystem, fs    scan local filesystem\n   repository, repo  scan remote repository\n   client, c         client mode\n   server, s         server mode\n   plugin, p         manage plugins\n   kubectl           scan kubectl resources\n   help, h           Shows a list of commands or help for one command\n

As shown above, kubectl subcommand exists in the COMMANDS section. To call the kubectl plugin and scan existing Kubernetes deployments, you can execute the following command:

$ trivy kubectl deployment <deployment-id> -- --ignore-unfixed --severity CRITICAL\n

Internally the kubectl plugin calls the kubectl binary to fetch information about that deployment and passes the using images to Trivy. You can see the detail here.

If you want to omit even the subcommand, you can use TRIVY_RUN_AS_PLUGIN environment variable.

$ TRIVY_RUN_AS_PLUGIN=kubectl trivy job your-job -- --format json\n
","title":"Using Plugins"},{"location":"docs/advanced/plugins/#installing-and-running-plugins-on-the-fly","text":"

trivy plugin run installs a plugin and runs it on the fly. If the plugin is already present in the cache, the installation is skipped.

trivy plugin run github.com/aquasecurity/trivy-plugin-kubectl pod your-pod -- --exit-code 1\n
","title":"Installing and Running Plugins on the fly"},{"location":"docs/advanced/plugins/#uninstalling-plugins","text":"

Specify a plugin name with trivy plugin uninstall command.

$ trivy plugin uninstall kubectl\n
","title":"Uninstalling Plugins"},{"location":"docs/advanced/plugins/#building-plugins","text":"

Each plugin has a top-level directory, and then a plugin.yaml file.

your-plugin/\n  |\n  |- plugin.yaml\n  |- your-plugin.sh\n

In the example above, the plugin is contained inside of a directory named your-plugin. It has two files: plugin.yaml (required) and an executable script, your-plugin.sh (optional).

The core of a plugin is a simple YAML file named plugin.yaml. Here is an example YAML of trivy-plugin-kubectl plugin that adds support for Kubernetes scanning.

name: \"kubectl\"\nrepository: github.com/aquasecurity/trivy-plugin-kubectl\nversion: \"0.1.0\"\nusage: scan kubectl resources\ndescription: |-\n  A Trivy plugin that scans the images of a kubernetes resource.\n  Usage: trivy kubectl TYPE[.VERSION][.GROUP] NAME\nplatforms:\n  - selector: # optional\n      os: darwin\n      arch: amd64\n    uri: ./trivy-kubectl # where the execution file is (local file, http, git, etc.)\n    bin: ./trivy-kubectl # path to the execution file\n  - selector: # optional\n      os: linux\n      arch: amd64\n    uri: https://github.com/aquasecurity/trivy-plugin-kubectl/releases/download/v0.1.0/trivy-kubectl.tar.gz\n    bin: ./trivy-kubectl\n

The plugin.yaml field should contain the following information:

  • name: The name of the plugin. This also determines how the plugin will be made available in the Trivy CLI. For example, if the plugin is named kubectl, you can call the plugin with trivy kubectl. (required)
  • version: The version of the plugin. (required)
  • usage: A short usage description. (required)
  • description: A long description of the plugin. This is where you could provide a helpful documentation of your plugin. (required)
  • platforms: (required)
  • selector: The OS/Architecture specific variations of a execution file. (optional)
    • os: OS information based on GOOS (linux, darwin, etc.) (optional)
    • arch: The architecture information based on GOARCH (amd64, arm64, etc.) (optional)
  • uri: Where the executable file is. Relative path from the root directory of the plugin or remote URL such as HTTP and S3. (required)
  • bin: Which file to call when the plugin is executed. Relative path from the root directory of the plugin. (required)

The following rules will apply in deciding which platform to select:

  • If both os and arch under selector match the current platform, search will stop and the platform will be used.
  • If selector is not present, the platform will be used.
  • If os matches and there is no more specific arch match, the platform will be used.
  • If no platform match is found, Trivy will exit with an error.

After determining platform, Trivy will download the execution file from uri and store it in the plugin cache. When the plugin is called via Trivy CLI, bin command will be executed.

The plugin is responsible for handling flags and arguments. Any arguments are passed to the plugin from the trivy command.

","title":"Building Plugins"},{"location":"docs/advanced/plugins/#example","text":"

https://github.com/aquasecurity/trivy-plugin-kubectl

","title":"Example"},{"location":"docs/advanced/container/embed-in-dockerfile/","text":"

Scan your image as part of the build process by embedding Trivy in the Dockerfile. This approach can be used to update Dockerfiles currently using Aqua\u2019s Microscanner.

$ cat Dockerfile\nFROM alpine:3.7\n\nRUN apk add curl \\\n    && curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin \\\n    && trivy rootfs --exit-code 1 --no-progress /\n\n$ docker build -t vulnerable-image .\n
Alternatively you can use Trivy in a multistage build. Thus avoiding the insecure curl | sh. Also the image is not changed.
[...]\n# Run vulnerability scan on build image\nFROM build AS vulnscan\nCOPY --from=aquasec/trivy:latest /usr/local/bin/trivy /usr/local/bin/trivy\nRUN trivy rootfs --exit-code 1 --no-progress /\n[...]\n

","title":"Embed in Dockerfile"},{"location":"docs/advanced/container/oci/","text":"

An image directory compliant with Open Container Image Layout Specification.

Buildah:

$ buildah push docker.io/library/alpine:3.11 oci:/path/to/alpine\n$ trivy image --input /path/to/alpine\n

Skopeo:

$ skopeo copy docker-daemon:alpine:3.11 oci:/path/to/alpine\n$ trivy image --input /path/to/alpine\n
","title":"OCI Image Layout"},{"location":"docs/advanced/container/podman/","text":"

EXPERIMENTAL

This feature might change without preserving backwards compatibility.

Scan your image in Podman (>=2.0) running locally. The remote Podman is not supported. Before performing Trivy commands, you must enable the podman.sock systemd service on your machine. For more details, see here.

$ systemctl --user enable --now podman.socket\n

Then, you can scan your image in Podman.

$ cat Dockerfile\nFROM alpine:3.12\nRUN apk add --no-cache bash\n$ podman build -t test .\n$ podman images\nREPOSITORY                TAG     IMAGE ID      CREATED      SIZE\nlocalhost/test            latest  efc372d4e0de  About a minute ago  7.94 MB\n$ trivy image test\n
","title":"Podman"},{"location":"docs/advanced/container/unpacked-filesystem/","text":"

Scan an unpacked container image filesystem.

In this case, Trivy works the same way when scanning containers

$ docker export $(docker create alpine:3.10.2) | tar -C /tmp/rootfs -xvf -\n$ trivy rootfs /tmp/rootfs\n
Result
2021-03-08T05:22:26.378Z        INFO    Need to update DB\n2021-03-08T05:22:26.380Z        INFO    Downloading DB...\n20.37 MiB / 20.37 MiB [-------------------------------------------------------------------------------------------------------------------------------------] 100.00% 8.24 MiB p/s 2s\n2021-03-08T05:22:30.134Z        INFO    Detecting Alpine vulnerabilities...\n\n/tmp/rootfs (alpine 3.10.2)\n===========================\nTotal: 20 (UNKNOWN: 0, LOW: 2, MEDIUM: 10, HIGH: 8, CRITICAL: 0)\n\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n|   LIBRARY    | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n| libcrypto1.1 | CVE-2020-1967    | HIGH     | 1.1.1c-r0         | 1.1.1g-r0     | openssl: Segmentation                 |\n|              |                  |          |                   |               | fault in SSL_check_chain              |\n|              |                  |          |                   |               | causes denial of service              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1967  |\n+              +------------------+          +                   +---------------+---------------------------------------+\n|              | CVE-2021-23839   |          |                   | 1.1.1j-r0     | openssl: incorrect SSLv2              |\n|              |                  |          |                   |               | rollback protection                   |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |\n|              |                  |          |                   |               | overflow in CipherUpdate              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |\n|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |\n+              +------------------+----------+                   +---------------+---------------------------------------+\n|              | CVE-2019-1547    | MEDIUM   |                   | 1.1.1d-r0     | openssl: side-channel weak            |\n|              |                  |          |                   |               | encryption vulnerability              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1547  |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2019-1549    |          |                   |               | openssl: information                  |\n|              |                  |          |                   |               | disclosure in fork()                  |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1549  |\n+              +------------------+          +                   +---------------+---------------------------------------+\n|              | CVE-2019-1551    |          |                   | 1.1.1d-r2     | openssl: Integer overflow in RSAZ     |\n|              |                  |          |                   |               | modular exponentiation on x86_64      |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1551  |\n+              +------------------+          +                   +---------------+---------------------------------------+\n|              | CVE-2020-1971    |          |                   | 1.1.1i-r0     | openssl: EDIPARTYNAME                 |\n|              |                  |          |                   |               | NULL pointer de-reference             |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1971  |\n+              +------------------+----------+                   +---------------+---------------------------------------+\n|              | CVE-2019-1563    | LOW      |                   | 1.1.1d-r0     | openssl: information                  |\n|              |                  |          |                   |               | disclosure in PKCS7_dataDecode        |\n|              |                  |          |                   |               | and CMS_decrypt_set1_pkey             |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1563  |\n+--------------+------------------+----------+                   +---------------+---------------------------------------+\n| libssl1.1    | CVE-2020-1967    | HIGH     |                   | 1.1.1g-r0     | openssl: Segmentation                 |\n|              |                  |          |                   |               | fault in SSL_check_chain              |\n|              |                  |          |                   |               | causes denial of service              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1967  |\n+              +------------------+          +                   +---------------+---------------------------------------+\n|              | CVE-2021-23839   |          |                   | 1.1.1j-r0     | openssl: incorrect SSLv2              |\n|              |                  |          |                   |               | rollback protection                   |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |\n|              |                  |          |                   |               | overflow in CipherUpdate              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |\n|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |\n+              +------------------+----------+                   +---------------+---------------------------------------+\n|              | CVE-2019-1547    | MEDIUM   |                   | 1.1.1d-r0     | openssl: side-channel weak            |\n|              |                  |          |                   |               | encryption vulnerability              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1547  |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2019-1549    |          |                   |               | openssl: information                  |\n|              |                  |          |                   |               | disclosure in fork()                  |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1549  |\n+              +------------------+          +                   +---------------+---------------------------------------+\n|              | CVE-2019-1551    |          |                   | 1.1.1d-r2     | openssl: Integer overflow in RSAZ     |\n|              |                  |          |                   |               | modular exponentiation on x86_64      |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1551  |\n+              +------------------+          +                   +---------------+---------------------------------------+\n|              | CVE-2020-1971    |          |                   | 1.1.1i-r0     | openssl: EDIPARTYNAME                 |\n|              |                  |          |                   |               | NULL pointer de-reference             |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-1971  |\n+              +------------------+----------+                   +---------------+---------------------------------------+\n|              | CVE-2019-1563    | LOW      |                   | 1.1.1d-r0     | openssl: information                  |\n|              |                  |          |                   |               | disclosure in PKCS7_dataDecode        |\n|              |                  |          |                   |               | and CMS_decrypt_set1_pkey             |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2019-1563  |\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n| musl         | CVE-2020-28928   | MEDIUM   | 1.1.22-r3         | 1.1.22-r4     | In musl libc through 1.2.1,           |\n|              |                  |          |                   |               | wcsnrtombs mishandles particular      |\n|              |                  |          |                   |               | combinations of destination buffer... |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2020-28928 |\n+--------------+                  +          +                   +               +                                       +\n| musl-utils   |                  |          |                   |               |                                       |\n|              |                  |          |                   |               |                                       |\n|              |                  |          |                   |               |                                       |\n|              |                  |          |                   |               |                                       |\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n
","title":"Unpacked Filesystem"},{"location":"docs/advanced/private-registries/","text":"

Trivy can download images from a private registry, without installing Docker or any other 3rd party tools. That's because it's easy to run in a CI process.

All you have to do is install Trivy and set ENV vars.

","title":"Overview"},{"location":"docs/advanced/private-registries/acr/","text":"

None, Trivy uses Azure SDK for Go. You don't need to install az command.

","title":"Requirements"},{"location":"docs/advanced/private-registries/acr/#privileges","text":"

Service principal must have the AcrPull permissions.

","title":"Privileges"},{"location":"docs/advanced/private-registries/acr/#creation-of-a-service-principal","text":"
export SP_DATA=$(az ad sp create-for-rbac --name TrivyTest --role AcrPull --scope \"/subscriptions/<subscription_id>/resourceGroups/<resource_group>/providers/Microsoft.ContainerRegistry/registries/<registry_name>\")\n
","title":"Creation of a service principal"},{"location":"docs/advanced/private-registries/acr/#usage","text":"
# must set TRIVY_USERNAME empty char\nexport AZURE_CLIENT_ID$(echo $SP_DATA | jq -r .appId)\nexport AZURE_CLIENT_SECRET$(echo $SP_DATA | jq -r .password)\nexport AZURE_TENANT_ID$(echo $SP_DATA | jq -r .tenant)\n
","title":"Usage"},{"location":"docs/advanced/private-registries/acr/#testing","text":"

You can test credentials in the following manner.

docker run -it --rm -v /tmp:/tmp\\\n  -e AZURE_CLIENT_ID=${AZURE_CLIENT_ID} -e AZURE_CLIENT_SECRET=${AZURE_CLIENT_SECRET} \\\n  -e AZURE_TENANT_ID=${AZURE_TENANT_ID} aquasec/trivy image your_special_project.azurecr.io/your_special_image:your_special_tag\n
","title":"Testing"},{"location":"docs/advanced/private-registries/docker-hub/","text":"

Docker Hub needs TRIVY_USERNAME and TRIVY_PASSWORD. You don't need to set ENV vars when download from public repository.

export TRIVY_USERNAME={DOCKERHUB_USERNAME}\nexport TRIVY_PASSWORD={DOCKERHUB_PASSWORD}\n
","title":"Docker Hub"},{"location":"docs/advanced/private-registries/ecr/","text":"

Trivy uses AWS SDK. You don't need to install aws CLI tool. You can use AWS CLI's ENV Vars.

","title":"AWS ECR (Elastic Container Registry)"},{"location":"docs/advanced/private-registries/gcr/","text":"

None, Trivy uses Google Cloud SDK. You don't need to install gcloud command.

","title":"Requirements"},{"location":"docs/advanced/private-registries/gcr/#privileges","text":"

Credential file must have the roles/storage.objectViewer permissions. More information can be found in Google's documentation

","title":"Privileges"},{"location":"docs/advanced/private-registries/gcr/#json-file-format","text":"

The JSON file specified should have the following format provided by google's service account mechanisms:

{\n  \"type\": \"service_account\",\n  \"project_id\": \"your_special_project\",\n  \"private_key_id\": \"XXXXXXXXXXXXXXXXXXXXxx\",\n  \"private_key\": \"-----BEGIN PRIVATE KEY-----\\nNONONONO\\n-----END PRIVATE KEY-----\\n\",\n  \"client_email\": \"somedude@your_special_project.iam.gserviceaccount.com\",\n  \"client_id\": \"1234567890\",\n  \"auth_uri\": \"https://accounts.google.com/o/oauth2/auth\",\n  \"token_uri\": \"https://oauth2.googleapis.com/token\",\n  \"auth_provider_x509_cert_url\": \"https://www.googleapis.com/oauth2/v1/certs\",\n  \"client_x509_cert_url\": \"https://www.googleapis.com/robot/v1/metadata/x509/somedude%40your_special_project.iam.gserviceaccount.com\"\n}\n
","title":"JSON File Format"},{"location":"docs/advanced/private-registries/gcr/#usage","text":"

If you want to use target project's repository, you can set them via GOOGLE_APPLICATION_CREDENTIALS.

# must set TRIVY_USERNAME empty char\nexport GOOGLE_APPLICATION_CREDENTIALS=/path/to/credential.json\n

","title":"Usage"},{"location":"docs/advanced/private-registries/gcr/#testing","text":"

You can test credentials in the following manner (assuming they are in /tmp on host machine).

docker run -it --rm -v /tmp:/tmp\\\n  -e GOOGLE_APPLICATION_CREDENTIALS=/tmp/service_account.json\\\n  aquasec/trivy image gcr.io/your_special_project/your_special_image:your_special_tag\n
","title":"Testing"},{"location":"docs/advanced/private-registries/self/","text":"

BasicAuth server needs TRIVY_USERNAME and TRIVY_PASSWORD.

export TRIVY_USERNAME={USERNAME}\nexport TRIVY_PASSWORD={PASSWORD}\n\n# if you want to use 80 port, use NonSSL\nexport TRIVY_NON_SSL=true\n
","title":"Self-Hosted"},{"location":"docs/integrations/","text":"

Scan your image automatically as part of your CI workflow, failing the workflow if a vulnerability is found. When you don't want to fail the test, specify --exit-code 0.

","title":"Integrations"},{"location":"docs/integrations/aws-codepipeline/","text":"

See this blog post for an example of using Trivy within AWS CodePipeline.

","title":"AWS CodePipeline"},{"location":"docs/integrations/aws-security-hub/","text":"","title":"AWS Security Hub"},{"location":"docs/integrations/aws-security-hub/#upload-findings-to-security-hub","text":"

In the following example using the template asff.tpl, ASFF file can be generated.

$ AWS_REGION=us-west-1 AWS_ACCOUNT_ID=123456789012 trivy image --format template --template \"@contrib/asff.tpl\" -o report.asff golang:1.12-alpine\n

ASFF template needs AWS_REGION and AWS_ACCOUNT_ID from environment variables.

Then, you can upload it with AWS CLI.

$ aws securityhub batch-import-findings --findings file://report.asff\n
","title":"Upload findings to Security Hub"},{"location":"docs/integrations/aws-security-hub/#customize","text":"

You can customize asff.tpl

$ export AWS_REGION=us-west-1\n$ export AWS_ACCOUNT_ID=123456789012\n$ trivy image --format template --template \"@your-asff.tpl\" -o report.asff golang:1.12-alpine\n
","title":"Customize"},{"location":"docs/integrations/aws-security-hub/#reference","text":"

https://aws.amazon.com/blogs/security/how-to-build-ci-cd-pipeline-container-vulnerability-scanning-trivy-and-aws-security-hub/

","title":"Reference"},{"location":"docs/integrations/bitbucket/","text":"

See trivy-pipe for the details.

","title":"Bitbucket Pipelines"},{"location":"docs/integrations/circleci/","text":"
$ cat .circleci/config.yml\njobs:\n  build:\n    docker:\n      - image: docker:stable-git\n    steps:\n      - checkout\n      - setup_remote_docker\n      - run:\n          name: Build image\n          command: docker build -t trivy-ci-test:${CIRCLE_SHA1} .\n      - run:\n          name: Install trivy\n          command: |\n            apk add --update-cache --upgrade curl\n            curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin\n      - run:\n          name: Scan the local image with trivy\n          command: trivy image --exit-code 0 --no-progress trivy-ci-test:${CIRCLE_SHA1}\nworkflows:\n  version: 2\n  release:\n    jobs:\n      - build\n

Example Repository

","title":"CircleCI"},{"location":"docs/integrations/github-actions/","text":"
  • Here is the Trivy Github Action
  • The Microsoft Azure team have written a container-scan action that uses Trivy and Dockle
  • For full control over the options specified to Trivy, this blog post describes adding Trivy into your own GitHub action workflows
","title":"GitHub Actions"},{"location":"docs/integrations/gitlab-ci/","text":"

If you're a GitLab Ultimate customer, GitLab 14.0 and above include out-of-the-box integration with Trivy. To enable it for your project, simply add the container scanning template to your .gitlab-ci.yml file. For more details, please refer to GitLab's documentation.

If you're using an earlier version of GitLab, you can still use the new integration by copying the contents of the 14.0 template to your configuration.

Alternatively, you can always use the example configurations below.

stages:\n  - test\n\ntrivy:\n  stage: test\n  image: docker:stable\n  services:\n    - name: docker:dind\n      entrypoint: [\"env\", \"-u\", \"DOCKER_HOST\"]\n      command: [\"dockerd-entrypoint.sh\"]\n  variables:\n    DOCKER_HOST: tcp://docker:2375/\n    DOCKER_DRIVER: overlay2\n    # See https://github.com/docker-library/docker/pull/166\n    DOCKER_TLS_CERTDIR: \"\"\n    IMAGE: trivy-ci-test:$CI_COMMIT_SHA\n    TRIVY_NO_PROGRESS: \"true\"\n    TRIVY_CACHE_DIR: \".trivycache/\"\n  before_script:\n    - export TRIVY_VERSION=$(wget -qO - \"https://api.github.com/repos/aquasecurity/trivy/releases/latest\" | grep '\"tag_name\":' | sed -E 's/.*\"v([^\"]+)\".*/\\1/')\n    - echo $TRIVY_VERSION\n    - wget --no-verbose https://github.com/aquasecurity/trivy/releases/download/v${TRIVY_VERSION}/trivy_${TRIVY_VERSION}_Linux-64bit.tar.gz -O - | tar -zxvf -\n  allow_failure: true\n  script:\n    # Build image\n    - docker build -t $IMAGE .\n    # Build report\n    - ./trivy image --exit-code 0 --format template --template \"@contrib/gitlab.tpl\" -o gl-container-scanning-report.json $IMAGE\n    # Print report\n    - ./trivy image --exit-code 0 --severity HIGH $IMAGE\n    # Fail on severe vulnerabilities\n    - ./trivy image --exit-code 1 --severity CRITICAL $IMAGE\n  cache:\n    paths:\n      - .trivycache/\n  # Enables https://docs.gitlab.com/ee/user/application_security/container_scanning/ (Container Scanning report is available on GitLab EE Ultimate or GitLab.com Gold)\n  artifacts:\n    reports:\n      container_scanning: gl-container-scanning-report.json\n

Example Repository

","title":"GitLab CI"},{"location":"docs/integrations/gitlab-ci/#gitlab-ci-using-trivy-container","text":"

To scan a previously built image that has already been pushed into the GitLab container registry the following CI job manifest can be used. Note that entrypoint needs to be unset for the script section to work. In case of a non-public GitLab project Trivy additionally needs to authenticate to the registry to be able to pull your application image. Finally, it is not necessary to clone the project repo as we only work with the container image.

container_scanning:\n  image:\n    name: docker.io/aquasec/trivy:latest\n    entrypoint: [\"\"]\n  variables:\n    # No need to clone the repo, we exclusively work on artifacts.  See\n    # https://docs.gitlab.com/ee/ci/runners/README.html#git-strategy\n    GIT_STRATEGY: none\n    TRIVY_USERNAME: \"$CI_REGISTRY_USER\"\n    TRIVY_PASSWORD: \"$CI_REGISTRY_PASSWORD\"\n    TRIVY_AUTH_URL: \"$CI_REGISTRY\"\n    TRIVY_NO_PROGRESS: \"true\"\n    TRIVY_CACHE_DIR: \".trivycache/\"\n    FULL_IMAGE_NAME: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG\n  script:\n    - trivy --version\n    # cache cleanup is needed when scanning images with the same tags, it does not remove the database\n    - time trivy image --clear-cache\n    # update vulnerabilities db\n    - time trivy image --download-db-only\n    # Builds report and puts it in the default workdir $CI_PROJECT_DIR, so `artifacts:` can take it from there\n    - time trivy image --exit-code 0 --format template --template \"@/contrib/gitlab.tpl\"\n        --output \"$CI_PROJECT_DIR/gl-container-scanning-report.json\" \"$FULL_IMAGE_NAME\"\n    # Prints full report\n    - time trivy image --exit-code 0 \"$FULL_IMAGE_NAME\"\n    # Fail on critical vulnerabilities\n    - time trivy image --exit-code 1 --severity CRITICAL \"$FULL_IMAGE_NAME\"\n  cache:\n    paths:\n      - .trivycache/\n  # Enables https://docs.gitlab.com/ee/user/application_security/container_scanning/ (Container Scanning report is available on GitLab EE Ultimate or GitLab.com Gold)\n  artifacts:\n    when:                          always\n    reports:\n      container_scanning:          gl-container-scanning-report.json\n  tags:\n    - docker-runner\n
","title":"GitLab CI using Trivy container"},{"location":"docs/integrations/gitlab-ci/#gitlab-ci-alternative-template","text":"

Depending on the edition of gitlab you have or your desired workflow, the container scanning template may not meet your needs. As an addition to the above container scanning template, a template for code climate has been included. The key things to update from the above examples are the template and report type. An updated example is below.

stages:\n  - test\n\ntrivy:\n  stage: test\n  image: docker:stable\n  services:\n    - name: docker:dind\n      entrypoint: [\"env\", \"-u\", \"DOCKER_HOST\"]\n      command: [\"dockerd-entrypoint.sh\"]\n  variables:\n    DOCKER_HOST: tcp://docker:2375/\n    DOCKER_DRIVER: overlay2\n    # See https://github.com/docker-library/docker/pull/166\n    DOCKER_TLS_CERTDIR: \"\"\n    IMAGE: trivy-ci-test:$CI_COMMIT_SHA\n    TRIVY_NO_PROGRESS: \"true\"\n    TRIVY_CACHE_DIR: \".trivycache/\"\n  before_script:\n    - export TRIVY_VERSION=$(wget -qO - \"https://api.github.com/repos/aquasecurity/trivy/releases/latest\" | grep '\"tag_name\":' | sed -E 's/.*\"v([^\"]+)\".*/\\1/')\n    - echo $TRIVY_VERSION\n    - wget --no-verbose https://github.com/aquasecurity/trivy/releases/download/v${TRIVY_VERSION}/trivy_${TRIVY_VERSION}_Linux-64bit.tar.gz -O - | tar -zxvf -\n  allow_failure: true\n  script:\n    # Build image\n    - docker build -t $IMAGE .\n    # Image report\n    - ./trivy image --exit-code 0 --format template --template \"@contrib/gitlab-codequality.tpl\" -o gl-codeclimate-image.json $IMAGE\n    # Filesystem report\n    - ./trivy filesystem --security-checks config,vuln --exit-code 0 --format template --template \"@contrib/gitlab-codequality.tpl\" -o gl-codeclimate-fs.json .\n    # Combine report\n    - apk update && apk add jq\n    - jq -s 'add' gl-codeclimate-image.json gl-codeclimate-fs.json > gl-codeclimate.json\n  cache:\n    paths:\n      - .trivycache/\n  # Enables https://docs.gitlab.com/ee/user/application_security/container_scanning/ (Container Scanning report is available on GitLab EE Ultimate or GitLab.com Gold)\n  artifacts:\n    paths:\n      - gl-codeclimate.json\n    reports:\n      codequality: gl-codeclimate.json\n

Currently gitlab only supports a single code quality report. There is an open feature request to support multiple reports. Until this has been implemented, if you already have a code quality report in your pipeline, you can use jq to combine reports. Depending on how you name your artifacts, it may be necessary to rename the artifact if you want to reuse the name. To then combine the previous artifact with the output of trivy, the following jq command can be used, jq -s 'add' prev-codeclimate.json trivy-codeclimate.json > gl-codeclimate.json.

","title":"Gitlab CI alternative template"},{"location":"docs/integrations/gitlab-ci/#gitlab-ci-alternative-template-example-report","text":"

You'll be able to see a full report in the Gitlab pipeline code quality UI, where filesystem vulnerabilities and misconfigurations include links to the flagged files and image vulnerabilities report the image/os or runtime/library that the vulnerability originates from instead.

","title":"Gitlab CI alternative template example report"},{"location":"docs/integrations/travis-ci/","text":"
$ cat .travis.yml\nservices:\n  - docker\n\nenv:\n  global:\n    - COMMIT=${TRAVIS_COMMIT::8}\n\nbefore_install:\n  - docker build -t trivy-ci-test:${COMMIT} .\n  - export VERSION=$(curl --silent \"https://api.github.com/repos/aquasecurity/trivy/releases/latest\" | grep '\"tag_name\":' | sed -E 's/.*\"v([^\"]+)\".*/\\1/')\n  - wget https://github.com/aquasecurity/trivy/releases/download/v${VERSION}/trivy_${VERSION}_Linux-64bit.tar.gz\n  - tar zxvf trivy_${VERSION}_Linux-64bit.tar.gz\nscript:\n  - ./trivy image --exit-code 0 --severity HIGH --no-progress trivy-ci-test:${COMMIT}\n  - ./trivy image --exit-code 1 --severity CRITICAL --no-progress trivy-ci-test:${COMMIT}\ncache:\n  directories:\n    - $HOME/.cache/trivy\n

Example Repository

","title":"Travis CI"},{"location":"docs/misconfiguration/","text":"

Trivy provides built-in policies to detect configuration issues in Docker, Kubernetes and Terraform. Also, you can write your own policies in Rego to scan JSON, YAML, HCL, etc, like Conftest.

","title":"Misconfiguration Scanning"},{"location":"docs/misconfiguration/filesystem/","text":"","title":"Filesystem"},{"location":"docs/misconfiguration/filesystem/#quick-start","text":"

Trivy scans a filesystem such as a virtual machine to detect misconfigurations.

You have to specify --security-checks config to enable misconfiguration detection.

$ trivy fs --security-checks config /path/to/dir\n

Internally, it is the same as config subcommand.

","title":"Quick start"},{"location":"docs/misconfiguration/filesystem/#vulnerability-and-misconfiguration-scanning","text":"

The difference between fs and config subcommand is that fs can detect both vulnerabilities and misconfiguration at the same time.

You have to specify --security-checks vuln,config to enable vulnerability and misconfiguration detection.

$ ls myapp/\nDockerfile Pipfile.lock\n$ trivy fs --security-checks vuln,config --severity HIGH,CRITICAL myapp/\n2021-07-09T12:03:27.564+0300    INFO    Detected OS: unknown\n2021-07-09T12:03:27.564+0300    INFO    Number of language-specific files: 1\n2021-07-09T12:03:27.564+0300    INFO    Detecting pipenv vulnerabilities...\n2021-07-09T12:03:27.566+0300    INFO    Detected config files: 1\n\nPipfile.lock (pipenv)\n=====================\nTotal: 1 (HIGH: 1, CRITICAL: 0)\n\n+----------+------------------+----------+-------------------+---------------+---------------------------------------+\n| LIBRARY  | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |\n+----------+------------------+----------+-------------------+---------------+---------------------------------------+\n| httplib2 | CVE-2021-21240   | HIGH     | 0.12.1            | 0.19.0        | python-httplib2: Regular              |\n|          |                  |          |                   |               | expression denial of                  |\n|          |                  |          |                   |               | service via malicious header          |\n|          |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-21240 |\n+----------+------------------+----------+-------------------+---------------+---------------------------------------+\n\nDockerfile (dockerfile)\n=======================\nTests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)\nFailures: 1 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |\n|                           |            |                      |          | Dockerfile should not be 'root'          |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n

In the above example, Trivy detected vulnerabilities of Python dependencies and misconfigurations in Dockerfile.

","title":"Vulnerability and Misconfiguration scanning"},{"location":"docs/misconfiguration/iac/","text":"","title":"Infrastructure as Code (IaC)"},{"location":"docs/misconfiguration/iac/#quick-start","text":"

Simply specify a directory containing IaC files such as Terraform, CloudFormation and Dockerfile.

$ trivy config [YOUR_IaC_DIRECTORY]\n

Trivy will automatically fetch the managed policies and will keep them up-to-date in future scans.

Example

$ ls build/\nDockerfile\n$ trivy config ./build\n2021-07-09T10:06:29.188+0300    INFO    Need to update the built-in policies\n2021-07-09T10:06:29.188+0300    INFO    Downloading the built-in policies...\n2021-07-09T10:06:30.520+0300    INFO    Detected config files: 1\n\nDockerfile (dockerfile)\n=======================\nTests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)\nFailures: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |\n|                           |            |                      |          | Dockerfile should not be 'root'          |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n
","title":"Quick start"},{"location":"docs/misconfiguration/iac/#type-detection","text":"

The specified directory can contain mixed types of IaC files. Trivy automatically detects config types and applies relevant policies.

For example, the following example holds IaC files for Terraform, CloudFormation, Kubernetes, and Dockerfile in the same directory.

$ ls iac/\nDockerfile  deployment.yaml  main.tf\n$ trivy conf --severity HIGH,CRITICAL ./iac\n
Result
2021-07-09T11:51:08.212+0300    INFO    Need to update the built-in policies\n2021-07-09T11:51:08.212+0300    INFO    Downloading the built-in policies...\n2021-07-09T11:51:09.527+0300    INFO    Detected config files: 3\n\nDockerfile (dockerfile)\n=======================\nTests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)\nFailures: 1 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |\n|                           |            |                      |          | Dockerfile should not be 'root'          |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n\ndeployment.yaml (kubernetes)\n============================\nTests: 28 (SUCCESSES: 15, FAILURES: 13, EXCEPTIONS: 0)\nFailures: 13 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |           CHECK            | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------------+----------+------------------------------------------+\n| Kubernetes Security Check |   KSV005   | SYS_ADMIN capability added |   HIGH   | Container 'hello-kubernetes' of          |\n|                           |            |                            |          | Deployment 'hello-kubernetes'            |\n|                           |            |                            |          | should not include 'SYS_ADMIN' in        |\n|                           |            |                            |          | 'securityContext.capabilities.add'       |\n|                           |            |                            |          | -->avd.aquasec.com/appshield/ksv005      |\n+---------------------------+------------+----------------------------+----------+------------------------------------------+\n\nmain.tf (terraform)\n===================\nTests: 23 (SUCCESSES: 14, FAILURES: 9, EXCEPTIONS: 0)\nFailures: 9 (HIGH: 6, CRITICAL: 1)\n\n+------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+\n|                   TYPE                   | MISCONF ID |                  CHECK                   | SEVERITY |                        MESSAGE                         |\n+------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+\n|   Terraform Security Check powered by    |   AWS003   | AWS Classic resource usage.              |   HIGH   | Resource                                               |\n|                  tfsec                   |            |                                          |          | 'aws_db_security_group.my-group'                       |\n|                                          |            |                                          |          | uses EC2 Classic. Use a VPC instead.                   |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS003/                          |\n+                                          +------------+------------------------------------------+----------+--------------------------------------------------------+\n|                                          |   AWS004   | Use of plain HTTP.                       | CRITICAL | Resource                                               |\n|                                          |            |                                          |          | 'aws_alb_listener.my-alb-listener'                     |\n|                                          |            |                                          |          | uses plain HTTP instead of HTTPS.                      |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS004/                          |\n+                                          +------------+------------------------------------------+----------+--------------------------------------------------------+\n|                                          |   AWS018   | Missing description for security         |   HIGH   | Resource                                               |\n|                                          |            | group/security group rule.               |          | 'aws_security_group_rule.my-rule' should               |\n|                                          |            |                                          |          | include a description for auditing                     |\n|                                          |            |                                          |          | purposes. -->tfsec.dev/docs/aws/AWS018/                |\n+                                          +------------+------------------------------------------+          +--------------------------------------------------------+\n|                                          |   AWS025   | API Gateway domain name uses outdated    |          | Resource                                               |\n|                                          |            | SSL/TLS protocols.                       |          | 'aws_api_gateway_domain_name.empty_security_policy'    |\n|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using           |\n|                                          |            |                                          |          | TLS_1_2). -->tfsec.dev/docs/aws/AWS025/                |\n+                                          +            +                                          +          +--------------------------------------------------------+\n|                                          |            |                                          |          | Resource                                               |\n|                                          |            |                                          |          | 'aws_api_gateway_domain_name.missing_security_policy'  |\n|                                          |            |                                          |          | should include security_policy (defaults to outdated   |\n|                                          |            |                                          |          | SSL/TLS policy). -->tfsec.dev/docs/aws/AWS025/         |\n+                                          +            +                                          +          +--------------------------------------------------------+\n|                                          |            |                                          |          | Resource                                               |\n|                                          |            |                                          |          | 'aws_api_gateway_domain_name.outdated_security_policy' |\n|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using TLS_1_2). |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS025/                          |\n+                                          +------------+------------------------------------------+          +--------------------------------------------------------+\n|                                          |   AZU003   | Unencrypted managed disk.                |          | Resource 'azurerm_managed_disk.source'                 |\n|                                          |            |                                          |          | defines an unencrypted managed disk.                   |\n|                                          |            |                                          |          | -->tfsec.dev/docs/azure/AZU003/                        |\n+------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+\n

You can see the config type next to each file name.

Example

Dockerfile (dockerfile)\n=======================\nTests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)\nFailures: 1 (HIGH: 1, CRITICAL: 0)\n\n...\n\ndeployment.yaml (kubernetes)\n============================\nTests: 28 (SUCCESSES: 15, FAILURES: 13, EXCEPTIONS: 0)\nFailures: 13 (HIGH: 1, CRITICAL: 0)\n\n...\n\nmain.tf (terraform)\n===================\nTests: 23 (SUCCESSES: 14, FAILURES: 9, EXCEPTIONS: 0)\nFailures: 9 (HIGH: 6, CRITICAL: 1)\n\n...\n\nbucket.yaml (cloudformation)\n============================\nTests: 9 (SUCCESSES: 3, FAILURES: 6, EXCEPTIONS: 0)\nFailures: 6 (UNKNOWN: 0, LOW: 0, MEDIUM: 2, HIGH: 4, CRITICAL: 0)\n
","title":"Type detection"},{"location":"docs/misconfiguration/iac/#example","text":"

See here

","title":"Example"},{"location":"docs/misconfiguration/comparison/cfsec/","text":"

cfsec uses static analysis of your CloudFormation templates to spot potential security issues. Trivy uses cfsec internally to scan both JSON and YAML configuration files, but Trivy doesn't support some features provided by cfsec. This section describes the differences between Trivy and cfsec.

Feature Trivy cfsec Built-in Policies Custom Policies Rego1 Policy Metadata2 Show Successes Disable Policies Show Issue Lines View Statistics Filtering by Severity Supported Formats Dockerfile, JSON, YAML, Terraform, etc. CloudFormation JSON and YAML

cfsec is designed for CloudFormation. People who use only want to scan their CloudFormation templates should use cfsec. People who want to scan a wide range of configuration files should use Trivy.

  1. CloudFormation files are not supported\u00a0\u21a9

  2. To enrich the results such as ID, Title, Description, Severity, etc.\u00a0\u21a9

","title":"vs cfsec"},{"location":"docs/misconfiguration/comparison/conftest/","text":"

Conftest is a really nice tool to help you write tests against structured configuration data. Misconfiguration detection in Trivy is heavily inspired by Conftest and provides similar features Conftest has. This section describes the differences between Trivy and Conftest.

Feature Trivy Conftest Support Rego Language Built-in Policies Custom Policies Custom Data Combine Combine per Policy Policy Input Selector1 Policy Metadata2 3 Filtering by Severity Rule-based Exceptions Namespace-based Exceptions Sharing Policies Show Successes Flexible Exit Code Rego Unit Tests 4 Go Testing Verbose Trace Supported Formats 6 formats5 14 formats6

Trivy offers built-in policies and a variety of options, while Conftest only supports custom policies. In other words, Conftest is simpler and lighter.

Conftest is a general testing tool for configuration files, and Trivy is more security-focused. People who need an out-of-the-box misconfiguration scanner should use Trivy. People who don't need built-in policies and write your policies should use Conftest.

  1. Pass only the types of configuration file as input, specified in selector\u00a0\u21a9

  2. To enrich the results such as ID, Title, Description, etc.\u00a0\u21a9

  3. Conftest supports structured errors in rules, but they are free format and not natively supported by Conftest.\u00a0\u21a9

  4. Trivy is not able to run *_test.rego like conftest verify.\u00a0\u21a9

  5. Dockerfile, HCL, HCL2, JSON, TOML, and YAML\u00a0\u21a9

  6. CUE, Dockerfile, EDN, HCL, HCL2, HOCON, Ignore files, INI, JSON, Jsonnet, TOML, VCL, XML, and YAML\u00a0\u21a9

","title":"vs Conftest"},{"location":"docs/misconfiguration/comparison/tfsec/","text":"

tfsec uses static analysis of your Terraform templates to spot potential security issues. Trivy uses tfsec internally to scan Terraform HCL files, but Trivy doesn't support some features provided by tfsec. This section describes the differences between Trivy and tfsec.

Feature Trivy tfsec Built-in Policies Custom Policies Rego1 JSON and YAML Policy Metadata2 Show Successes Disable Policies Show Issue Lines Support .tfvars View Statistics Filtering by Severity Supported Formats Dockerfile, JSON, YAML, Terraform, etc. Terraform

tfsec is designed for Terraform. People who use only Terraform should use tfsec. People who want to scan a wide range of configuration files should use Trivy.

  1. Terraform HCL files are not supported.\u00a0\u21a9

  2. To enrich the results such as ID, Title, Description, Severity, etc.\u00a0\u21a9

","title":"vs tfsec"},{"location":"docs/misconfiguration/custom/","text":"","title":"Custom Policies"},{"location":"docs/misconfiguration/custom/#overview","text":"

You can write custom policies in Rego. Once you finish writing custom policies, you can pass the directory where those policies are stored with --policy option.

trivy conf --policy /path/to/custom_policies --namespaces user /path/to/config_dir\n

As for --namespaces option, the detail is described as below.

","title":"Overview"},{"location":"docs/misconfiguration/custom/#file-formats","text":"

If a file name matches the following file patterns, Trivy will parse the file and pass it as input to your Rego policy.

File format File pattern JSON *.json YAML *.yaml TOML *.toml HCL *.hcl, *.hcl1, and *.hcl2 Dockerfile Dockerfile, Dockerfile.*, and *.Dockerfile","title":"File formats"},{"location":"docs/misconfiguration/custom/#configuration-languages","text":"

In the above general file formats, Trivy automatically identifies the following types of configuration files:

  • Ansible (YAML)
  • CloudFormation (JSON/YAML)
  • Kubernetes (JSON/YAML)

This is useful for filtering inputs, as described below.

Warning

Custom policies do not support Terraform at the moment.

","title":"Configuration languages"},{"location":"docs/misconfiguration/custom/#rego-format","text":"

A single package must contain only one policy.

Example

package user.kubernetes.ID001\n\n__rego_metadata__ := {\n    \"id\": \"ID001\",\n    \"title\": \"Deployment not allowed\",\n    \"severity\": \"LOW\",\n    \"type\": \"Custom Kubernetes Check\",\n    \"description\": \"Deployments are not allowed because of some reasons.\",\n}\n\n__rego_input__ := {\n    \"selector\": [\n        {\"type\": \"kubernetes\"},\n    ],\n}\n\ndeny[msg] {\n    input.kind == \"Deployment\"\n    msg = sprintf(\"Found deployment '%s' but deployments are not allowed\", [input.metadata.name])\n}\n

In this example, ID001 \"Deployment not allowed\" is defined under user.kubernetes.ID001. If you add a new custom policy, it must be defined under a new package like user.kubernetes.ID002.

","title":"Rego format"},{"location":"docs/misconfiguration/custom/#policy-structure","text":"package (required)
  • MUST follow the Rego's specification
  • MUST be unique per policy
  • SHOULD include policy id for uniqueness
  • MAY include the group name such as kubernetes for clarity
    • Group name has no effect on policy evaluation
__rego_metadata__ (optional)
  • SHOULD be defined for clarity since these values will be displayed in the scan results
__rego_input__ (optional)
  • MAY be defined when you want to specify input format
deny (required)
  • SHOULD be deny or start with deny_
    • Although warn, warn_*, violation, violation_ also work for compatibility, deny is recommended as severity can be defined in __rego_metadata__.
  • SHOULD return string
    • Although object with msg field is accepted, other fields are dropped and string is recommended.
    • e.g. {\"msg\": \"deny message\", \"details\": \"something\"}
","title":"Policy structure"},{"location":"docs/misconfiguration/custom/#package","text":"

A package name must be unique per policy.

Example

package user.kubernetes.ID001\n

By default, only appshield.* packages will be evaluated. If you define custom packages, you have to specify the package prefix via --namespaces option.

trivy conf --policy /path/to/custom_policies --namespaces user /path/to/config_dir\n

In this case, user.* will be evaluated. Any package prefixes such as main and user are allowed.

","title":"Package"},{"location":"docs/misconfiguration/custom/#metadata","text":"

Metadata helps enrich Trivy's scan results with useful information.

Example

__rego_metadata__ := {\n    \"id\": \"ID001\",\n    \"title\": \"Deployment not allowed\",\n    \"severity\": \"LOW\",\n    \"type\": \"Custom Kubernetes Check\",\n    \"description\": \"Deployments are not allowed because of some reasons.\",\n    \"recommended_actions\": \"Remove Deployment\",\n    \"url\": \"https://cloud.google.com/blog/products/containers-kubernetes/kubernetes-best-practices-resource-requests-and-limits\",\n}\n

All fields under __rego_metadata__ are optional.

Field name Allowed values Default value In table In JSON id Any characters N/A title Any characters N/A severity LOW, MEDIUM, HIGH, CRITICAL UNKNOWN type Any characters N/A description Any characters recommended_actions Any characters url Any characters

Some fields are displayed in scan results.

deployment.yaml (kubernetes)\n============================\nTests: 28 (SUCCESSES: 14, FAILURES: 14, EXCEPTIONS: 0)\nFailures: 14 (HIGH: 1)\n\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |                CHECK                | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n| Custom Kubernetes Check   |   ID001    | Deployment not allowed              |   LOW    | Found deployment 'test' but deployments  |\n|                           |            |                                     |          | are not allowed                          |\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n
","title":"Metadata"},{"location":"docs/misconfiguration/custom/#input","text":"

You can specify input format via __rego_input__. All fields under __rego_input are optional.

Example

__rego_input__ := {\n    \"combine\": false,\n    \"selector\": [\n        {\"type\": \"kubernetes\"},\n    ],\n}\n
combine (boolean) The details is here. selector (array)

This option filters the input by file formats or configuration languages. In the above example, Trivy passes only Kubernetes files to this policy. Even if Dockerfile exists in the specified directory, it will not be passed to the policy as input.

When configuration language such as Kubernetes is not identified, file format such as JSON will be used as type. When configuration language is identified, it will overwrite type.

Example

pod.yaml including Kubernetes Pod will be handled as kubernetes, not yaml. type is overwritten by kubernetes from yaml.

type accepts kubernetes, dockerfile, ansible, cloudformation, json, yaml, toml, or hcl.

","title":"Input"},{"location":"docs/misconfiguration/custom/combine/","text":"","title":"Combined input"},{"location":"docs/misconfiguration/custom/combine/#overview","text":"

Trivy usually scans each configuration file individually. Sometimes it might be useful to compare values from different configuration files simultaneously.

When combine is set to true, all config files under the specified directory are combined into one input data structure.

Example

__rego_input__ := {\n    \"combine\": false,\n}\n

In \"combine\" mode, the input document becomes an array, where each element is an object with two fields:

  • \"path\": \"path/to/file\": the relative file path of the respective file
  • \"contents\": ...: the parsed content of the respective file

Now you can ensure that duplicate values match across the entirety of your configuration files.

","title":"Overview"},{"location":"docs/misconfiguration/custom/combine/#return-value","text":"

In \"combine\" mode, the deny entrypoint must return an object with two keys

filepath (required) the relative file path of the file being evaluated msg (required) the message describing an issue

Example

deny[res] {\n    resource := input[i].contents\n    ... some logic ...\n\n    res := {\n        \"filepath\": input[i].path,\n        \"msg\": \"something bad\",\n    }\n}\n
","title":"Return value"},{"location":"docs/misconfiguration/custom/data/","text":"

Custom policies may require additional data in order to determine an answer.

For example, an allowed list of resources that can be created. Instead of hardcoding this information inside of your policy, Trivy allows passing paths to data files with the --data flag.

Given the following yaml file:

$ cd examples/misconf/custom-data\n$ cat data/ports.yaml                                                                                                                                                                      [~/src/github.com/aquasecurity/trivy/examples/misconf/custom-data]\nservices:\n  ports:\n    - \"20\"\n    - \"20/tcp\"\n    - \"20/udp\"\n    - \"23\"\n    - \"23/tcp\"\n

This can be imported into your policy:

import data.services\n\nports := services.ports\n

Then, you need to pass data paths through --data option. Trivy recursively searches the specified paths for JSON (*.json) and YAML (*.yaml) files.

$ trivy conf --policy ./policy --data data --namespaces user ./configs\n
","title":"Custom Data"},{"location":"docs/misconfiguration/custom/debug/","text":"

When working on more complex queries (or when learning Rego), it's useful to see exactly how the policy is applied. For this purpose you can use the --trace flag. This will output a large trace from Open Policy Agent like the following:

Tip

Only failed policies show traces. If you want to debug a passed policy, you need to make it fail on purpose.

$ trivy conf --trace configs/\n2021-07-11T16:45:58.493+0300    INFO    Detected config files: 1\n\nDockerfile (dockerfile)\n=======================\nTests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)\nFailures: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |\n|                           |            |                      |          | Dockerfile should not be 'root'          |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n\nID: DS002\nFile: Dockerfile\nNamespace: appshield.dockerfile.DS002\nQuery: data.appshield.dockerfile.DS002.deny\nMessage: Last USER command in Dockerfile should not be 'root'\nTRACE  Enter data.appshield.dockerfile.DS002.deny = _\nTRACE  | Eval data.appshield.dockerfile.DS002.deny = _\nTRACE  | Index data.appshield.dockerfile.DS002.deny matched 2 rules)\nTRACE  | Enter data.appshield.dockerfile.DS002.deny\nTRACE  | | Eval data.appshield.dockerfile.DS002.fail_user_count\nTRACE  | | Index data.appshield.dockerfile.DS002.fail_user_count (matched 1 rule)\nTRACE  | | Enter data.appshield.dockerfile.DS002.fail_user_count\nTRACE  | | | Eval __local559__ = data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Index data.appshield.dockerfile.DS002.get_user (matched 1 rule)\nTRACE  | | | Enter data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Eval user = data.lib.docker.user[_]\nTRACE  | | | | Index data.lib.docker.user (matched 1 rule)\nTRACE  | | | | Enter data.lib.docker.user\nTRACE  | | | | | Eval instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Exit data.lib.docker.user\nTRACE  | | | | Eval username = user.Value[_]\nTRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Redo username = user.Value[_]\nTRACE  | | | | Redo user = data.lib.docker.user[_]\nTRACE  | | | | Redo data.lib.docker.user\nTRACE  | | | | | Redo instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Exit data.lib.docker.user\nTRACE  | | | | Eval username = user.Value[_]\nTRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Redo username = user.Value[_]\nTRACE  | | | | Redo user = data.lib.docker.user[_]\nTRACE  | | | | Redo data.lib.docker.user\nTRACE  | | | | | Redo instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | Eval count(__local559__, __local391__)\nTRACE  | | | Eval lt(__local391__, 1)\nTRACE  | | | Fail lt(__local391__, 1)\nTRACE  | | | Redo count(__local559__, __local391__)\nTRACE  | | | Redo __local559__ = data.appshield.dockerfile.DS002.get_user\nTRACE  | | Fail data.appshield.dockerfile.DS002.fail_user_count\nTRACE  | Enter data.appshield.dockerfile.DS002.deny\nTRACE  | | Eval data.appshield.dockerfile.DS002.fail_last_user_root\nTRACE  | | Index data.appshield.dockerfile.DS002.fail_last_user_root (matched 1 rule)\nTRACE  | | Enter data.appshield.dockerfile.DS002.fail_last_user_root\nTRACE  | | | Eval __local560__ = data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Index data.appshield.dockerfile.DS002.get_user (matched 1 rule)\nTRACE  | | | Enter data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Eval user = data.lib.docker.user[_]\nTRACE  | | | | Index data.lib.docker.user (matched 1 rule)\nTRACE  | | | | Enter data.lib.docker.user\nTRACE  | | | | | Eval instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Exit data.lib.docker.user\nTRACE  | | | | Eval username = user.Value[_]\nTRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Redo username = user.Value[_]\nTRACE  | | | | Redo user = data.lib.docker.user[_]\nTRACE  | | | | Redo data.lib.docker.user\nTRACE  | | | | | Redo instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Exit data.lib.docker.user\nTRACE  | | | | Eval username = user.Value[_]\nTRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Redo username = user.Value[_]\nTRACE  | | | | Redo user = data.lib.docker.user[_]\nTRACE  | | | | Redo data.lib.docker.user\nTRACE  | | | | | Redo instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | Eval cast_array(__local560__, __local392__)\nTRACE  | | | Eval user = __local392__\nTRACE  | | | Eval __local561__ = data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Index data.appshield.dockerfile.DS002.get_user (matched 1 rule)\nTRACE  | | | Enter data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Eval user = data.lib.docker.user[_]\nTRACE  | | | | Index data.lib.docker.user (matched 1 rule)\nTRACE  | | | | Enter data.lib.docker.user\nTRACE  | | | | | Eval instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Exit data.lib.docker.user\nTRACE  | | | | Eval username = user.Value[_]\nTRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Redo username = user.Value[_]\nTRACE  | | | | Redo user = data.lib.docker.user[_]\nTRACE  | | | | Redo data.lib.docker.user\nTRACE  | | | | | Redo instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Exit data.lib.docker.user\nTRACE  | | | | Eval username = user.Value[_]\nTRACE  | | | | Exit data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo data.appshield.dockerfile.DS002.get_user\nTRACE  | | | | Redo username = user.Value[_]\nTRACE  | | | | Redo user = data.lib.docker.user[_]\nTRACE  | | | | Redo data.lib.docker.user\nTRACE  | | | | | Redo instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | | | Eval instruction.Cmd = \"user\"\nTRACE  | | | | | Fail instruction.Cmd = \"user\"\nTRACE  | | | | | Redo instruction = input.stages[_][_]\nTRACE  | | | Eval count(__local561__, __local393__)\nTRACE  | | | Eval len = __local393__\nTRACE  | | | Eval minus(len, 1, __local394__)\nTRACE  | | | Eval user[__local394__] = \"root\"\nTRACE  | | | Exit data.appshield.dockerfile.DS002.fail_last_user_root\nTRACE  | | Eval res = \"Last USER command in Dockerfile should not be 'root'\"\nTRACE  | | Exit data.appshield.dockerfile.DS002.deny\nTRACE  | Redo data.appshield.dockerfile.DS002.deny\nTRACE  | | Redo res = \"Last USER command in Dockerfile should not be 'root'\"\nTRACE  | | Redo data.appshield.dockerfile.DS002.fail_last_user_root\nTRACE  | | Redo data.appshield.dockerfile.DS002.fail_last_user_root\nTRACE  | | | Redo user[__local394__] = \"root\"\nTRACE  | | | Redo minus(len, 1, __local394__)\nTRACE  | | | Redo len = __local393__\nTRACE  | | | Redo count(__local561__, __local393__)\nTRACE  | | | Redo __local561__ = data.appshield.dockerfile.DS002.get_user\nTRACE  | | | Redo user = __local392__\nTRACE  | | | Redo cast_array(__local560__, __local392__)\nTRACE  | | | Redo __local560__ = data.appshield.dockerfile.DS002.get_user\nTRACE  | Exit data.appshield.dockerfile.DS002.deny = _\nTRACE  Redo data.appshield.dockerfile.DS002.deny = _\nTRACE  | Redo data.appshield.dockerfile.DS002.deny = _\n
","title":"Debugging policies"},{"location":"docs/misconfiguration/custom/examples/","text":"","title":"Examples"},{"location":"docs/misconfiguration/custom/examples/#custom-policy","text":"","title":"Custom Policy"},{"location":"docs/misconfiguration/custom/examples/#kubernetes","text":"

See here.

The custom policy is defined in user.kubernetes.ID001 package. You need to pass the package prefix you want to evaluate through --namespaces option. In this case, the package prefix should be user, user.kuberntes, or user.kubernetes.ID001.

","title":"Kubernetes"},{"location":"docs/misconfiguration/custom/examples/#dockerfile","text":"

See here.

The input will be a dictionary of stages.

","title":"Dockerfile"},{"location":"docs/misconfiguration/custom/examples/#single-stage","text":"Example

Dockerfile

FROM foo\nCOPY . /\nRUN echo hello\n

Rego Input

{\n    \"stages\": {\n        \"foo\": [\n            {\n                \"Cmd\": \"from\",\n                \"EndLine\": 1,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"FROM foo\",\n                \"Stage\": 0,\n                \"StartLine\": 1,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"foo\"\n                ]\n            },\n            {\n                \"Cmd\": \"copy\",\n                \"EndLine\": 2,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"COPY . /\",\n                \"Stage\": 0,\n                \"StartLine\": 2,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \".\",\n                    \"/\"\n                ]\n            },\n            {\n                \"Cmd\": \"run\",\n                \"EndLine\": 3,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"RUN echo hello\",\n                \"Stage\": 0,\n                \"StartLine\": 3,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"echo hello\"\n                ]\n            }\n        ]\n    }\n}\n

","title":"Single Stage"},{"location":"docs/misconfiguration/custom/examples/#multi-stage","text":"Example

Dockerfile

FROM golang:1.16 AS builder\nWORKDIR /go/src/github.com/alexellis/href-counter/\nRUN go get -d -v golang.org/x/net/html\nCOPY app.go .\nRUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o app .\n\nFROM alpine:latest\nRUN apk --no-cache add ca-certificates \\\n&& apk add --no-cache bash\nWORKDIR /root/\nCOPY --from=builder /go/src/github.com/alexellis/href-counter/app .\nCMD [\"./app\"]\n

Rego Input

{\n    \"stages\": {\n        \"alpine:latest\": [\n            {\n                \"Cmd\": \"from\",\n                \"EndLine\": 7,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"FROM alpine:latest\",\n                \"Stage\": 1,\n                \"StartLine\": 7,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"alpine:latest\"\n                ]\n            },\n            {\n                \"Cmd\": \"run\",\n                \"EndLine\": 9,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"RUN apk --no-cache add ca-certificates     \\u0026\\u0026 apk add --no-cache bash\",\n                \"Stage\": 1,\n                \"StartLine\": 8,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"apk --no-cache add ca-certificates     \\u0026\\u0026 apk add --no-cache bash\"\n                ]\n            },\n            {\n                \"Cmd\": \"workdir\",\n                \"EndLine\": 10,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"WORKDIR /root/\",\n                \"Stage\": 1,\n                \"StartLine\": 10,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"/root/\"\n                ]\n            },\n            {\n                \"Cmd\": \"copy\",\n                \"EndLine\": 11,\n                \"Flags\": [\n                    \"--from=builder\"\n                ],\n                \"JSON\": false,\n                \"Original\": \"COPY --from=builder /go/src/github.com/alexellis/href-counter/app .\",\n                \"Stage\": 1,\n                \"StartLine\": 11,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"/go/src/github.com/alexellis/href-counter/app\",\n                    \".\"\n                ]\n            },\n            {\n                \"Cmd\": \"cmd\",\n                \"EndLine\": 12,\n                \"Flags\": [],\n                \"JSON\": true,\n                \"Original\": \"CMD [\\\"./app\\\"]\",\n                \"Stage\": 1,\n                \"StartLine\": 12,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"./app\"\n                ]\n            }\n        ],\n        \"golang:1.16 AS builder\": [\n            {\n                \"Cmd\": \"from\",\n                \"EndLine\": 1,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"FROM golang:1.16 AS builder\",\n                \"Stage\": 0,\n                \"StartLine\": 1,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"golang:1.16\",\n                    \"AS\",\n                    \"builder\"\n                ]\n            },\n            {\n                \"Cmd\": \"workdir\",\n                \"EndLine\": 2,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"WORKDIR /go/src/github.com/alexellis/href-counter/\",\n                \"Stage\": 0,\n                \"StartLine\": 2,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"/go/src/github.com/alexellis/href-counter/\"\n                ]\n                },\n            {\n                \"Cmd\": \"run\",\n                \"EndLine\": 3,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"RUN go get -d -v golang.org/x/net/html\",\n                \"Stage\": 0,\n                \"StartLine\": 3,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"go get -d -v golang.org/x/net/html\"\n                ]\n            },\n            {\n                \"Cmd\": \"copy\",\n                \"EndLine\": 4,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"COPY app.go .\",\n                \"Stage\": 0,\n                \"StartLine\": 4,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"app.go\",\n                    \".\"\n                ]\n            },\n            {\n                \"Cmd\": \"run\",\n                \"EndLine\": 5,\n                \"Flags\": [],\n                \"JSON\": false,\n                \"Original\": \"RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o app .\",\n                \"Stage\": 0,\n                \"StartLine\": 5,\n                \"SubCmd\": \"\",\n                \"Value\": [\n                    \"CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o app .\"\n                ]\n            }\n        ]\n    }\n}\n

","title":"Multi Stage"},{"location":"docs/misconfiguration/custom/examples/#docker-compose","text":"

See here.

Docker Compose uses YAML format for configurations. You can apply your Rego policies to docker-compose.yml.

","title":"Docker Compose"},{"location":"docs/misconfiguration/custom/examples/#hcl","text":"

See here.

Trivy parses HCL files and converts into structured data.

Warning

Terraform HCL files are not supported yet.

","title":"HCL"},{"location":"docs/misconfiguration/custom/examples/#terraform-plan","text":"

See here.

Use the command terraform show to convert the Terraform plan into JSON so that OPA can read the plan.

$ terraform init\n$ terraform plan --out tfplan.binary\n$ terraform show -json tfplan.binary > tfplan.json\n

For more details, see also OPA document.

","title":"Terraform Plan"},{"location":"docs/misconfiguration/custom/examples/#serverless-framework","text":"

See here.

Server Framework uses YAML format for configurations. You can apply your Rego policies to serverless.yaml.

","title":"Serverless Framework"},{"location":"docs/misconfiguration/custom/examples/#custom-data","text":"

See here.

","title":"Custom Data"},{"location":"docs/misconfiguration/custom/examples/#combined-input","text":"

See here.

","title":"Combined Input"},{"location":"docs/misconfiguration/custom/examples/#go-testing","text":"

See here.

","title":"Go Testing"},{"location":"docs/misconfiguration/custom/testing/","text":"

It is highly recommended to write tests for your custom policies.

","title":"Testing"},{"location":"docs/misconfiguration/custom/testing/#rego-testing","text":"

To help you verify the correctness of your custom policies, OPA gives you a framework that you can use to write tests for your policies. By writing tests for your custom policies you can speed up the development process of new rules and reduce the amount of time it takes to modify rules as requirements evolve.

For more details, see Policy Testing.

Example

package user.dockerfile.ID002\n\ntest_add_denied {\n    r := deny with input as {\"stages\": {\"alpine:3.13\": [\n        {\"Cmd\": \"add\", \"Value\": [\"/target/resources.tar.gz\", \"resources.jar\"]},\n        {\"Cmd\": \"add\", \"Value\": [\"/target/app.jar\", \"app.jar\"]},\n    ]}}\n\n    count(r) == 1\n    r[_] == \"Consider using 'COPY /target/app.jar app.jar' command instead of 'ADD /target/app.jar app.jar'\"\n}\n

To write tests for custom policies, you can refer to existing tests under AppShield.

","title":"Rego testing"},{"location":"docs/misconfiguration/custom/testing/#go-testing","text":"

Fanal which is a core library of Trivy can be imported as a Go library. You can scan config files in Go and test your custom policies using Go's testing methods, such as table-driven tests. This allows you to use the actual configuration file as input, making it easy to prepare test data and ensure that your custom policies work in practice.

In particular, Dockerfile and HCL need to be converted to structural data as input, which may be different from the expected input format.

Tip

We recommend writing OPA and Go tests both since they have different roles, like unit tests and integration tests.

The following example stores allowed and denied configuration files in a directory. Successes contains the result of successes, and Failures contains the result of failures.

{\n    name:  \"disallowed ports\",\n    input: \"configs/\",\n    fields: fields{\n        policyPaths: []string{\"policy\"},\n        dataPaths:   []string{\"data\"},\n        namespaces:  []string{\"user\"},\n    },\n    want: []types.Misconfiguration{\n        {\n            FileType: types.Dockerfile,\n            FilePath: \"Dockerfile.allowed\",\n            Successes: types.MisconfResults{\n                {\n                    Namespace: \"user.dockerfile.ID002\",\n                    PolicyMetadata: types.PolicyMetadata{\n                        ID:          \"ID002\",\n                        Type:        \"Docker Custom Check\",\n                        Title:       \"Disallowed ports exposed\",\n                        Severity:    \"HIGH\",\n                    },\n                },\n            },\n        },\n        {\n            FileType: types.Dockerfile,\n            FilePath: \"Dockerfile.denied\",\n            Failures: types.MisconfResults{\n                {\n                    Namespace: \"user.dockerfile.ID002\",\n                    Message:   \"Port 23 should not be exposed\",\n                    PolicyMetadata: types.PolicyMetadata{\n                        ID:          \"ID002\",\n                        Type:        \"Docker Custom Check\",\n                        Title:       \"Disallowed ports exposed\",\n                        Severity:    \"HIGH\",\n                    },\n                },\n            },\n        },\n    },\n},\n

Dockerfile.allowed has one successful result in Successes, while Dockerfile.denied has one failure result in Failures.

","title":"Go testing"},{"location":"docs/misconfiguration/options/filter/","text":"","title":"Filter Misconfigurations"},{"location":"docs/misconfiguration/options/filter/#by-severity","text":"

Use --severity option.

trivy conf --severity HIGH,CRITICAL examples/misconf/mixed\n
Result
2021-07-10T17:37:13.267+0300    INFO    Detected config files: 4\n\nconfigs/Dockerfile (dockerfile)\n===============================\nTests: 23 (SUCCESSES: 21, FAILURES: 2, EXCEPTIONS: 0)\nFailures: 2 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Specify at least 1 USER                  |\n|                           |            |                      |          | command in Dockerfile with               |\n|                           |            |                      |          | non-root user as argument                |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n\nconfigs/deployment.yaml (kubernetes)\n====================================\nTests: 28 (SUCCESSES: 14, FAILURES: 14, EXCEPTIONS: 0)\nFailures: 14 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |                CHECK                | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n| Kubernetes Security Check |   KSV006   | docker.sock is mounted to container |   HIGH   | Deployment 'hello-kubernetes' should     |\n|                           |            |                                     |          | not specify '/var/run/docker.socker' in  |\n|                           |            |                                     |          | 'spec.template.volumes.hostPath.path'    |\n|                           |            |                                     |          | -->avd.aquasec.com/appshield/ksv006      |\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n\nconfigs/main.tf (terraform)\n===========================\nTests: 19 (SUCCESSES: 11, FAILURES: 8, EXCEPTIONS: 0)\nFailures: 8 (HIGH: 6, CRITICAL: 1)\n\n+------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+\n|                   TYPE                   | MISCONF ID |                  CHECK                   | SEVERITY |                        MESSAGE                         |\n+------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+\n|   Terraform Security Check powered by    |   AWS003   | AWS Classic resource usage.              |   HIGH   | Resource                                               |\n|                  tfsec                   |            |                                          |          | 'aws_db_security_group.my-group'                       |\n|                                          |            |                                          |          | uses EC2 Classic. Use a VPC instead.                   |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS003/                          |\n+                                          +------------+------------------------------------------+----------+--------------------------------------------------------+\n|                                          |   AWS004   | Use of plain HTTP.                       | CRITICAL | Resource                                               |\n|                                          |            |                                          |          | 'aws_alb_listener.my-alb-listener'                     |\n|                                          |            |                                          |          | uses plain HTTP instead of HTTPS.                      |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS004/                          |\n+                                          +------------+------------------------------------------+----------+--------------------------------------------------------+\n|                                          |   AWS018   | Missing description for security         |   HIGH   | Resource                                               |\n|                                          |            | group/security group rule.               |          | 'aws_security_group_rule.my-rule' should               |\n|                                          |            |                                          |          | include a description for auditing                     |\n|                                          |            |                                          |          | purposes. -->tfsec.dev/docs/aws/AWS018/                |\n+                                          +------------+------------------------------------------+          +--------------------------------------------------------+\n|                                          |   AWS025   | API Gateway domain name uses outdated    |          | Resource                                               |\n|                                          |            | SSL/TLS protocols.                       |          | 'aws_api_gateway_domain_name.empty_security_policy'    |\n|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using           |\n|                                          |            |                                          |          | TLS_1_2). -->tfsec.dev/docs/aws/AWS025/                |\n+                                          +            +                                          +          +--------------------------------------------------------+\n|                                          |            |                                          |          | Resource                                               |\n|                                          |            |                                          |          | 'aws_api_gateway_domain_name.missing_security_policy'  |\n|                                          |            |                                          |          | should include security_policy (defaults to outdated   |\n|                                          |            |                                          |          | SSL/TLS policy). -->tfsec.dev/docs/aws/AWS025/         |\n+                                          +            +                                          +          +--------------------------------------------------------+\n|                                          |            |                                          |          | Resource                                               |\n|                                          |            |                                          |          | 'aws_api_gateway_domain_name.outdated_security_policy' |\n|                                          |            |                                          |          | defines outdated SSL/TLS policies (not using TLS_1_2). |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS025/                          |\n+                                          +------------+------------------------------------------+          +--------------------------------------------------------+\n|                                          |   AZU003   | Unencrypted managed disk.                |          | Resource 'azurerm_managed_disk.source'                 |\n|                                          |            |                                          |          | defines an unencrypted managed disk.                   |\n|                                          |            |                                          |          | -->tfsec.dev/docs/azure/AZU003/                        |\n+------------------------------------------+------------+------------------------------------------+----------+--------------------------------------------------------+\n\nconfigs/variables.tf (terraform)\n================================\nTests: 1 (SUCCESSES: 1, FAILURES: 0, EXCEPTIONS: 0)\nFailures: 0 (HIGH: 0, CRITICAL: 0)\n
","title":"By Severity"},{"location":"docs/misconfiguration/options/filter/#by-misconfiguration-ids","text":"

Use .trivyignore.

$ cat .trivyignore\n# Accept the risk\nAWS003\nAWS018\nAWS025\n\n$ trivy conf --severity HIGH,CRITICAL examples/misconf/mixed\n
Result
2021-07-10T17:38:51.306+0300    INFO    Detected config files: 4\n\nconfigs/Dockerfile (dockerfile)\n===============================\nTests: 23 (SUCCESSES: 21, FAILURES: 2, EXCEPTIONS: 0)\nFailures: 2 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Specify at least 1 USER                  |\n|                           |            |                      |          | command in Dockerfile with               |\n|                           |            |                      |          | non-root user as argument                |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n\nconfigs/deployment.yaml (kubernetes)\n====================================\nTests: 28 (SUCCESSES: 14, FAILURES: 14, EXCEPTIONS: 0)\nFailures: 14 (HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |                CHECK                | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n| Kubernetes Security Check |   KSV006   | docker.sock is mounted to container |   HIGH   | Deployment 'hello-kubernetes' should     |\n|                           |            |                                     |          | not specify '/var/run/docker.socker' in  |\n|                           |            |                                     |          | 'spec.template.volumes.hostPath.path'    |\n|                           |            |                                     |          | -->avd.aquasec.com/appshield/ksv006      |\n+---------------------------+------------+-------------------------------------+----------+------------------------------------------+\n\nconfigs/main.tf (terraform)\n===========================\nTests: 19 (SUCCESSES: 11, FAILURES: 8, EXCEPTIONS: 0)\nFailures: 8 (HIGH: 1, CRITICAL: 1)\n\n+------------------------------------------+------------+---------------------------+----------+------------------------------------------+\n|                   TYPE                   | MISCONF ID |           CHECK           | SEVERITY |                 MESSAGE                  |\n+------------------------------------------+------------+---------------------------+----------+------------------------------------------+\n|   Terraform Security Check powered by    |   AWS004   | Use of plain HTTP.        | CRITICAL | Resource                                 |\n|                  tfsec                   |            |                           |          | 'aws_alb_listener.my-alb-listener'       |\n|                                          |            |                           |          | uses plain HTTP instead of HTTPS.        |\n|                                          |            |                           |          | -->tfsec.dev/docs/aws/AWS004/            |\n+                                          +------------+---------------------------+----------+------------------------------------------+\n|                                          |   AZU003   | Unencrypted managed disk. |   HIGH   | Resource 'azurerm_managed_disk.source'   |\n|                                          |            |                           |          | defines an unencrypted managed disk.     |\n|                                          |            |                           |          | -->tfsec.dev/docs/azure/AZU003/          |\n+------------------------------------------+------------+---------------------------+----------+------------------------------------------+\n\nconfigs/variables.tf (terraform)\n================================\nTests: 1 (SUCCESSES: 1, FAILURES: 0, EXCEPTIONS: 0)\nFailures: 0 (HIGH: 0, CRITICAL: 0)\n
","title":"By Misconfiguration IDs"},{"location":"docs/misconfiguration/options/filter/#by-exceptions","text":"

See Exceptions

","title":"By Exceptions"},{"location":"docs/misconfiguration/options/filter/#show-successes-and-exceptions","text":"

Use --include-non-failures option to show successes and exceptions as well as failures.

trivy conf --severity CRITICAL --include-non-failures examples/misconf/mixed\n
Result
2021-07-10T17:44:02.049+0300    INFO    Detected config files: 4\n\nconfigs/Dockerfile (dockerfile)\n===============================\nTests: 23 (SUCCESSES: 21, FAILURES: 2, EXCEPTIONS: 0)\nFailures: 2 (CRITICAL: 0)\n\n+---------------------------+------------+------------------------------------------+----------+--------+-----------------+\n|           TYPE            | MISCONF ID |                  CHECK                   | SEVERITY | STATUS |     MESSAGE     |\n+---------------------------+------------+------------------------------------------+----------+--------+-----------------+\n| Dockerfile Security Check |   DS006    | COPY '--from' refers to the current      | CRITICAL |  PASS  | No issues found |\n|                           |            | image                                    |          |        |                 |\n+                           +------------+------------------------------------------+          +        +                 +\n|                           |   DS007    | Multiple ENTRYPOINT instructions are     |          |        |                 |\n|                           |            | listed                                   |          |        |                 |\n+                           +------------+------------------------------------------+          +        +                 +\n|                           |   DS008    | Exposed port is out of range             |          |        |                 |\n+                           +------------+------------------------------------------+          +        +                 +\n|                           |   DS010    | 'sudo' is used                           |          |        |                 |\n+                           +------------+------------------------------------------+          +        +                 +\n|                           |   DS011    | COPY with more than two arguments is not |          |        |                 |\n|                           |            | ending with slash                        |          |        |                 |\n+                           +------------+------------------------------------------+          +        +                 +\n|                           |   DS012    | Duplicate aliases are defined in         |          |        |                 |\n|                           |            | different FROMs                          |          |        |                 |\n+---------------------------+------------+------------------------------------------+----------+--------+-----------------+\n\n...\n
","title":"Show Successes and Exceptions"},{"location":"docs/misconfiguration/options/others/","text":"

Hint

See also Others in Vulnerability section.

","title":"Others"},{"location":"docs/misconfiguration/options/others/#file-patterns","text":"

When a directory is given as an input, Trivy will recursively look for and test all files based on file patterns. The default file patterns are here.

In addition to the default file patterns, the --file-patterns option takes regexp patterns to look for your files. For example, it may be useful when your file name of Dockerfile doesn't match the default patterns.

This can be repeated for specifying multiple file patterns. Allowed values are here:

  • dockerfile
  • yaml
  • json
  • toml
  • hcl

For more details, see an example

","title":"File patterns"},{"location":"docs/misconfiguration/options/policy/","text":"","title":"Policy"},{"location":"docs/misconfiguration/options/policy/#pass-custom-policies","text":"

You can pass directories including your custom policies through --policy option. This can be repeated for specifying multiple directories.

cd examplex/misconf/\ntrivy conf --policy custom-policy/policy --policy combine/policy --namespaces user misconf/mixed\n

For more details, see Custom Policies.

Tip

You also need to specify --namespaces option.

","title":"Pass custom policies"},{"location":"docs/misconfiguration/options/policy/#pass-custom-data","text":"

You can pass directories including your custom data through --data option. This can be repeated for specifying multiple directories.

cd examples/misconf/custom-data\ntrivy conf --policy ./policy --data ./data --namespaces user ./configs\n

For more details, see Custom Data.

","title":"Pass custom data"},{"location":"docs/misconfiguration/options/policy/#pass-namespaces","text":"

By default, Trivy evaluate policies defined in appshield.*. If you want to evaluate custom policies in other packages, you have to specify package prefixes through --namespaces option. This can be repeated for specifying multiple packages.

trivy conf --policy ./policy --namespaces main --namespaces user ./configs\n
","title":"Pass namespaces"},{"location":"docs/misconfiguration/options/policy/#skip-update-of-built-in-policies","text":"

Trivy downloads built-in policies when it starts operating. Then, it checks for updates every 24 hours. You can use the --skip-policy-update option to skip it. If you skip it the first time, the built-in policies will not be loaded.

Note

Even if you specify the option the first time, it will be loaded as Terraform policies are written in Go.

trivy conf --skip-policy-update examples/misconf/mixed                                                                                           [~/src/github.com/aquasecurity/trivy]\n
Result
2021-07-10T18:04:19.083+0300    INFO    No builtin policies were loaded\n2021-07-10T18:04:19.174+0300    INFO    Detected config files: 2\n\nconfigs/main.tf (terraform)\n===========================\nTests: 19 (SUCCESSES: 11, FAILURES: 8, EXCEPTIONS: 0)\nFailures: 8 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 1, CRITICAL: 1)\n\n+------------------------------------------+------------+------------------------------------------+----------+------------------------------------------+\n|                   TYPE                   | MISCONF ID |                  CHECK                   | SEVERITY |                 MESSAGE                  |\n+------------------------------------------+------------+------------------------------------------+----------+------------------------------------------+\n|   Terraform Security Check powered by    |   AWS004   | Use of plain HTTP.                       | CRITICAL | Resource                                 |\n|                  tfsec                   |            |                                          |          | 'aws_alb_listener.my-alb-listener'       |\n|                                          |            |                                          |          | uses plain HTTP instead of HTTPS.        |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS004/            |\n+                                          +------------+------------------------------------------+----------+------------------------------------------+\n|                                          |   AWS006   | An ingress security group rule allows    |  MEDIUM  | Resource                                 |\n|                                          |            | traffic from /0.                         |          | 'aws_security_group_rule.my-rule'        |\n|                                          |            |                                          |          | defines a fully open                     |\n|                                          |            |                                          |          | ingress security group rule.             |\n|                                          |            |                                          |          | -->tfsec.dev/docs/aws/AWS006/            |\n+                                          +------------+------------------------------------------+----------+------------------------------------------+\n|                                          |   AZU003   | Unencrypted managed disk.                |   HIGH   | Resource 'azurerm_managed_disk.source'   |\n|                                          |            |                                          |          | defines an unencrypted managed disk.     |\n|                                          |            |                                          |          | -->tfsec.dev/docs/azure/AZU003/          |\n+------------------------------------------+------------+------------------------------------------+----------+------------------------------------------+\n\nconfigs/variables.tf (terraform)\n================================\nTests: 1 (SUCCESSES: 1, FAILURES: 0, EXCEPTIONS: 0)\nFailures: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)\n
","title":"Skip update of built-in policies"},{"location":"docs/misconfiguration/options/report/","text":"

See Reports Formats in Vulnerability section.

Caution

Misconfiguration scanning doesn't support default templates such as XML for now.

","title":"Report Formats"},{"location":"docs/misconfiguration/policy/builtin/","text":"","title":"Built-in Policies"},{"location":"docs/misconfiguration/policy/builtin/#policy-sources","text":"

Built-in policies are mainly written in Rego. Those policies are managed under AppShield repository. Terraform policies are currently powered by tfsec and CloudFormation policies are powered by cfsec.

Config type Source Kubernetes AppShield Dockerfile AppShield Terraform tfsec CloudFormation cfsec

For suggestions or issues regarding policy content, please open an issue under AppShield, tfsec or cfsec repository.

Ansible are coming soon.

","title":"Policy Sources"},{"location":"docs/misconfiguration/policy/builtin/#policy-distribution","text":"

AppShield policies are distributed as an OPA bundle on GitHub Container Registry (GHCR). When misconfiguration detection is enabled, Trivy pulls the OPA bundle from GHCR as an OCI artifact and stores it in the cache. Those policies are then loaded into Trivy OPA engine and used for detecting misconfigurations.

","title":"Policy Distribution"},{"location":"docs/misconfiguration/policy/builtin/#update-interval","text":"

Trivy checks for updates to OPA bundle on GHCR every 24 hours and pulls it if there are any updates.

","title":"Update Interval"},{"location":"docs/misconfiguration/policy/exceptions/","text":"

Exceptions lets you to specify cases where you allow policy violations. Trivy supports two types of exceptions.

Info

Exceptions can be applied to built-in policies as well as custom policies.

","title":"Exceptions"},{"location":"docs/misconfiguration/policy/exceptions/#namespace-based-exceptions","text":"

There are some cases where you need to disable built-in policies partially or fully. Namespace-based exceptions lets you rough choose which individual packages to exempt.

To use namespace-based exceptions, create a Rego rule with the name exception that returns the package names to exempt. The exception rule must be defined under namespace.exceptions. data.namespaces includes all package names.

Example

package namespace.exceptions\n\nimport data.namespaces\n\nexception[ns] {\n    ns := data.namespaces[_]\n    startswith(ns, \"appshield\")\n}\n

This example exempts all built-in policies for Kubernetes.

For more details, see an example.

","title":"Namespace-based exceptions"},{"location":"docs/misconfiguration/policy/exceptions/#rule-based-exceptions","text":"

There are some cases where you need more flexibility and granularity in defining which cases to exempt. Rule-based exceptions lets you granularly choose which individual rules to exempt, while also declaring under which conditions to exempt them.

To use rule-based exceptions, create a Rego rule with the name exception that returns the rule name suffixes to exempt, prefixed by deny_ (for example, returning foo will exempt deny_foo). The rule can make any other assertion, for example, on the input or data documents. This is useful to specify the exemption for a specific case.

Note that if you specify the empty string, the exception will match all rules named deny.

exception[rules] {\n    # Logic\n\n    rules = [\"foo\",\"bar\"]\n}\n

The above would provide an exception from deny_foo and deny_bar.

Example

package user.kubernetes.ID100\n\n__rego_metadata := {\n    \"id\": \"ID100\",\n    \"title\": \"Deployment not allowed\",\n    \"severity\": \"HIGH\",\n    \"type\": \"Kubernetes Custom Check\",\n}\n\ndeny_deployment[msg] {\n    input.kind == \"Deployment\"\n    msg = sprintf(\"Found deployment '%s' but deployments are not allowed\", [name])\n}\n\nexception[rules] {\n    input.kind == \"Deployment\"\n    input.metadata.name == \"allow-deployment\"\n\n    rules := [\"deployment\"]\n}\n

If you want to apply rule-based exceptions to built-in policies, you have to define the exception under the same package.

Example

package appshield.kubernetes.KSV012\n\nexception[rules] {\n    input.metadata.name == \"can-run-as-root\"\n    rules := [\"\"]\n}\n

This exception is applied to KSV012 in AppShield. You can get the package names in AppShield repository or the JSON output from Trivy.

For more details, see an example.

","title":"Rule-based exceptions"},{"location":"docs/references/troubleshooting/","text":"","title":"Troubleshooting"},{"location":"docs/references/troubleshooting/#scan","text":"","title":"Scan"},{"location":"docs/references/troubleshooting/#timeout","text":"

Error

$ trivy image ...\n...\nanalyze error: timeout: context deadline exceeded\n

Your scan may time out. Java takes a particularly long time to scan. Try increasing the value of the ---timeout option such as --timeout 15m.

","title":"Timeout"},{"location":"docs/references/troubleshooting/#certification","text":"

Error

Error: x509: certificate signed by unknown authority

TRIVY_INSECURE can be used to allow insecure connections to a container registry when using SSL.

$ TRIVY_INSECURE=true trivy image [YOUR_IMAGE]\n
","title":"Certification"},{"location":"docs/references/troubleshooting/#github-rate-limiting","text":"

Error

$ trivy image ...\n...\nAPI rate limit exceeded for xxx.xxx.xxx.xxx.\n

Specify GITHUB_TOKEN for authentication https://developer.github.com/v3/#rate-limiting

$ GITHUB_TOKEN=XXXXXXXXXX trivy alpine:3.10\n
","title":"GitHub Rate limiting"},{"location":"docs/references/troubleshooting/#maven-rate-limiting-inconsistent-jar-vulnerability-reporting","text":"

Error

$ trivy image ...\n...\nstatus 403 Forbidden from http://search.maven.org/solrsearch/select\n

Trivy calls Maven API for better detection of JAR files, but many requests may exceed rate limiting. This can easily happen if you are running more than one instance of Trivy which is concurrently scanning multiple images. Once this starts happening Trivy's vulnerability reporting on jar files may become inconsistent. There are two options to resolve this issue:

The first is to enable offline scanning using the --offline-scan option to stop Trivy from making API requests. This option affects only vulnerability scanning. The vulnerability database and builtin policies are downloaded as usual. If you want to skip them as well, you can try --skip-update and --skip-policy-update. Note that a number of vulnerabilities might be fewer than without the --offline-scan option.

The second, more scalable, option is the place Trivy behind a rate-limiting forward-proxy to the Maven Central API. One way to achieve this is to use nginx. You can use the following nginx config to enable both rate-limiting and caching (the caching greatly reduces the number of calls to the Maven Central API, especially if you are scanning a lot of similar images):

limit_req_zone global zone=maven:1m rate=10r/s;\nproxy_cache_path /tmp/cache keys_zone=mavencache:10m;\n\nserver {\n  listen 80;\n  proxy_cache mavencache;\n\n  location / {\n    limit_req zone=maven burst=1000;\n    proxy_cache_valid any 1h;\n    proxy_pass https://search.maven.org:443;\n  }\n}\n

This config file will allow a maximum of 10 requests per second to the Maven API, this number was determined experimentally so you might want to use something else if it doesn't fit your needs.

Once nginx is up and running, you need to tell all your Trivy deployments to proxy their Maven API calls through nginx. You can do this by setting the MAVEN_CENTRAL_URL environment variable. For example, if your nginx proxy is running at 127.0.0.1, you can set MAVEN_CENTRAL_URL=http://127.0.0.1/solrsearch/select.

","title":"Maven rate limiting / inconsistent jar vulnerability reporting"},{"location":"docs/references/troubleshooting/#running-in-parallel-takes-same-time-as-series-run","text":"

When running trivy on multiple images simultaneously, it will take same time as running trivy in series. This is because of a limitation of boltdb.

Bolt obtains a file lock on the data file so multiple processes cannot open the same database at the same time. Opening an already open Bolt database will cause it to hang until the other process closes it.

Reference : boltdb: Opening a database.

","title":"Running in parallel takes same time as series run"},{"location":"docs/references/troubleshooting/#error-downloading-vulnerability-db","text":"

Error

FATAL failed to download vulnerability DB

If trivy is running behind corporate firewall, you have to add the following urls to your allowlist.

  • ghcr.io
  • pkg-containers.githubusercontent.com
","title":"Error downloading vulnerability DB"},{"location":"docs/references/troubleshooting/#old-db-schema","text":"

Error

--skip-update cannot be specified with the old DB schema.

Trivy v0.23.0 or later requires Trivy DB v2. Please update your local database or follow [the instruction of air-gapped environment][../advanced/air-gap.md].

","title":"Old DB schema"},{"location":"docs/references/troubleshooting/#homebrew","text":"","title":"Homebrew"},{"location":"docs/references/troubleshooting/#scope-error","text":"

Error

Error: Your macOS keychain GitHub credentials do not have sufficient scope!

$ brew tap aquasecurity/trivy\nError: Your macOS keychain GitHub credentials do not have sufficient scope!\nScopes they need: none\nScopes they have:\nCreate a personal access token:\nhttps://github.com/settings/tokens/new?scopes=gist,public_repo&description=Homebrew\necho 'export HOMEBREW_GITHUB_API_TOKEN=your_token_here' >> ~/.zshrc\n

Try:

$ printf \"protocol=https\\nhost=github.com\\n\" | git credential-osxkeychain erase\n
","title":"Scope error"},{"location":"docs/references/troubleshooting/#already-installed","text":"

Error

Error: aquasecurity/trivy/trivy 64 already installed

$ brew upgrade\n...\nError: aquasecurity/trivy/trivy 64 already installed\n

Try:

$ brew unlink trivy && brew uninstall trivy\n($ rm -rf /usr/local/Cellar/trivy/64)\n$ brew install aquasecurity/trivy/trivy\n
","title":"Already installed"},{"location":"docs/references/troubleshooting/#others","text":"","title":"Others"},{"location":"docs/references/troubleshooting/#unknown-error","text":"

Try again with --reset option:

$ trivy image --reset\n
","title":"Unknown error"},{"location":"docs/references/cli/","text":"

Trivy has several sub commands, image, fs, repo, client and server.

NAME:\n   trivy - A simple and comprehensive vulnerability scanner for containers\n\nUSAGE:\n   trivy [global options] command [command options] target\n\nVERSION:\n   dev\n\nCOMMANDS:\n   image, i          scan an image\n   filesystem, fs    scan local filesystem\n   repository, repo  scan remote repository\n   client, c         client mode\n   server, s         server mode\n   config, conf      scan config files\n   plugin, p         manage plugins\n   version           print the version\n   help, h           Shows a list of commands or help for one command\n\nGLOBAL OPTIONS:\n   --quiet, -q        suppress progress bar and log output (default: false) [$TRIVY_QUIET]\n   --debug, -d        debug mode (default: false) [$TRIVY_DEBUG]\n   --cache-dir value  cache directory (default: \"/Users/teppei/Library/Caches/trivy\") [$TRIVY_CACHE_DIR]\n   --help, -h         show help (default: false)\n   --version, -v      print the version (default: false)\n
","title":"Overview"},{"location":"docs/references/cli/client/","text":"
NAME:\n   trivy client - client mode\n\nUSAGE:\n   trivy client [command options] image_name\n\nOPTIONS:\n   --template value, -t value  output template [$TRIVY_TEMPLATE]\n   --format value, -f value    format (table, json, sarif, template) (default: \"table\") [$TRIVY_FORMAT]\n   --input value, -i value     input file path instead of image name [$TRIVY_INPUT]\n   --severity value, -s value  severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --output value, -o value    output file name [$TRIVY_OUTPUT]\n   --exit-code value           Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]\n   --clear-cache, -c           clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --ignore-unfixed            display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]\n   --removed-pkgs              detect vulnerabilities of removed packages (only for Alpine) (default: false) [$TRIVY_REMOVED_PKGS]\n   --vuln-type value           comma-separated list of vulnerability types (os,library) (default: \"os,library\") [$TRIVY_VULN_TYPE]\n   --ignorefile value          specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --timeout value             timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --ignore-policy value       specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]\n   --list-all-pkgs             enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]\n   --offline-scan              do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]\n   --token value               for authentication [$TRIVY_TOKEN]\n   --token-header value        specify a header name for token (default: \"Trivy-Token\") [$TRIVY_TOKEN_HEADER]\n   --remote value              server address (default: \"http://localhost:4954\") [$TRIVY_REMOTE]\n   --custom-headers value      custom headers [$TRIVY_CUSTOM_HEADERS]\n   --help, -h                  show help (default: false)\n
","title":"Client"},{"location":"docs/references/cli/config/","text":"
NAME:\n   trivy config - scan config files\n\nUSAGE:\n   trivy config [command options] dir\n\nOPTIONS:\n   --template value, -t value                     output template [$TRIVY_TEMPLATE]\n   --format value, -f value                       format (table, json, sarif, template) (default: \"table\") [$TRIVY_FORMAT]\n   --severity value, -s value                     severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --output value, -o value                       output file name [$TRIVY_OUTPUT]\n   --exit-code value                              Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]\n   --skip-policy-update                           skip updating built-in policies (default: false) [$TRIVY_SKIP_POLICY_UPDATE]\n   --reset                                        remove all caches and database (default: false) [$TRIVY_RESET]\n   --clear-cache, -c                              clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --ignorefile value                             specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --timeout value                                timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --skip-files value                             specify the file paths to skip traversal [$TRIVY_SKIP_FILES]\n   --skip-dirs value                              specify the directories where the traversal is skipped [$TRIVY_SKIP_DIRS]\n   --policy value, --config-policy value          specify paths to the Rego policy files directory, applying config files [$TRIVY_POLICY]\n   --data value, --config-data value              specify paths from which data for the Rego policies will be recursively loaded [$TRIVY_DATA]\n   --policy-namespaces value, --namespaces value  Rego namespaces (default: \"users\") [$TRIVY_POLICY_NAMESPACES]\n   --file-patterns value                          specify file patterns [$TRIVY_FILE_PATTERNS]\n   --include-successes                            include successes of misconfigurations (default: false) [$TRIVY_INCLUDE_SUCCESSES]\n   --help, -h                                     show help (default: false)\n
","title":"Config"},{"location":"docs/references/cli/fs/","text":"
NAME:\n   trivy filesystem - scan local filesystem\n\nUSAGE:\n   trivy filesystem [command options] dir\n\nOPTIONS:\n   --template value, -t value                     output template [$TRIVY_TEMPLATE]\n   --format value, -f value                       format (table, json, sarif, template) (default: \"table\") [$TRIVY_FORMAT]\n   --severity value, -s value                     severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --output value, -o value                       output file name [$TRIVY_OUTPUT]\n   --exit-code value                              Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]\n   --skip-db-update, --skip-update                skip updating vulnerability database (default: false) [$TRIVY_SKIP_UPDATE, $TRIVY_SKIP_DB_UPDATE]\n   --skip-policy-update                           skip updating built-in policies (default: false) [$TRIVY_SKIP_POLICY_UPDATE]\n   --clear-cache, -c                              clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --ignore-unfixed                               display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]\n   --vuln-type value                              comma-separated list of vulnerability types (os,library) (default: \"os,library\") [$TRIVY_VULN_TYPE]\n   --security-checks value                        comma-separated list of what security issues to detect (vuln,config) (default: \"vuln\") [$TRIVY_SECURITY_CHECKS]\n   --ignorefile value                             specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --cache-backend value                          cache backend (e.g. redis://localhost:6379) (default: \"fs\") [$TRIVY_CACHE_BACKEND]\n   --timeout value                                timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --no-progress                                  suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]\n   --ignore-policy value                          specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]\n   --list-all-pkgs                                enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]\n   --offline-scan                                 do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]\n   --skip-files value                             specify the file paths to skip traversal [$TRIVY_SKIP_FILES]\n   --skip-dirs value                              specify the directories where the traversal is skipped [$TRIVY_SKIP_DIRS]\n   --config-policy value                          specify paths to the Rego policy files directory, applying config files [$TRIVY_CONFIG_POLICY]\n   --config-data value                            specify paths from which data for the Rego policies will be recursively loaded [$TRIVY_CONFIG_DATA]\n   --policy-namespaces value, --namespaces value  Rego namespaces (default: \"users\") [$TRIVY_POLICY_NAMESPACES]\n   --server value                                 server address [$TRIVY_SERVER]\n   --token value                                  for authentication [$TRIVY_TOKEN]\n   --token-header value                           specify a header name for token (default: \"Trivy-Token\") [$TRIVY_TOKEN_HEADER]\n   --custom-headers value                         custom headers [$TRIVY_CUSTOM_HEADERS]\n   --help, -h                                     show help (default: false)\n
","title":"Filesystem"},{"location":"docs/references/cli/image/","text":"
NAME:\n   trivy image - scan an image\n\nUSAGE:\n   trivy image [command options] image_name\n\nOPTIONS:\n   --template value, -t value  output template [$TRIVY_TEMPLATE]\n   --format value, -f value    format (table, json, sarif, template) (default: \"table\") [$TRIVY_FORMAT]\n   --input value, -i value     input file path instead of image name [$TRIVY_INPUT]\n   --severity value, -s value  severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --output value, -o value    output file name [$TRIVY_OUTPUT]\n   --exit-code value           Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]\n   --skip-update               skip db update (default: false) [$TRIVY_SKIP_UPDATE]\n   --download-db-only          download/update vulnerability database but don't run a scan (default: false) [$TRIVY_DOWNLOAD_DB_ONLY]\n   --reset                     remove all caches and database (default: false) [$TRIVY_RESET]\n   --clear-cache, -c           clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --no-progress               suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]\n   --ignore-unfixed            display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]\n   --removed-pkgs              detect vulnerabilities of removed packages (only for Alpine) (default: false) [$TRIVY_REMOVED_PKGS]\n   --vuln-type value           comma-separated list of vulnerability types (os,library) (default: \"os,library\") [$TRIVY_VULN_TYPE]\n   --ignorefile value          specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --timeout value             timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --ignore-policy value       specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]\n   --list-all-pkgs             enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]\n   --offline-scan              do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]\n   --skip-files value          specify the file path to skip traversal [$TRIVY_SKIP_FILES]\n   --skip-dirs value           specify the directory where the traversal is skipped [$TRIVY_SKIP_DIRS]\n   --cache-backend value       cache backend (e.g. redis://localhost:6379) (default: \"fs\") [$TRIVY_CACHE_BACKEND]\n   --help, -h                  show help (default: false)\n
","title":"Image"},{"location":"docs/references/cli/plugins/","text":"

Trivy provides a plugin feature to allow others to extend the Trivy CLI without the need to change the Trivycode base. This plugin system was inspired by the plugin system used in kubectl, Helm, and Conftest.

","title":"Plugins"},{"location":"docs/references/cli/plugins/#overview","text":"

Trivy plugins are add-on tools that integrate seamlessly with Trivy. They provide a way to extend the core feature set of Trivy, but without requiring every new feature to be written in Go and added to the core tool.

  • They can be added and removed from a Trivy installation without impacting the core Trivy tool.
  • They can be written in any programming language.
  • They integrate with Trivy, and will show up in Trivy help and subcommands.

Warning

Trivy plugins available in public are not audited for security. You should install and run third-party plugins at your own risk, since they are arbitrary programs running on your machine.

","title":"Overview"},{"location":"docs/references/cli/plugins/#installing-a-plugin","text":"

A plugin can be installed using the trivy plugin install command. This command takes a url and will download the plugin and install it in the plugin cache.

Trivy adheres to the XDG specification, so the location depends on whether XDG_DATA_HOME is set. Trivy will now search XDG_DATA_HOME for the location of the Trivy plugins cache. The preference order is as follows:

  • XDG_DATA_HOME if set and .trivy/plugins exists within the XDG_DATA_HOME dir
  • ~/.trivy/plugins

Under the hood Trivy leverages go-getter to download plugins. This means the following protocols are supported for downloading plugins:

  • OCI Registries
  • Local Files
  • Git
  • HTTP/HTTPS
  • Mercurial
  • Amazon S3
  • Google Cloud Storage

For example, to download the Kubernetes Trivy plugin you can execute the following command:

$ trivy plugin install github.com/aquasecurity/trivy-plugin-kubectl\n
","title":"Installing a Plugin"},{"location":"docs/references/cli/plugins/#using-plugins","text":"

Once the plugin is installed, Trivy will load all available plugins in the cache on the start of the next Trivy execution. A plugin will be made in the Trivy CLI based on the plugin name. To display all plugins, you can list them by trivy --help

$ trivy --help\nNAME:\n   trivy - A simple and comprehensive vulnerability scanner for containers\n\nUSAGE:\n   trivy [global options] command [command options] target\n\nVERSION:\n   dev\n\nCOMMANDS:\n   image, i          scan an image\n   filesystem, fs    scan local filesystem\n   repository, repo  scan remote repository\n   client, c         client mode\n   server, s         server mode\n   plugin, p         manage plugins\n   kubectl           scan kubectl resources\n   help, h           Shows a list of commands or help for one command\n

As shown above, kubectl subcommand exists in the COMMANDS section. To call the kubectl plugin and scan existing Kubernetes deployments, you can execute the following command:

$ trivy kubectl deployment <deployment-id> -- --ignore-unfixed --severity CRITICAL\n

Internally the kubectl plugin calls the kubectl binary to fetch information about that deployment and passes the using images to Trivy. You can see the detail here.

If you want to omit even the subcommand, you can use TRIVY_RUN_AS_PLUGIN environment variable.

$ TRIVY_RUN_AS_PLUGIN=kubectl trivy job your-job -- --format json\n
","title":"Using Plugins"},{"location":"docs/references/cli/plugins/#installing-and-running-plugins-on-the-fly","text":"

trivy plugin run installs a plugin and runs it on the fly. If the plugin is already present in the cache, the installation is skipped.

trivy plugin run github.com/aquasecurity/trivy-plugin-kubectl pod your-pod -- --exit-code 1\n
","title":"Installing and Running Plugins on the fly"},{"location":"docs/references/cli/plugins/#uninstalling-plugins","text":"

Specify a plugin name with trivy plugin uninstall command.

$ trivy plugin uninstall kubectl\n
","title":"Uninstalling Plugins"},{"location":"docs/references/cli/plugins/#building-plugins","text":"

Each plugin has a top-level directory, and then a plugin.yaml file.

your-plugin/\n  |\n  |- plugin.yaml\n  |- your-plugin.sh\n

In the example above, the plugin is contained inside of a directory named your-plugin. It has two files: plugin.yaml (required) and an executable script, your-plugin.sh (optional).

The core of a plugin is a simple YAML file named plugin.yaml. Here is an example YAML of trivy-plugin-kubectl plugin that adds support for Kubernetes scanning.

name: \"kubectl\"\nrepository: github.com/aquasecurity/trivy-plugin-kubectl\nversion: \"0.1.0\"\nusage: scan kubectl resources\ndescription: |-\n  A Trivy plugin that scans the images of a kubernetes resource.\n  Usage: trivy kubectl TYPE[.VERSION][.GROUP] NAME\nplatforms:\n  - selector: # optional\n      os: darwin\n      arch: amd64\n    uri: ./trivy-kubectl # where the execution file is (local file, http, git, etc.)\n    bin: ./trivy-kubectl # path to the execution file\n  - selector: # optional\n      os: linux\n      arch: amd64\n    uri: https://github.com/aquasecurity/trivy-plugin-kubectl/releases/download/v0.1.0/trivy-kubectl.tar.gz\n    bin: ./trivy-kubectl\n

The plugin.yaml field should contain the following information:

  • name: The name of the plugin. This also determines how the plugin will be made available in the Trivy CLI. For example, if the plugin is named kubectl, you can call the plugin with trivy kubectl. (required)
  • version: The version of the plugin. (required)
  • usage: A short usage description. (required)
  • description: A long description of the plugin. This is where you could provide a helpful documentation of your plugin. (required)
  • platforms: (required)
  • selector: The OS/Architecture specific variations of a execution file. (optional)
    • os: OS information based on GOOS (linux, darwin, etc.) (optional)
    • arch: The architecture information based on GOARCH (amd64, arm64, etc.) (optional)
  • uri: Where the executable file is. Relative path from the root directory of the plugin or remote URL such as HTTP and S3. (required)
  • bin: Which file to call when the plugin is executed. Relative path from the root directory of the plugin. (required)

The following rules will apply in deciding which platform to select:

  • If both os and arch under selector match the current platform, search will stop and the platform will be used.
  • If selector is not present, the platform will be used.
  • If os matches and there is no more specific arch match, the platform will be used.
  • If no platform match is found, Trivy will exit with an error.

After determining platform, Trivy will download the execution file from uri and store it in the plugin cache. When the plugin is called via Trivy CLI, bin command will be executed.

The plugin is responsible for handling flags and arguments. Any arguments are passed to the plugin from the trivy command.

","title":"Building Plugins"},{"location":"docs/references/cli/plugins/#example","text":"

https://github.com/aquasecurity/trivy-plugin-kubectl

","title":"Example"},{"location":"docs/references/cli/repo/","text":"
NAME:\n   trivy repository - scan remote repository\n\nUSAGE:\n   trivy repository [command options] repo_url\n\nOPTIONS:\n   --template value, -t value  output template [$TRIVY_TEMPLATE]\n   --format value, -f value    format (table, json, sarif, template) (default: \"table\") [$TRIVY_FORMAT]\n   --input value, -i value     input file path instead of image name [$TRIVY_INPUT]\n   --severity value, -s value  severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --output value, -o value    output file name [$TRIVY_OUTPUT]\n   --exit-code value           Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]\n   --skip-update               skip db update (default: false) [$TRIVY_SKIP_UPDATE]\n   --clear-cache, -c           clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --ignore-unfixed            display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]\n   --removed-pkgs              detect vulnerabilities of removed packages (only for Alpine) (default: false) [$TRIVY_REMOVED_PKGS]\n   --vuln-type value           comma-separated list of vulnerability types (os,library) (default: \"os,library\") [$TRIVY_VULN_TYPE]\n   --ignorefile value          specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --cache-backend value       cache backend (e.g. redis://localhost:6379) (default: \"fs\") [$TRIVY_CACHE_BACKEND]\n   --timeout value             timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --no-progress               suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]\n   --quiet, -q                      suppress progress bar and log output (default: false) [$TRIVY_QUIET]\n   --ignore-policy value       specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]\n   --list-all-pkgs             enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]\n   --offline-scan              do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]\n   --skip-files value          specify the file path to skip traversal [$TRIVY_SKIP_FILES]\n   --skip-dirs value           specify the directory where the traversal is skipped [$TRIVY_SKIP_DIRS]\n   --help, -h                  show help (default: false)\n
","title":"Repository"},{"location":"docs/references/cli/rootfs/","text":"
NAME:\n   trivy rootfs - scan rootfs\n\nUSAGE:\n   trivy rootfs [command options] dir\n\nOPTIONS:\n   --template value, -t value                     output template [$TRIVY_TEMPLATE]\n   --format value, -f value                       format (table, json, sarif, template) (default: \"table\") [$TRIVY_FORMAT]\n   --severity value, -s value                     severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --output value, -o value                       output file name [$TRIVY_OUTPUT]\n   --exit-code value                              Exit code when vulnerabilities were found (default: 0) [$TRIVY_EXIT_CODE]\n   --skip-db-update, --skip-update                skip updating vulnerability database (default: false) [$TRIVY_SKIP_UPDATE, $TRIVY_SKIP_DB_UPDATE]\n   --skip-policy-update                           skip updating built-in policies (default: false) [$TRIVY_SKIP_POLICY_UPDATE]\n   --clear-cache, -c                              clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --ignore-unfixed                               display only fixed vulnerabilities (default: false) [$TRIVY_IGNORE_UNFIXED]\n   --vuln-type value                              comma-separated list of vulnerability types (os,library) (default: \"os,library\") [$TRIVY_VULN_TYPE]\n   --security-checks value                        comma-separated list of what security issues to detect (vuln,config) (default: \"vuln\") [$TRIVY_SECURITY_CHECKS]\n   --ignorefile value                             specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --cache-backend value                          cache backend (e.g. redis://localhost:6379) (default: \"fs\") [$TRIVY_CACHE_BACKEND]\n   --timeout value                                timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --no-progress                                  suppress progress bar (default: false) [$TRIVY_NO_PROGRESS]\n   --ignore-policy value                          specify the Rego file to evaluate each vulnerability [$TRIVY_IGNORE_POLICY]\n   --list-all-pkgs                                enabling the option will output all packages regardless of vulnerability (default: false) [$TRIVY_LIST_ALL_PKGS]\n   --offline-scan                                 do not issue API requests to identify dependencies (default: false) [$TRIVY_OFFLINE_SCAN]\n   --skip-files value                             specify the file paths to skip traversal [$TRIVY_SKIP_FILES]\n   --skip-dirs value                              specify the directories where the traversal is skipped [$TRIVY_SKIP_DIRS]\n   --config-policy value                          specify paths to the Rego policy files directory, applying config files [$TRIVY_CONFIG_POLICY]\n   --config-data value                            specify paths from which data for the Rego policies will be recursively loaded [$TRIVY_CONFIG_DATA]\n   --policy-namespaces value, --namespaces value  Rego namespaces (default: \"users\") [$TRIVY_POLICY_NAMESPACES]\n   --help, -h                                     show help (default: false)\n
","title":"Rootfs"},{"location":"docs/references/cli/sbom/","text":"
NAME:\n   trivy sbom - generate SBOM for an artifact\n\nUSAGE:\n   trivy sbom [command options] ARTIFACT\n\nOPTIONS:\n   --output value, -o value             output file name [$TRIVY_OUTPUT]\n   --clear-cache, -c                    clear image caches without scanning (default: false) [$TRIVY_CLEAR_CACHE]\n   --ignorefile value                   specify .trivyignore file (default: \".trivyignore\") [$TRIVY_IGNOREFILE]\n   --timeout value                      timeout (default: 5m0s) [$TRIVY_TIMEOUT]\n   --severity value, -s value           severities of vulnerabilities to be displayed (comma separated) (default: \"UNKNOWN,LOW,MEDIUM,HIGH,CRITICAL\") [$TRIVY_SEVERITY]\n   --artifact-type value, --type value  input artifact type (image, fs, repo, archive) (default: \"image\") [$TRIVY_ARTIFACT_TYPE]\n   --sbom-format value, --format value  SBOM format (cyclonedx) (default: \"cyclonedx\") [$TRIVY_SBOM_FORMAT]\n   --help, -h                           show help (default: false)\n
","title":"SBOM"},{"location":"docs/references/cli/server/","text":"
NAME:\n   trivy server - server mode\n\nUSAGE:\n   trivy server [command options] [arguments...]\n\nOPTIONS:\n   --skip-update          skip db update (default: false) [$TRIVY_SKIP_UPDATE]\n   --download-db-only     download/update vulnerability database but don't run a scan (default: false) [$TRIVY_DOWNLOAD_DB_ONLY]\n   --reset                remove all caches and database (default: false) [$TRIVY_RESET]\n   --cache-backend value  cache backend (e.g. redis://localhost:6379) (default: \"fs\") [$TRIVY_CACHE_BACKEND]\n   --token value          for authentication [$TRIVY_TOKEN]\n   --token-header value   specify a header name for token (default: \"Trivy-Token\") [$TRIVY_TOKEN_HEADER]\n   --listen value         listen address (default: \"localhost:4954\") [$TRIVY_LISTEN]\n   --help, -h             show help (default: false)\n
","title":"Server"},{"location":"docs/references/modes/client-server/","text":"

Trivy has client/server mode. Trivy server has vulnerability database and Trivy client doesn't have to download vulnerability database. It is useful if you want to scan images at multiple locations and do not want to download the database at every location.

","title":"Client/Server"},{"location":"docs/references/modes/client-server/#server","text":"

At first, you need to launch Trivy server. It downloads vulnerability database automatically and continue to fetch the latest DB in the background.

$ trivy server --listen localhost:8080\n2019-12-12T15:17:06.551+0200    INFO    Need to update DB\n2019-12-12T15:17:56.706+0200    INFO    Reopening DB...\n2019-12-12T15:17:56.707+0200    INFO    Listening localhost:8080...\n

If you want to accept a connection from outside, you have to specify 0.0.0.0 or your ip address, not localhost.

$ trivy server --listen 0.0.0.0:8080\n
","title":"Server"},{"location":"docs/references/modes/client-server/#client","text":"

Then, specify the remote address.

$ trivy client --remote http://localhost:8080 alpine:3.10\n

Result
alpine:3.10 (alpine 3.10.2)\n===========================\nTotal: 3 (UNKNOWN: 0, LOW: 1, MEDIUM: 2, HIGH: 0, CRITICAL: 0)\n\n+---------+------------------+----------+-------------------+---------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |\n+---------+------------------+----------+-------------------+---------------+\n| openssl | CVE-2019-1549    | MEDIUM   | 1.1.1c-r0         | 1.1.1d-r0     |\n+         +------------------+          +                   +               +\n|         | CVE-2019-1563    |          |                   |               |\n+         +------------------+----------+                   +               +\n|         | CVE-2019-1547    | LOW      |                   |               |\n+---------+------------------+----------+-------------------+---------------+\n
","title":"Client"},{"location":"docs/references/modes/client-server/#authentication","text":"
$ trivy server --listen localhost:8080 --token dummy\n
$ trivy client --remote http://localhost:8080 --token dummy alpine:3.10\n
","title":"Authentication"},{"location":"docs/references/modes/client-server/#architecture","text":"

","title":"Architecture"},{"location":"docs/references/modes/standalone/","text":"

trivy image, trivy filesystem, and trivy repo works as standalone mode.

","title":"Standalone"},{"location":"docs/references/modes/standalone/#image","text":"

","title":"Image"},{"location":"docs/references/modes/standalone/#filesystem","text":"

","title":"Filesystem"},{"location":"docs/references/modes/standalone/#git-repository","text":"

","title":"Git Repository"},{"location":"docs/sbom/","text":"

Trivy currently supports the following SBOM formats.

  • CycloneDX

To generate SBOM, you can use the --format option for each subcommand such as image and fs.

$ trivy image --format cyclonedx --output result.json alpine:3.15\n

In addition, you can use the trivy sbom subcommand.

$ trivy sbom alpine:3.15\n
Result
{\n  \"bomFormat\": \"CycloneDX\",\n  \"specVersion\": \"1.3\",\n  \"serialNumber\": \"urn:uuid:2be5773d-7cd3-4b4b-90a5-e165474ddace\",\n  \"version\": 1,\n  \"metadata\": {\n    \"timestamp\": \"2022-02-22T15:11:40.270597Z\",\n    \"tools\": [\n      {\n        \"vendor\": \"aquasecurity\",\n        \"name\": \"trivy\",\n        \"version\": \"dev\"\n      }\n    ],\n    \"component\": {\n      \"bom-ref\": \"pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64\",\n      \"type\": \"container\",\n      \"name\": \"alpine:3.15\",\n      \"version\": \"\",\n      \"purl\": \"pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:SchemaVersion\",\n          \"value\": \"2\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:ImageID\",\n          \"value\": \"sha256:c059bfaa849c4d8e4aecaeb3a10c2d9b3d85f5165c66ad3a4d937758128c4d18\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:RepoDigest\",\n          \"value\": \"alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:DiffID\",\n          \"value\": \"sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:RepoTag\",\n          \"value\": \"alpine:3.15\"\n        }\n      ]\n    }\n  },\n  \"components\": [\n    {\n      \"bom-ref\": \"pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0\",\n      \"type\": \"library\",\n      \"name\": \"alpine-baselayout\",\n      \"version\": \"3.2.0-r18\",\n      \"licenses\": [\n        {\n          \"expression\": \"GPL-2.0-only\"\n        }\n      ],\n      \"purl\": \"pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:SrcName\",\n          \"value\": \"alpine-baselayout\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:SrcVersion\",\n          \"value\": \"3.2.0-r18\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDigest\",\n          \"value\": \"sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDiffID\",\n          \"value\": \"sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759\"\n        }\n      ]\n    },\n    ...(snip)...\n    {\n      \"bom-ref\": \"pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0\",\n      \"type\": \"library\",\n      \"name\": \"zlib\",\n      \"version\": \"1.2.11-r3\",\n      \"licenses\": [\n        {\n          \"expression\": \"Zlib\"\n        }\n      ],\n      \"purl\": \"pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:SrcName\",\n          \"value\": \"zlib\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:SrcVersion\",\n          \"value\": \"1.2.11-r3\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDigest\",\n          \"value\": \"sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDiffID\",\n          \"value\": \"sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759\"\n        }\n      ]\n    },\n    {\n      \"bom-ref\": \"3da6a469-964d-4b4e-b67d-e94ec7c88d37\",\n      \"type\": \"operating-system\",\n      \"name\": \"alpine\",\n      \"version\": \"3.15.0\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:Type\",\n          \"value\": \"alpine\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:Class\",\n          \"value\": \"os-pkgs\"\n        }\n      ]\n    }\n  ],\n  \"dependencies\": [\n    {\n      \"ref\": \"3da6a469-964d-4b4e-b67d-e94ec7c88d37\",\n      \"dependsOn\": [\n        \"pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0\",\n        \"pkg:apk/alpine/alpine-keys@2.4-r1?distro=3.15.0\",\n        \"pkg:apk/alpine/apk-tools@2.12.7-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/busybox@1.34.1-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/ca-certificates-bundle@20191127-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/libc-utils@0.7.2-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/libcrypto1.1@1.1.1l-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/libretls@3.3.4-r2?distro=3.15.0\",\n        \"pkg:apk/alpine/libssl1.1@1.1.1l-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/musl@1.2.2-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/musl-utils@1.2.2-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/scanelf@1.3.3-r0?distro=3.15.0\",\n        \"pkg:apk/alpine/ssl_client@1.34.1-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0\"\n      ]\n    },\n    {\n      \"ref\": \"pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64\",\n      \"dependsOn\": [\n        \"3da6a469-964d-4b4e-b67d-e94ec7c88d37\"\n      ]\n    }\n  ]\n}\n

fs, repo and archive also work with sbom subcommand.

# filesystem\n$ trivy sbom --artifact-type fs /path/to/project\n\n# repository\n$ trivy sbom --artifact-type repo github.com/aquasecurity/trivy-ci-test\n\n# container image archive\n$ trivy sbom --artifact-type archive alpine.tar\n
","title":"SBOM"},{"location":"docs/sbom/cyclonedx/","text":"

Trivy generates JSON reports in the CycloneDX format. Note that XML format is not supported at the moment.

You can use the regular subcommands (like image, fs and rootfs) and specify cyclonedx with the --format option.

$ trivy image --format cyclonedx --output result.json alpine:3.15\n
Result
$ cat result.json | jq .\n{\n  \"bomFormat\": \"CycloneDX\",\n  \"specVersion\": \"1.4\",\n  \"serialNumber\": \"urn:uuid:2be5773d-7cd3-4b4b-90a5-e165474ddace\",\n  \"version\": 1,\n  \"metadata\": {\n    \"timestamp\": \"2022-02-22T15:11:40.270597Z\",\n    \"tools\": [\n      {\n        \"vendor\": \"aquasecurity\",\n        \"name\": \"trivy\",\n        \"version\": \"dev\"\n      }\n    ],\n    \"component\": {\n      \"bom-ref\": \"pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64\",\n      \"type\": \"container\",\n      \"name\": \"alpine:3.15\",\n      \"version\": \"\",\n      \"purl\": \"pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:SchemaVersion\",\n          \"value\": \"2\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:ImageID\",\n          \"value\": \"sha256:c059bfaa849c4d8e4aecaeb3a10c2d9b3d85f5165c66ad3a4d937758128c4d18\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:RepoDigest\",\n          \"value\": \"alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:DiffID\",\n          \"value\": \"sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:RepoTag\",\n          \"value\": \"alpine:3.15\"\n        }\n      ]\n    }\n  },\n  \"components\": [\n    {\n      \"bom-ref\": \"pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0\",\n      \"type\": \"library\",\n      \"name\": \"alpine-baselayout\",\n      \"version\": \"3.2.0-r18\",\n      \"licenses\": [\n        {\n          \"expression\": \"GPL-2.0-only\"\n        }\n      ],\n      \"purl\": \"pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:SrcName\",\n          \"value\": \"alpine-baselayout\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:SrcVersion\",\n          \"value\": \"3.2.0-r18\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDigest\",\n          \"value\": \"sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDiffID\",\n          \"value\": \"sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759\"\n        }\n      ]\n    },\n    ...(snip)...\n    {\n      \"bom-ref\": \"pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0\",\n      \"type\": \"library\",\n      \"name\": \"zlib\",\n      \"version\": \"1.2.11-r3\",\n      \"licenses\": [\n        {\n          \"expression\": \"Zlib\"\n        }\n      ],\n      \"purl\": \"pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:SrcName\",\n          \"value\": \"zlib\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:SrcVersion\",\n          \"value\": \"1.2.11-r3\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDigest\",\n          \"value\": \"sha256:59bf1c3509f33515622619af21ed55bbe26d24913cedbca106468a5fb37a50c3\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:LayerDiffID\",\n          \"value\": \"sha256:8d3ac3489996423f53d6087c81180006263b79f206d3fdec9e66f0e27ceb8759\"\n        }\n      ]\n    },\n    {\n      \"bom-ref\": \"3da6a469-964d-4b4e-b67d-e94ec7c88d37\",\n      \"type\": \"operating-system\",\n      \"name\": \"alpine\",\n      \"version\": \"3.15.0\",\n      \"properties\": [\n        {\n          \"name\": \"aquasecurity:trivy:Type\",\n          \"value\": \"alpine\"\n        },\n        {\n          \"name\": \"aquasecurity:trivy:Class\",\n          \"value\": \"os-pkgs\"\n        }\n      ]\n    }\n  ],\n  \"dependencies\": [\n    {\n      \"ref\": \"3da6a469-964d-4b4e-b67d-e94ec7c88d37\",\n      \"dependsOn\": [\n        \"pkg:apk/alpine/alpine-baselayout@3.2.0-r18?distro=3.15.0\",\n        \"pkg:apk/alpine/alpine-keys@2.4-r1?distro=3.15.0\",\n        \"pkg:apk/alpine/apk-tools@2.12.7-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/busybox@1.34.1-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/ca-certificates-bundle@20191127-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/libc-utils@0.7.2-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/libcrypto1.1@1.1.1l-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/libretls@3.3.4-r2?distro=3.15.0\",\n        \"pkg:apk/alpine/libssl1.1@1.1.1l-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/musl@1.2.2-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/musl-utils@1.2.2-r7?distro=3.15.0\",\n        \"pkg:apk/alpine/scanelf@1.3.3-r0?distro=3.15.0\",\n        \"pkg:apk/alpine/ssl_client@1.34.1-r3?distro=3.15.0\",\n        \"pkg:apk/alpine/zlib@1.2.11-r3?distro=3.15.0\"\n      ]\n    },\n    {\n      \"ref\": \"pkg:oci/alpine@sha256:21a3deaa0d32a8057914f36584b5288d2e5ecc984380bc0118285c70fa8c9300?repository_url=index.docker.io%2Flibrary%2Falpine&arch=amd64\",\n      \"dependsOn\": [\n        \"3da6a469-964d-4b4e-b67d-e94ec7c88d37\"\n      ]\n    }\n  ],\n  \"vulnerabilities\": [\n    {\n      \"id\": \"CVE-2021-42386\",\n      \"source\": {\n        \"name\": \"alpine\",\n        \"url\": \"https://secdb.alpinelinux.org/\"\n      },\n      \"ratings\": [\n        {\n          \"source\": {\n            \"name\": \"nvd\"\n          },\n          \"score\": 7.2,\n          \"severity\": \"high\",\n          \"method\": \"CVSSv31\",\n          \"vector\": \"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H\"\n        },\n        {\n          \"source\": {\n            \"name\": \"nvd\"\n          },\n          \"score\": 6.5,\n          \"severity\": \"medium\",\n          \"method\": \"CVSSv2\",\n          \"vector\": \"AV:N/AC:L/Au:S/C:P/I:P/A:P\"\n        },\n        {\n          \"source\": {\n            \"name\": \"redhat\"\n          },\n          \"score\": 6.6,\n          \"severity\": \"medium\",\n          \"method\": \"CVSSv31\",\n          \"vector\": \"CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:H\"\n        }\n      ],\n      \"cwes\": [\n        416\n      ],\n      \"description\": \"A use-after-free in Busybox's awk applet leads to denial of service and possibly code execution when processing a crafted awk pattern in the nvalloc function\",\n      \"advisories\": [\n        {\n          \"url\": \"https://access.redhat.com/security/cve/CVE-2021-42386\"\n        },\n        {\n          \"url\": \"https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-42386\"\n        }\n      ],\n      \"published\": \"2021-11-15 21:15:00 +0000 UTC\",\n      \"updated\": \"2022-01-04 17:14:00 +0000 UTC\",\n      \"affects\": [\n        {\n          \"ref\": \"pkg:apk/alpine/busybox@1.33.1-r3?distro=3.14.2\"\n        },\n        {\n          \"ref\": \"pkg:apk/alpine/ssl_client@1.33.1-r3?distro=3.14.2\"\n        }\n      ]\n    }\n  ]\n}\n
","title":"CycloneDX"},{"location":"docs/vulnerability/detection/data-source/","text":"OS Source Arch Linux Vulnerable Issues Alpine Linux secdb Amazon Linux 1 Amazon Linux Security Center Amazon Linux 2 Amazon Linux Security Center Debian Security Bug Tracker OVAL Ubuntu Ubuntu CVE Tracker RHEL/CentOS OVAL Security Data AlmaLinux AlmaLinux Product Errata Rocky Linux Rocky Linux UpdateInfo Oracle Linux OVAL CBL-Mariner OVAL OpenSUSE/SLES CVRF Photon OS Photon Security Advisory","title":"OS"},{"location":"docs/vulnerability/detection/data-source/#programming-language","text":"Language Source Commercial Use Delay1 PHP PHP Security Advisories Database \u2705 - GitHub Advisory Database (Composer) \u2705 - Python GitHub Advisory Database (pip) \u2705 - Open Source Vulnerabilities (PyPI) \u2705 - Ruby Ruby Advisory Database \u2705 - GitHub Advisory Database (RubyGems) \u2705 - Node.js Ecosystem Security Working Group \u2705 - GitHub Advisory Database (npm) \u2705 - Java GitLab Advisories Community \u2705 1 month GitHub Advisory Database (Maven) \u2705 - Go GitLab Advisories Community \u2705 1 month The Go Vulnerability Database \u2705 - Rust Open Source Vulnerabilities (crates.io) \u2705 - .NET GitHub Advisory Database (NuGet) \u2705 -","title":"Programming Language"},{"location":"docs/vulnerability/detection/data-source/#others","text":"Name Source National Vulnerability Database NVD
  1. Intentional delay between vulnerability disclosure and registration in the DB\u00a0\u21a9

","title":"Others"},{"location":"docs/vulnerability/detection/language/","text":"

Trivy automatically detects the following files in the container and scans vulnerabilities in the application dependencies.

Language File Image7 Rootfs8 Filesystem9 Repository10 Dev dependencies Ruby Gemfile.lock - - \u2705 \u2705 included gemspec \u2705 \u2705 - - included Python Pipfile.lock - - \u2705 \u2705 excluded poetry.lock - - \u2705 \u2705 included requirements.txt - - \u2705 \u2705 included egg package1 \u2705 \u2705 - - excluded wheel package2 \u2705 \u2705 - - excluded PHP composer.lock \u2705 \u2705 \u2705 \u2705 excluded Node.js package-lock.json - - \u2705 \u2705 excluded yarn.lock - - \u2705 \u2705 included package.json \u2705 \u2705 - - excluded .NET packages.lock.json \u2705 \u2705 \u2705 \u2705 included packages.config \u2705 \u2705 \u2705 \u2705 excluded Java JAR/WAR/PAR/EAR34 \u2705 \u2705 - - included pom.xml5 - - \u2705 \u2705 excluded Go Binaries built by Go6 \u2705 \u2705 - - excluded go.sum - - \u2705 \u2705 included Rust Cargo.lock \u2705 \u2705 \u2705 \u2705 included

The path of these files does not matter.

Example: Dockerfile

  1. *.egg-info, *.egg-info/PKG-INFO, *.egg and EGG-INFO/PKG-INFO \u21a9

  2. .dist-info/META-DATA \u21a9

  3. *.jar, *.war, *.par and *.ear \u21a9

  4. It requires Internet access\u00a0\u21a9

  5. It requires Internet access when the POM doesn't exist in your local repository\u00a0\u21a9

  6. UPX-compressed binaries don't work\u00a0\u21a9

  7. \u2705 means \"enabled\" and - means \"disabled\" in the image scanning\u00a0\u21a9

  8. \u2705 means \"enabled\" and - means \"disabled\" in the rootfs scanning\u00a0\u21a9

  9. \u2705 means \"enabled\" and - means \"disabled\" in the filesystem scanning\u00a0\u21a9

  10. \u2705 means \"enabled\" and - means \"disabled\" in the git repository scanning\u00a0\u21a9

","title":"Language-specific Packages"},{"location":"docs/vulnerability/detection/os/","text":"

The unfixed/unfixable vulnerabilities mean that the patch has not yet been provided on their distribution. Trivy doesn't support self-compiled packages/binaries, but official packages provided by vendors such as Red Hat and Debian.

OS Supported Versions Target Packages Detection of unfixed vulnerabilities Alpine Linux 2.2 - 2.7, 3.0 - 3.15 Installed by apk NO Red Hat Universal Base Image1 7, 8 Installed by yum/rpm YES Red Hat Enterprise Linux 6, 7, 8 Installed by yum/rpm YES CentOS 6, 7, 8 Installed by yum/rpm YES AlmaLinux 8 Installed by yum/rpm NO Rocky Linux 8 Installed by yum/rpm NO Oracle Linux 5, 6, 7, 8 Installed by yum/rpm NO CBL-Mariner 1.0, 2.0 Installed by yum/rpm YES Amazon Linux 1, 2 Installed by yum/rpm NO openSUSE Leap 42, 15 Installed by zypper/rpm NO SUSE Enterprise Linux 11, 12, 15 Installed by zypper/rpm NO Photon OS 1.0, 2.0, 3.0, 4.0 Installed by tdnf/yum/rpm NO Debian GNU/Linux wheezy, jessie, stretch, buster, bullseye Installed by apt/apt-get/dpkg YES Ubuntu All versions supported by Canonical Installed by apt/apt-get/dpkg YES Distroless2 Any Installed by apt/apt-get/dpkg YES
  1. https://developers.redhat.com/products/rhel/ubi\u00a0\u21a9

  2. https://github.com/GoogleContainerTools/distroless\u00a0\u21a9

","title":"Supported OS"},{"location":"docs/vulnerability/detection/supported/","text":"","title":"Supported"},{"location":"docs/vulnerability/detection/supported/#container-runtime","text":"
  • Docker Engine
  • Podman
","title":"Container Runtime"},{"location":"docs/vulnerability/detection/supported/#container-registry","text":"
  • Docker Registry HTTP API V2
  • OCI Distribution Specification
","title":"Container Registry"},{"location":"docs/vulnerability/detection/supported/#image-tar-formats","text":"

Trivy scans a tar image with the following format.

  • Docker Image Specification
    • Moby Project
    • Buildah
    • Podman
    • img
  • Kaniko
","title":"Image Tar Formats"},{"location":"docs/vulnerability/detection/supported/#image-layout","text":"
  • OCI Image Format Specification
","title":"Image Layout"},{"location":"docs/vulnerability/examples/cache/","text":"","title":"Cache"},{"location":"docs/vulnerability/examples/cache/#clear-caches","text":"

The --clear-cache option removes caches.

The scan is not performed.

$ trivy image --clear-cache\n
Result
2019-11-15T15:13:26.209+0200    INFO    Reopening vulnerability DB\n2019-11-15T15:13:26.209+0200    INFO    Removing image caches...\n
","title":"Clear Caches"},{"location":"docs/vulnerability/examples/cache/#cache-directory","text":"

Specify where the cache is stored with --cache-dir.

$ trivy --cache-dir /tmp/trivy/ image python:3.4-alpine3.9\n
","title":"Cache Directory"},{"location":"docs/vulnerability/examples/cache/#cache-backend","text":"

EXPERIMENTAL

This feature might change without preserving backwards compatibility.

Trivy supports local filesystem and Redis as the cache backend. This option is useful especially for client/server mode.

Two options: - fs - the cache path can be specified by --cache-dir - redis:// - redis://[HOST]:[PORT]

$ trivy server --cache-backend redis://localhost:6379\n

Trivy also support for connecting to Redis using TLS, you only need to specify --redis-ca , --redis-cert , and --redis-key option.

$ trivy server --cache-backend redis://localhost:6379 \\\n  --redis-ca /path/to/ca-cert.pem \\\n  --redis-cert /path/to/cert.pem \\\n  --redis-key /path/to/key.pem\n

TLS option for redis is hidden from Trivy command-line flag, but you still can use it.

","title":"Cache Backend"},{"location":"docs/vulnerability/examples/db/","text":"","title":"Vulnerability DB"},{"location":"docs/vulnerability/examples/db/#skip-update-of-vulnerability-db","text":"

Trivy downloads its vulnerability database every 12 hours when it starts operating. This is usually fast, as the size of the DB is only 10~30MB. But if you want to skip even that, use the --skip-db-update option.

$ trivy image --skip-db-update python:3.4-alpine3.9\n
Result
2019-05-16T12:48:08.703+0900    INFO    Detecting Alpine vulnerabilities...\n\npython:3.4-alpine3.9 (alpine 3.9.2)\n===================================\nTotal: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)\n\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |\n|         |                  |          |                   |               | with long nonces               |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n
","title":"Skip update of vulnerability DB"},{"location":"docs/vulnerability/examples/db/#only-download-vulnerability-database","text":"

You can also ask Trivy to simply retrieve the vulnerability database. This is useful to initialize workers in Continuous Integration systems.

$ trivy image --download-db-only\n
","title":"Only download vulnerability database"},{"location":"docs/vulnerability/examples/db/#db-repository","text":"

Trivy could also download the vulnerability database from an external OCI registry by using --db-repository option.

$ trivy image --db-repository registry.gitlab.com/gitlab-org/security-products/dependencies/trivy-db\n
","title":"DB Repository"},{"location":"docs/vulnerability/examples/filter/","text":"","title":"Filter Vulnerabilities"},{"location":"docs/vulnerability/examples/filter/#hide-unfixed-vulnerabilities","text":"

By default, Trivy also detects unpatched/unfixed vulnerabilities. This means you can't fix these vulnerabilities even if you update all packages. If you would like to ignore them, use the --ignore-unfixed option.

$ trivy image --ignore-unfixed ruby:2.4.0\n
Result
2019-05-16T12:49:52.656+0900    INFO    Updating vulnerability database...\n2019-05-16T12:50:14.786+0900    INFO    Detecting Debian vulnerabilities...\n\nruby:2.4.0 (debian 8.7)\n=======================\nTotal: 4730 (UNKNOWN: 1, LOW: 145, MEDIUM: 3487, HIGH: 1014, CRITICAL: 83)\n\n+------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+\n|           LIBRARY            | VULNERABILITY ID | SEVERITY |     INSTALLED VERSION      |          FIXED VERSION           |                        TITLE                        |\n+------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+\n| apt                          | CVE-2019-3462    | CRITICAL | 1.0.9.8.3                  | 1.0.9.8.5                        | Incorrect sanitation of the                         |\n|                              |                  |          |                            |                                  | 302 redirect field in HTTP                          |\n|                              |                  |          |                            |                                  | transport method of...                              |\n+                              +------------------+----------+                            +----------------------------------+-----------------------------------------------------+\n|                              | CVE-2016-1252    | MEDIUM   |                            | 1.0.9.8.4                        | The apt package in Debian                           |\n|                              |                  |          |                            |                                  | jessie before 1.0.9.8.4, in                         |\n|                              |                  |          |                            |                                  | Debian unstable before...                           |\n+------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+\n| bash                         | CVE-2019-9924    | HIGH     | 4.3-11                     | 4.3-11+deb8u2                    | bash: BASH_CMD is writable in                       |\n|                              |                  |          |                            |                                  | restricted bash shells                              |\n+                              +------------------+          +                            +----------------------------------+-----------------------------------------------------+\n|                              | CVE-2016-7543    |          |                            | 4.3-11+deb8u1                    | bash: Specially crafted                             |\n|                              |                  |          |                            |                                  | SHELLOPTS+PS4 variables allows                      |\n|                              |                  |          |                            |                                  | command substitution                                |\n+                              +------------------+----------+                            +                                  +-----------------------------------------------------+\n|                              | CVE-2016-0634    | MEDIUM   |                            |                                  | bash: Arbitrary code execution                      |\n|                              |                  |          |                            |                                  | via malicious hostname                              |\n+                              +------------------+----------+                            +----------------------------------+-----------------------------------------------------+\n|                              | CVE-2016-9401    | LOW      |                            | 4.3-11+deb8u2                    | bash: popd controlled free                          |\n+------------------------------+------------------+----------+----------------------------+----------------------------------+-----------------------------------------------------+\n...\n
","title":"Hide Unfixed Vulnerabilities"},{"location":"docs/vulnerability/examples/filter/#by-severity","text":"

Use --severity option.

$ trivy image --severity HIGH,CRITICAL ruby:2.4.0\n
Result
2019-05-16T01:51:46.255+0900    INFO    Updating vulnerability database...\n2019-05-16T01:51:49.213+0900    INFO    Detecting Debian vulnerabilities...\n\nruby:2.4.0 (debian 8.7)\n=======================\nTotal: 1785 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1680, CRITICAL: 105)\n\n+-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+\n|           LIBRARY           | VULNERABILITY ID | SEVERITY |     INSTALLED VERSION     |          FIXED VERSION           |                      TITLE                      |\n+-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+\n| apt                         | CVE-2019-3462    | CRITICAL | 1.0.9.8.3                 | 1.0.9.8.5                        | Incorrect sanitation of the                     |\n|                             |                  |          |                           |                                  | 302 redirect field in HTTP                      |\n|                             |                  |          |                           |                                  | transport method of...                          |\n+-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+\n| bash                        | CVE-2019-9924    | HIGH     | 4.3-11                    | 4.3-11+deb8u2                    | bash: BASH_CMD is writable in                   |\n|                             |                  |          |                           |                                  | restricted bash shells                          |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2016-7543    |          |                           | 4.3-11+deb8u1                    | bash: Specially crafted                         |\n|                             |                  |          |                           |                                  | SHELLOPTS+PS4 variables allows                  |\n|                             |                  |          |                           |                                  | command substitution                            |\n+-----------------------------+------------------+          +---------------------------+----------------------------------+-------------------------------------------------+\n| binutils                    | CVE-2017-8421    |          | 2.25-5                    |                                  | binutils: Memory exhaustion in                  |\n|                             |                  |          |                           |                                  | objdump via a crafted PE file                   |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2017-14930   |          |                           |                                  | binutils: Memory leak in                        |\n|                             |                  |          |                           |                                  | decode_line_info                                |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2017-7614    |          |                           |                                  | binutils: NULL                                  |\n|                             |                  |          |                           |                                  | pointer dereference in                          |\n|                             |                  |          |                           |                                  | bfd_elf_final_link function                     |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2014-9939    |          |                           |                                  | binutils: buffer overflow in                    |\n|                             |                  |          |                           |                                  | ihex.c                                          |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2017-13716   |          |                           |                                  | binutils: Memory leak with the                  |\n|                             |                  |          |                           |                                  | C++ symbol demangler routine                    |\n|                             |                  |          |                           |                                  | in libiberty                                    |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2018-12699   |          |                           |                                  | binutils: heap-based buffer                     |\n|                             |                  |          |                           |                                  | overflow in finish_stab in                      |\n|                             |                  |          |                           |                                  | stabs.c                                         |\n+-----------------------------+------------------+          +---------------------------+----------------------------------+-------------------------------------------------+\n| bsdutils                    | CVE-2015-5224    |          | 2.25.2-6                  |                                  | util-linux: File name                           |\n|                             |                  |          |                           |                                  | collision due to incorrect                      |\n|                             |                  |          |                           |                                  | mkstemp use                                     |\n+                             +------------------+          +                           +----------------------------------+-------------------------------------------------+\n|                             | CVE-2016-2779    |          |                           |                                  | util-linux: runuser tty hijack                  |\n|                             |                  |          |                           |                                  | via TIOCSTI ioctl                               |\n+-----------------------------+------------------+----------+---------------------------+----------------------------------+-------------------------------------------------+\n
","title":"By Severity"},{"location":"docs/vulnerability/examples/filter/#by-vulnerability-ids","text":"

Use .trivyignore.

$ cat .trivyignore\n# Accept the risk\nCVE-2018-14618\n\n# No impact in our settings\nCVE-2019-1543\n\n$ trivy image python:3.4-alpine3.9\n
Result
2019-05-16T12:53:10.076+0900    INFO    Updating vulnerability database...\n2019-05-16T12:53:28.134+0900    INFO    Detecting Alpine vulnerabilities...\n\npython:3.4-alpine3.9 (alpine 3.9.2)\n===================================\nTotal: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)\n
","title":"By Vulnerability IDs"},{"location":"docs/vulnerability/examples/filter/#by-type","text":"

Use --vuln-type option.

$ trivy image --vuln-type os ruby:2.4.0\n

Available values: - library - os

Result
2019-05-22T19:36:50.530+0200    \u001b[34mINFO\u001b[0m    Updating vulnerability database...\n2019-05-22T19:36:51.681+0200    \u001b[34mINFO\u001b[0m    Detecting Alpine vulnerabilities...\n2019-05-22T19:36:51.685+0200    \u001b[34mINFO\u001b[0m    Updating npm Security DB...\n2019-05-22T19:36:52.389+0200    \u001b[34mINFO\u001b[0m    Detecting npm vulnerabilities...\n2019-05-22T19:36:52.390+0200    \u001b[34mINFO\u001b[0m    Updating pipenv Security DB...\n2019-05-22T19:36:53.406+0200    \u001b[34mINFO\u001b[0m    Detecting pipenv vulnerabilities...\n\nruby:2.4.0 (debian 8.7)\nTotal: 4751 (UNKNOWN: 1, LOW: 150, MEDIUM: 3504, HIGH: 1013, CRITICAL: 83)\n\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |              TITLE               |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| curl    | CVE-2018-14618   | CRITICAL | 7.61.0-r0         | 7.61.1-r0     | curl: NTLM password overflow     |\n|         |                  |          |                   |               | via integer overflow             |\n+         +------------------+----------+                   +---------------+----------------------------------+\n|         | CVE-2018-16839   | HIGH     |                   | 7.61.1-r1     | curl: Integer overflow leading   |\n|         |                  |          |                   |               | to heap-based buffer overflow in |\n|         |                  |          |                   |               | Curl_sasl_create_plain_message() |\n+         +------------------+          +                   +---------------+----------------------------------+\n|         | CVE-2019-3822    |          |                   | 7.61.1-r2     | curl: NTLMv2 type-3 header       |\n|         |                  |          |                   |               | stack buffer overflow            |\n+         +------------------+          +                   +---------------+----------------------------------+\n|         | CVE-2018-16840   |          |                   | 7.61.1-r1     | curl: Use-after-free when        |\n|         |                  |          |                   |               | closing \"easy\" handle in         |\n|         |                  |          |                   |               | Curl_close()                     |\n+         +------------------+----------+                   +---------------+----------------------------------+\n|         | CVE-2019-3823    | MEDIUM   |                   | 7.61.1-r2     | curl: SMTP end-of-response       |\n|         |                  |          |                   |               | out-of-bounds read               |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2018-16890   |          |                   |               | curl: NTLM type-2 heap           |\n|         |                  |          |                   |               | out-of-bounds buffer read        |\n+         +------------------+          +                   +---------------+----------------------------------+\n|         | CVE-2018-16842   |          |                   | 7.61.1-r1     | curl: Heap-based buffer          |\n|         |                  |          |                   |               | over-read in the curl tool       |\n|         |                  |          |                   |               | warning formatting               |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| git     | CVE-2018-17456   | HIGH     | 2.15.2-r0         | 2.15.3-r0     | git: arbitrary code execution    |\n|         |                  |          |                   |               | via .gitmodules                  |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2018-19486   |          |                   |               | git: Improper handling of        |\n|         |                  |          |                   |               | PATH allows for commands to be   |\n|         |                  |          |                   |               | executed from...                 |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| libssh2 | CVE-2019-3855    | CRITICAL | 1.8.0-r2          | 1.8.1-r0      | libssh2: Integer overflow in     |\n|         |                  |          |                   |               | transport read resulting in      |\n|         |                  |          |                   |               | out of bounds write...           |\n+         +------------------+----------+                   +               +----------------------------------+\n|         | CVE-2019-3861    | MEDIUM   |                   |               | libssh2: Out-of-bounds reads     |\n|         |                  |          |                   |               | with specially crafted SSH       |\n|         |                  |          |                   |               | packets                          |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3857    |          |                   |               | libssh2: Integer overflow in     |\n|         |                  |          |                   |               | SSH packet processing channel    |\n|         |                  |          |                   |               | resulting in out of...           |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3856    |          |                   |               | libssh2: Integer overflow in     |\n|         |                  |          |                   |               | keyboard interactive handling    |\n|         |                  |          |                   |               | resulting in out of bounds...    |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3863    |          |                   |               | libssh2: Integer overflow        |\n|         |                  |          |                   |               | in user authenticate             |\n|         |                  |          |                   |               | keyboard interactive allows      |\n|         |                  |          |                   |               | out-of-bounds writes             |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3862    |          |                   |               | libssh2: Out-of-bounds memory    |\n|         |                  |          |                   |               | comparison with specially        |\n|         |                  |          |                   |               | crafted message channel          |\n|         |                  |          |                   |               | request                          |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3860    |          |                   |               | libssh2: Out-of-bounds reads     |\n|         |                  |          |                   |               | with specially crafted SFTP      |\n|         |                  |          |                   |               | packets                          |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3858    |          |                   |               | libssh2: Zero-byte allocation    |\n|         |                  |          |                   |               | with a specially crafted SFTP    |\n|         |                  |          |                   |               | packed leading to an...          |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-3859    |          |                   |               | libssh2: Unchecked use of        |\n|         |                  |          |                   |               | _libssh2_packet_require and      |\n|         |                  |          |                   |               | _libssh2_packet_requirev         |\n|         |                  |          |                   |               | resulting in out-of-bounds       |\n|         |                  |          |                   |               | read                             |\n+---------+------------------+          +-------------------+---------------+----------------------------------+\n| libxml2 | CVE-2018-14404   |          | 2.9.7-r0          | 2.9.8-r1      | libxml2: NULL pointer            |\n|         |                  |          |                   |               | dereference in                   |\n|         |                  |          |                   |               | xpath.c:xmlXPathCompOpEval()     |\n|         |                  |          |                   |               | can allow attackers to cause     |\n|         |                  |          |                   |               | a...                             |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2018-14567   |          |                   |               | libxml2: Infinite loop when      |\n|         |                  |          |                   |               | --with-lzma is used allows for   |\n|         |                  |          |                   |               | denial of service...             |\n+         +------------------+----------+                   +               +----------------------------------+\n|         | CVE-2018-9251    | LOW      |                   |               | libxml2: infinite loop in        |\n|         |                  |          |                   |               | xz_decomp function in xzlib.c    |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| openssh | CVE-2019-6109    | MEDIUM   | 7.5_p1-r9         | 7.5_p1-r10    | openssh: Missing character       |\n|         |                  |          |                   |               | encoding in progress display     |\n|         |                  |          |                   |               | allows for spoofing of scp...    |\n+         +------------------+          +                   +               +----------------------------------+\n|         | CVE-2019-6111    |          |                   |               | openssh: Improper validation     |\n|         |                  |          |                   |               | of object names allows           |\n|         |                  |          |                   |               | malicious server to overwrite    |\n|         |                  |          |                   |               | files...                         |\n+         +------------------+----------+                   +               +----------------------------------+\n|         | CVE-2018-20685   | LOW      |                   |               | openssh: scp client improper     |\n|         |                  |          |                   |               | directory name validation        |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| sqlite  | CVE-2018-20346   | MEDIUM   | 3.21.0-r1         | 3.25.3-r0     | CVE-2018-20505 CVE-2018-20506    |\n|         |                  |          |                   |               | sqlite: Multiple flaws in        |\n|         |                  |          |                   |               | sqlite which can be triggered    |\n|         |                  |          |                   |               | via...                           |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n| tar     | CVE-2018-20482   | LOW      | 1.29-r1           | 1.31-r0       | tar: Infinite read loop in       |\n|         |                  |          |                   |               | sparse_dump_region function in   |\n|         |                  |          |                   |               | sparse.c                         |\n+---------+------------------+----------+-------------------+---------------+----------------------------------+\n
","title":"By Type"},{"location":"docs/vulnerability/examples/filter/#by-open-policy-agent","text":"

EXPERIMENTAL

This feature might change without preserving backwards compatibility.

Trivy supports Open Policy Agent (OPA) to filter vulnerabilities. You can specify a Rego file with --ignore-policy option.

The Rego package name must be trivy and it must include a rule called ignore which determines if each individual vulnerability should be excluded (ignore=true) or not (ignore=false). In the policy, each vulnerability will be available for inspection as the input variable. The structure of each vulnerability input is the same as for the Trivy JSON output. There is a built-in Rego library with helper functions that you can import into your policy using: import data.lib.trivy. For more info about the helper functions, look at the library here

To get started, see the example policy.

$ trivy image --ignore-policy contrib/example_policy/basic.rego centos:7\n
Result
centos:7 (centos 7.9.2009)\n==========================\nTotal: 9 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 4, CRITICAL: 5)\n\n+--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+\n|   LIBRARY    | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |   FIXED VERSION   |                  TITLE                  |\n+--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+\n| glib2        | CVE-2015-8385    | HIGH     | 2.56.1-7.el7      |                   | pcre: buffer overflow caused            |\n|              |                  |          |                   |                   | by named forward reference              |\n|              |                  |          |                   |                   | to duplicate group number...            |\n|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2015-8385    |\n+              +------------------+          +                   +-------------------+-----------------------------------------+\n|              | CVE-2016-3191    |          |                   |                   | pcre: workspace overflow for            |\n|              |                  |          |                   |                   | (*ACCEPT) with deeply nested            |\n|              |                  |          |                   |                   | parentheses (8.39/13, 10.22/12)         |\n|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2016-3191    |\n+              +------------------+          +                   +-------------------+-----------------------------------------+\n|              | CVE-2021-27219   |          |                   | 2.56.1-9.el7_9    | glib: integer overflow in               |\n|              |                  |          |                   |                   | g_bytes_new function on                 |\n|              |                  |          |                   |                   | 64-bit platforms due to an...           |\n|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2021-27219   |\n+--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+\n| glibc        | CVE-2019-1010022 | CRITICAL | 2.17-317.el7      |                   | glibc: stack guard protection bypass    |\n|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2019-1010022 |\n+--------------+                  +          +                   +-------------------+                                         +\n| glibc-common |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n+--------------+------------------+          +-------------------+-------------------+-----------------------------------------+\n| nss          | CVE-2021-43527   |          | 3.53.1-3.el7_9    | 3.67.0-4.el7_9    | nss: Memory corruption in               |\n|              |                  |          |                   |                   | decodeECorDsaSignature with             |\n|              |                  |          |                   |                   | DSA signatures (and RSA-PSS)            |\n|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2021-43527   |\n+--------------+                  +          +                   +                   +                                         +\n| nss-sysinit  |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n+--------------+                  +          +                   +                   +                                         +\n| nss-tools    |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n|              |                  |          |                   |                   |                                         |\n+--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+\n| openssl-libs | CVE-2020-1971    | HIGH     | 1:1.0.2k-19.el7   | 1:1.0.2k-21.el7_9 | openssl: EDIPARTYNAME                   |\n|              |                  |          |                   |                   | NULL pointer de-reference               |\n|              |                  |          |                   |                   | -->avd.aquasec.com/nvd/cve-2020-1971    |\n+--------------+------------------+----------+-------------------+-------------------+-----------------------------------------+\n
","title":"By Open Policy Agent"},{"location":"docs/vulnerability/examples/others/","text":"","title":"Others"},{"location":"docs/vulnerability/examples/others/#skip-files","text":"

Trivy traversals directories and looks for all lock files by default. If your image contains lock files which are not maintained by you, you can skip the file.

$ trivy image --skip-files \"/Gemfile.lock\" --skip-files \"/var/lib/gems/2.5.0/gems/http_parser.rb-0.6.0/Gemfile.lock\" quay.io/fluentd_elasticsearch/fluentd:v2.9.0\n
","title":"Skip Files"},{"location":"docs/vulnerability/examples/others/#skip-directories","text":"

Trivy traversals directories and look for all lock files by default. If your image contains lock files which are not maintained by you, you can skip traversal in the specific directory.

$ trivy image --skip-dirs /var/lib/gems/2.5.0/gems/fluent-plugin-detect-exceptions-0.0.13 --skip-dirs \"/var/lib/gems/2.5.0/gems/http_parser.rb-0.6.0\" quay.io/fluentd_elasticsearch/fluentd:v2.9.0\n
","title":"Skip Directories"},{"location":"docs/vulnerability/examples/others/#exit-code","text":"

By default, Trivy exits with code 0 even when vulnerabilities are detected. Use the --exit-code option if you want to exit with a non-zero exit code.

$ trivy image --exit-code 1 python:3.4-alpine3.9\n
Result
2019-05-16T12:51:43.500+0900    INFO    Updating vulnerability database...\n2019-05-16T12:52:00.387+0900    INFO    Detecting Alpine vulnerabilities...\n\npython:3.4-alpine3.9 (alpine 3.9.2)\n===================================\nTotal: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)\n\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |\n|         |                  |          |                   |               | with long nonces               |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n

This option is useful for CI/CD. In the following example, the test will fail only when a critical vulnerability is found.

$ trivy image --exit-code 0 --severity MEDIUM,HIGH ruby:2.4.0\n$ trivy image --exit-code 1 --severity CRITICAL ruby:2.4.0\n
","title":"Exit Code"},{"location":"docs/vulnerability/examples/others/#reset","text":"

The --reset option removes all caches and database. After this, it takes a long time as the vulnerability database needs to be rebuilt locally.

$ trivy image --reset\n
Result
2019-05-16T13:05:31.935+0900    INFO    Resetting...\n
","title":"Reset"},{"location":"docs/vulnerability/examples/report/","text":"","title":"Report Formats"},{"location":"docs/vulnerability/examples/report/#table-default","text":"
$ trivy image -f table golang:1.12-alpine\n
","title":"Table (Default)"},{"location":"docs/vulnerability/examples/report/#json","text":"
$ trivy image -f json -o results.json golang:1.12-alpine\n

Caution

v0.20.0 changes the JSON schema. For more details, see here.

Result
2019-05-16T01:46:31.777+0900    INFO    Updating vulnerability database...\n2019-05-16T01:47:03.007+0900    INFO    Detecting Alpine vulnerabilities...\n
JSON
[\n  {\n    \"Target\": \"php-app/composer.lock\",\n    \"Vulnerabilities\": null\n  },\n  {\n    \"Target\": \"node-app/package-lock.json\",\n    \"Vulnerabilities\": [\n      {\n        \"VulnerabilityID\": \"CVE-2018-16487\",\n        \"PkgName\": \"lodash\",\n        \"InstalledVersion\": \"4.17.4\",\n        \"FixedVersion\": \"\\u003e=4.17.11\",\n        \"Title\": \"lodash: Prototype pollution in utilities function\",\n        \"Description\": \"A prototype pollution vulnerability was found in lodash \\u003c4.17.11 where the functions merge, mergeWith, and defaultsDeep can be tricked into adding or modifying properties of Object.prototype.\",\n        \"Severity\": \"HIGH\",\n        \"References\": [\n          \"https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-16487\",\n        ]\n      }\n    ]\n  },\n  {\n    \"Target\": \"trivy-ci-test (alpine 3.7.1)\",\n    \"Vulnerabilities\": [\n      {\n        \"VulnerabilityID\": \"CVE-2018-16840\",\n        \"PkgName\": \"curl\",\n        \"InstalledVersion\": \"7.61.0-r0\",\n        \"FixedVersion\": \"7.61.1-r1\",\n        \"Title\": \"curl: Use-after-free when closing \\\"easy\\\" handle in Curl_close()\",\n        \"Description\": \"A heap use-after-free flaw was found in curl versions from 7.59.0 through 7.61.1 in the code related to closing an easy handle. \",\n        \"Severity\": \"HIGH\",\n        \"References\": [\n          \"https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-16840\",\n        ]\n      },\n      {\n        \"VulnerabilityID\": \"CVE-2019-3822\",\n        \"PkgName\": \"curl\",\n        \"InstalledVersion\": \"7.61.0-r0\",\n        \"FixedVersion\": \"7.61.1-r2\",\n        \"Title\": \"curl: NTLMv2 type-3 header stack buffer overflow\",\n        \"Description\": \"libcurl versions from 7.36.0 to before 7.64.0 are vulnerable to a stack-based buffer overflow. \",\n        \"Severity\": \"HIGH\",\n        \"References\": [\n          \"https://curl.haxx.se/docs/CVE-2019-3822.html\",\n          \"https://lists.apache.org/thread.html/8338a0f605bdbb3a6098bb76f666a95fc2b2f53f37fa1ecc89f1146f@%3Cdevnull.infra.apache.org%3E\"\n        ]\n      },\n      {\n        \"VulnerabilityID\": \"CVE-2018-16839\",\n        \"PkgName\": \"curl\",\n        \"InstalledVersion\": \"7.61.0-r0\",\n        \"FixedVersion\": \"7.61.1-r1\",\n        \"Title\": \"curl: Integer overflow leading to heap-based buffer overflow in Curl_sasl_create_plain_message()\",\n        \"Description\": \"Curl versions 7.33.0 through 7.61.1 are vulnerable to a buffer overrun in the SASL authentication code that may lead to denial of service.\",\n        \"Severity\": \"HIGH\",\n        \"References\": [\n          \"https://github.com/curl/curl/commit/f3a24d7916b9173c69a3e0ee790102993833d6c5\",\n        ]\n      },\n      {\n        \"VulnerabilityID\": \"CVE-2018-19486\",\n        \"PkgName\": \"git\",\n        \"InstalledVersion\": \"2.15.2-r0\",\n        \"FixedVersion\": \"2.15.3-r0\",\n        \"Title\": \"git: Improper handling of PATH allows for commands to be executed from the current directory\",\n        \"Description\": \"Git before 2.19.2 on Linux and UNIX executes commands from the current working directory (as if '.' were at the end of $PATH) in certain cases involving the run_command() API and run-command.c, because there was a dangerous change from execvp to execv during 2017.\",\n        \"Severity\": \"HIGH\",\n        \"References\": [\n          \"https://usn.ubuntu.com/3829-1/\",\n        ]\n      },\n      {\n        \"VulnerabilityID\": \"CVE-2018-17456\",\n        \"PkgName\": \"git\",\n        \"InstalledVersion\": \"2.15.2-r0\",\n        \"FixedVersion\": \"2.15.3-r0\",\n        \"Title\": \"git: arbitrary code execution via .gitmodules\",\n        \"Description\": \"Git before 2.14.5, 2.15.x before 2.15.3, 2.16.x before 2.16.5, 2.17.x before 2.17.2, 2.18.x before 2.18.1, and 2.19.x before 2.19.1 allows remote code execution during processing of a recursive \\\"git clone\\\" of a superproject if a .gitmodules file has a URL field beginning with a '-' character.\",\n        \"Severity\": \"HIGH\",\n        \"References\": [\n          \"http://www.securitytracker.com/id/1041811\",\n        ]\n      }\n    ]\n  },\n  {\n    \"Target\": \"python-app/Pipfile.lock\",\n    \"Vulnerabilities\": null\n  },\n  {\n    \"Target\": \"ruby-app/Gemfile.lock\",\n    \"Vulnerabilities\": null\n  },\n  {\n    \"Target\": \"rust-app/Cargo.lock\",\n    \"Vulnerabilities\": null\n  }\n]\n

VulnerabilityID, PkgName, InstalledVersion, and Severity in Vulnerabilities are always filled with values, but other fields might be empty.

","title":"JSON"},{"location":"docs/vulnerability/examples/report/#sarif","text":"

Sarif can be generated with the --format sarif option.

$ trivy image --format sarif -o report.sarif  golang:1.12-alpine\n

This SARIF file can be uploaded to GitHub code scanning results, and there is a Trivy GitHub Action for automating this process.

","title":"SARIF"},{"location":"docs/vulnerability/examples/report/#template","text":"","title":"Template"},{"location":"docs/vulnerability/examples/report/#custom-template","text":"
$ trivy image --format template --template \"{{ range . }} {{ .Target }} {{ end }}\" golang:1.12-alpine\n
Result
2020-01-02T18:02:32.856+0100    INFO    Detecting Alpine vulnerabilities...\n golang:1.12-alpine (alpine 3.10.2)\n

You can compute different figures within the template using sprig functions. As an example you can summarize the different classes of issues:

$ trivy image --format template --template '{{- $critical := 0 }}{{- $high := 0 }}{{- range . }}{{- range .Vulnerabilities }}{{- if  eq .Severity \"CRITICAL\" }}{{- $critical = add $critical 1 }}{{- end }}{{- if  eq .Severity \"HIGH\" }}{{- $high = add $high 1 }}{{- end }}{{- end }}{{- end }}Critical: {{ $critical }}, High: {{ $high }}' golang:1.12-alpine\n
Result
Critical: 0, High: 2\n

For other features of sprig, see the official sprig documentation.

","title":"Custom Template"},{"location":"docs/vulnerability/examples/report/#load-templates-from-a-file","text":"

You can load templates from a file prefixing the template path with an @.

$ trivy image --format template --template \"@/path/to/template\" golang:1.12-alpine\n
","title":"Load templates from a file"},{"location":"docs/vulnerability/examples/report/#default-templates","text":"

If Trivy is installed using rpm then default templates can be found at /usr/local/share/trivy/templates.

","title":"Default Templates"},{"location":"docs/vulnerability/examples/report/#xml","text":"

In the following example using the template junit.tpl XML can be generated.

$ trivy image --format template --template \"@contrib/junit.tpl\" -o junit-report.xml  golang:1.12-alpine\n

","title":"XML"},{"location":"docs/vulnerability/examples/report/#asff","text":"

Trivy also supports an ASFF template for reporting findings to AWS Security Hub

","title":"ASFF"},{"location":"docs/vulnerability/examples/report/#html","text":"
$ trivy image --format template --template \"@contrib/html.tpl\" -o report.html golang:1.12-alpine\n

The following example shows use of default HTML template when Trivy is installed using rpm.

$ trivy image --format template --template \"@/usr/local/share/trivy/templates/html.tpl\" -o report.html golang:1.12-alpine\n
","title":"HTML"},{"location":"docs/vulnerability/scanning/","text":"

Trivy scans Container Images, Rootfs, Filesystem, and Git Repositories to detect vulnerabilities.

","title":"Vulnerability Scanning"},{"location":"docs/vulnerability/scanning/filesystem/","text":"

Scan a local project including language-specific files.

$ trivy fs /path/to/project\n
","title":"Filesystem"},{"location":"docs/vulnerability/scanning/filesystem/#standalone-mode","text":"","title":"Standalone mode"},{"location":"docs/vulnerability/scanning/filesystem/#local-project","text":"

Trivy will look for vulnerabilities based on lock files such as Gemfile.lock and package-lock.json.

$ trivy fs ~/src/github.com/aquasecurity/trivy-ci-test\n
Result
2020-06-01T17:06:58.652+0300    WARN    OS is not detected and vulnerabilities in OS packages are not detected.\n2020-06-01T17:06:58.652+0300    INFO    Detecting pipenv vulnerabilities...\n2020-06-01T17:06:58.691+0300    INFO    Detecting cargo vulnerabilities...\n\nPipfile.lock\n============\nTotal: 10 (UNKNOWN: 2, LOW: 0, MEDIUM: 6, HIGH: 2, CRITICAL: 0)\n\n+---------------------+------------------+----------+-------------------+------------------------+------------------------------------+\n|       LIBRARY       | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |     FIXED VERSION      |               TITLE                |\n+---------------------+------------------+----------+-------------------+------------------------+------------------------------------+\n| django              | CVE-2020-7471    | HIGH     | 2.0.9             | 3.0.3, 2.2.10, 1.11.28 | django: potential                  |\n|                     |                  |          |                   |                        | SQL injection via                  |\n|                     |                  |          |                   |                        | StringAgg(delimiter)               |\n+                     +------------------+----------+                   +------------------------+------------------------------------+\n|                     | CVE-2019-19844   | MEDIUM   |                   | 3.0.1, 2.2.9, 1.11.27  | Django: crafted email address      |\n|                     |                  |          |                   |                        | allows account takeover            |\n+                     +------------------+          +                   +------------------------+------------------------------------+\n|                     | CVE-2019-3498    |          |                   | 2.1.5, 2.0.10, 1.11.18 | python-django: Content             |\n|                     |                  |          |                   |                        | spoofing via URL path in           |\n|                     |                  |          |                   |                        | default 404 page                   |\n+                     +------------------+          +                   +------------------------+------------------------------------+\n|                     | CVE-2019-6975    |          |                   | 2.1.6, 2.0.11, 1.11.19 | python-django:                     |\n|                     |                  |          |                   |                        | memory exhaustion in               |\n|                     |                  |          |                   |                        | django.utils.numberformat.format() |\n+---------------------+------------------+----------+-------------------+------------------------+------------------------------------+\n...\n
","title":"Local Project"},{"location":"docs/vulnerability/scanning/filesystem/#single-file","text":"

It's also possible to scan a single file.

$ trivy fs ~/src/github.com/aquasecurity/trivy-ci-test/Pipfile.lock\n
","title":"Single file"},{"location":"docs/vulnerability/scanning/filesystem/#clientserver-mode","text":"

You must launch Trivy server in advance.

$ trivy server\n

Then, Trivy works as a client if you specify the --server option.

$ trivy fs --server http://localhost:4954 --severity CRITICAL ./integration/testdata/fixtures/fs/pom/\n
Result
pom.xml (pom)\n=============\nTotal: 4 (CRITICAL: 4)\n\n+---------------------------------------------+------------------+----------+-------------------+--------------------------------+---------------------------------------+\n|                   LIBRARY                   | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |         FIXED VERSION          |                 TITLE                 |\n+---------------------------------------------+------------------+----------+-------------------+--------------------------------+---------------------------------------+\n| com.fasterxml.jackson.core:jackson-databind | CVE-2017-17485   | CRITICAL | 2.9.1             | 2.8.11, 2.9.4                  | jackson-databind: Unsafe              |\n|                                             |                  |          |                   |                                | deserialization due to                |\n|                                             |                  |          |                   |                                | incomplete black list (incomplete     |\n|                                             |                  |          |                   |                                | fix for CVE-2017-15095)...            |\n|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2017-17485 |\n+                                             +------------------+          +                   +--------------------------------+---------------------------------------+\n|                                             | CVE-2020-9546    |          |                   | 2.7.9.7, 2.8.11.6, 2.9.10.4    | jackson-databind: Serialization       |\n|                                             |                  |          |                   |                                | gadgets in shaded-hikari-config       |\n|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2020-9546  |\n+                                             +------------------+          +                   +                                +---------------------------------------+\n|                                             | CVE-2020-9547    |          |                   |                                | jackson-databind: Serialization       |\n|                                             |                  |          |                   |                                | gadgets in ibatis-sqlmap              |\n|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2020-9547  |\n+                                             +------------------+          +                   +                                +---------------------------------------+\n|                                             | CVE-2020-9548    |          |                   |                                | jackson-databind: Serialization       |\n|                                             |                  |          |                   |                                | gadgets in anteros-core               |\n|                                             |                  |          |                   |                                | -->avd.aquasec.com/nvd/cve-2020-9548  |\n+---------------------------------------------+------------------+----------+-------------------+--------------------------------+---------------------------------------+\n
","title":"Client/Server mode"},{"location":"docs/vulnerability/scanning/git-repository/","text":"

Scan your remote git repository

$ trivy repo https://github.com/knqyf263/trivy-ci-test\n
Result
2021-03-09T15:04:19.003+0200    INFO    Detecting cargo vulnerabilities...\n2021-03-09T15:04:19.005+0200    INFO    Detecting pipenv vulnerabilities...\n\nCargo.lock\n==========\nTotal: 7 (UNKNOWN: 7, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)\n\n+----------+-------------------+----------+-------------------+------------------------------+---------------------------------------------+\n| LIBRARY  | VULNERABILITY ID  | SEVERITY | INSTALLED VERSION |        FIXED VERSION         |                    TITLE                    |\n+----------+-------------------+----------+-------------------+------------------------------+---------------------------------------------+\n| ammonia  | RUSTSEC-2019-0001 | UNKNOWN  | 1.9.0             | >= 2.1.0                     | Uncontrolled recursion leads                |\n|          |                   |          |                   |                              | to abort in HTML serialization              |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2019-0001 |\n+----------+-------------------+          +-------------------+------------------------------+---------------------------------------------+\n| openssl  | RUSTSEC-2016-0001 |          | 0.8.3             | >= 0.9.0                     | SSL/TLS MitM vulnerability                  |\n|          |                   |          |                   |                              | due to insecure defaults                    |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2016-0001 |\n+----------+-------------------+          +-------------------+------------------------------+---------------------------------------------+\n| smallvec | RUSTSEC-2018-0018 |          | 0.6.9             | >= 0.6.13                    | smallvec creates uninitialized              |\n|          |                   |          |                   |                              | value of any type                           |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2018-0018 |\n+          +-------------------+          +                   +------------------------------+---------------------------------------------+\n|          | RUSTSEC-2019-0009 |          |                   | >= 0.6.10                    | Double-free and use-after-free              |\n|          |                   |          |                   |                              | in SmallVec::grow()                         |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2019-0009 |\n+          +-------------------+          +                   +                              +---------------------------------------------+\n|          | RUSTSEC-2019-0012 |          |                   |                              | Memory corruption in SmallVec::grow()       |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2019-0012 |\n+          +-------------------+          +                   +------------------------------+---------------------------------------------+\n|          | RUSTSEC-2021-0003 |          |                   | >= 0.6.14, < 1.0.0, >= 1.6.1 | Buffer overflow in SmallVec::insert_many    |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2021-0003 |\n+----------+-------------------+          +-------------------+------------------------------+---------------------------------------------+\n| tempdir  | RUSTSEC-2018-0017 |          | 0.3.7             |                              | `tempdir` crate has been                    |\n|          |                   |          |                   |                              | deprecated; use `tempfile` instead          |\n|          |                   |          |                   |                              | -->rustsec.org/advisories/RUSTSEC-2018-0017 |\n+----------+-------------------+----------+-------------------+------------------------------+---------------------------------------------+\n\nPipfile.lock\n============\nTotal: 20 (UNKNOWN: 3, LOW: 0, MEDIUM: 7, HIGH: 5, CRITICAL: 5)\n\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n|       LIBRARY       | VULNERABILITY ID | SEVERITY | INSTALLED VERSION |     FIXED VERSION      |                 TITLE                 |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| django              | CVE-2019-19844   | CRITICAL | 2.0.9             | 3.0.1, 2.2.9, 1.11.27  | Django: crafted email address         |\n|                     |                  |          |                   |                        | allows account takeover               |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-19844 |\n+                     +------------------+          +                   +------------------------+---------------------------------------+\n|                     | CVE-2020-7471    |          |                   | 3.0.3, 2.2.10, 1.11.28 | django: potential SQL injection       |\n|                     |                  |          |                   |                        | via StringAgg(delimiter)              |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-7471  |\n+                     +------------------+----------+                   +------------------------+---------------------------------------+\n|                     | CVE-2019-6975    | HIGH     |                   | 2.1.6, 2.0.11, 1.11.19 | python-django: memory exhaustion in   |\n|                     |                  |          |                   |                        | django.utils.numberformat.format()    |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-6975  |\n+                     +------------------+          +                   +------------------------+---------------------------------------+\n|                     | CVE-2020-9402    |          |                   | 3.0.4, 2.2.11, 1.11.29 | django: potential SQL injection       |\n|                     |                  |          |                   |                        | via \"tolerance\" parameter in          |\n|                     |                  |          |                   |                        | GIS functions and aggregates...       |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-9402  |\n+                     +------------------+----------+                   +------------------------+---------------------------------------+\n|                     | CVE-2019-3498    | MEDIUM   |                   | 2.1.5, 2.0.10, 1.11.18 | python-django: Content spoofing       |\n|                     |                  |          |                   |                        | via URL path in default 404 page      |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-3498  |\n+                     +------------------+          +                   +------------------------+---------------------------------------+\n|                     | CVE-2020-13254   |          |                   | 3.0.7, 2.2.13          | django: potential data leakage        |\n|                     |                  |          |                   |                        | via malformed memcached keys          |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-13254 |\n+                     +------------------+          +                   +                        +---------------------------------------+\n|                     | CVE-2020-13596   |          |                   |                        | django: possible XSS via              |\n|                     |                  |          |                   |                        | admin ForeignKeyRawIdWidget           |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-13596 |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| django-cors-headers | pyup.io-37132    | UNKNOWN  | 2.5.2             | 3.0.0                  | In django-cors-headers                |\n|                     |                  |          |                   |                        | version 3.0.0,                        |\n|                     |                  |          |                   |                        | ``CORS_ORIGIN_WHITELIST``             |\n|                     |                  |          |                   |                        | requires URI schemes, and             |\n|                     |                  |          |                   |                        | optionally ports. This...             |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| djangorestframework | CVE-2020-25626   | MEDIUM   | 3.9.2             | 3.11.2                 | django-rest-framework: XSS            |\n|                     |                  |          |                   |                        | Vulnerability in API viewer           |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-25626 |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| httplib2            | CVE-2021-21240   | HIGH     | 0.12.1            | 0.19.0                 | python-httplib2: Regular              |\n|                     |                  |          |                   |                        | expression denial of                  |\n|                     |                  |          |                   |                        | service via malicious header          |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2021-21240 |\n+                     +------------------+----------+                   +------------------------+---------------------------------------+\n|                     | CVE-2020-11078   | MEDIUM   |                   | 0.18.0                 | python-httplib2: CRLF injection       |\n|                     |                  |          |                   |                        | via an attacker controlled            |\n|                     |                  |          |                   |                        | unescaped part of uri for...          |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-11078 |\n+                     +------------------+----------+                   +                        +---------------------------------------+\n|                     | pyup.io-38303    | UNKNOWN  |                   |                        | Httplib2 0.18.0 is an                 |\n|                     |                  |          |                   |                        | important security update to          |\n|                     |                  |          |                   |                        | patch a CWE-93 CRLF...                |\n+---------------------+------------------+          +-------------------+------------------------+---------------------------------------+\n| jinja2              | pyup.io-39525    |          | 2.10.1            | 2.11.3                 | This affects the package              |\n|                     |                  |          |                   |                        | jinja2 from 0.0.0 and before          |\n|                     |                  |          |                   |                        | 2.11.3. The ReDOS...                  |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| py                  | CVE-2020-29651   | HIGH     | 1.8.0             |                        | python-py: ReDoS in the py.path.svnwc |\n|                     |                  |          |                   |                        | component via mailicious input        |\n|                     |                  |          |                   |                        | to blame functionality...             |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-29651 |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| pyyaml              | CVE-2019-20477   | CRITICAL |               5.1 |                        | PyYAML: command execution             |\n|                     |                  |          |                   |                        | through python/object/apply           |\n|                     |                  |          |                   |                        | constructor in FullLoader             |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-20477 |\n+                     +------------------+          +                   +------------------------+---------------------------------------+\n|                     | CVE-2020-14343   |          |                   |                    5.4 | PyYAML: incomplete                    |\n|                     |                  |          |                   |                        | fix for CVE-2020-1747                 |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-14343 |\n+                     +------------------+          +                   +------------------------+---------------------------------------+\n|                     | CVE-2020-1747    |          |                   | 5.3.1                  | PyYAML: arbitrary command             |\n|                     |                  |          |                   |                        | execution through python/object/new   |\n|                     |                  |          |                   |                        | when FullLoader is used               |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-1747  |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n| urllib3             | CVE-2019-11324   | HIGH     | 1.24.1            | 1.24.2                 | python-urllib3: Certification         |\n|                     |                  |          |                   |                        | mishandle when error should be thrown |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-11324 |\n+                     +------------------+----------+                   +------------------------+---------------------------------------+\n|                     | CVE-2019-11236   | MEDIUM   |                   |                        | python-urllib3: CRLF injection        |\n|                     |                  |          |                   |                        | due to not encoding the               |\n|                     |                  |          |                   |                        | '\\r\\n' sequence leading to...         |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2019-11236 |\n+                     +------------------+          +                   +------------------------+---------------------------------------+\n|                     | CVE-2020-26137   |          |                   | 1.25.9                 | python-urllib3: CRLF injection        |\n|                     |                  |          |                   |                        | via HTTP request method               |\n|                     |                  |          |                   |                        | -->avd.aquasec.com/nvd/cve-2020-26137 |\n+---------------------+------------------+----------+-------------------+------------------------+---------------------------------------+\n
","title":"Git Repository"},{"location":"docs/vulnerability/scanning/git-repository/#scanning-private-repositories","text":"

In order to scan private GitHub or GitLab repositories, the environment variable GITHUB_TOKEN or GITLAB_TOKEN must be set, respectively, with a valid token that has access to the private repository being scanned.

The GITHUB_TOKEN environment variable will take precedence over GITLAB_TOKEN, so if a private GitLab repository will be scanned, then GITHUB_TOKEN must be unset.

For example:

$ export GITHUB_TOKEN=\"your_private_github_token\"\n$ trivy repo <your private GitHub repo URL>\n$\n$ # or\n$ export GITLAB_TOKEN=\"your_private_gitlab_token\"\n$ trivy repo <your private GitLab repo URL>\n
","title":"Scanning Private Repositories"},{"location":"docs/vulnerability/scanning/image/","text":"","title":"Image"},{"location":"docs/vulnerability/scanning/image/#container-images","text":"

Simply specify an image name (and a tag).

$ trivy image [YOUR_IMAGE_NAME]\n

For example:

$ trivy image python:3.4-alpine\n
Result
2019-05-16T01:20:43.180+0900    INFO    Updating vulnerability database...\n2019-05-16T01:20:53.029+0900    INFO    Detecting Alpine vulnerabilities...\n\npython:3.4-alpine3.9 (alpine 3.9.2)\n===================================\nTotal: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)\n\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |\n|         |                  |          |                   |               | with long nonces               |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n
","title":"Container Images"},{"location":"docs/vulnerability/scanning/image/#tar-files","text":"
$ docker pull ruby:3.1-alpine3.15\n$ docker save ruby:3.1-alpine3.15 -o ruby-3.1.tar\n$ trivy image --input ruby-3.1.tar\n
Result
2022-02-03T10:08:19.127Z        INFO    Detected OS: alpine\n2022-02-03T10:08:19.127Z        WARN    This OS version is not on the EOL list: alpine 3.15\n2022-02-03T10:08:19.127Z        INFO    Detecting Alpine vulnerabilities...\n2022-02-03T10:08:19.127Z        INFO    Number of language-specific files: 2\n2022-02-03T10:08:19.127Z        INFO    Detecting gemspec vulnerabilities...\n2022-02-03T10:08:19.128Z        INFO    Detecting node-pkg vulnerabilities...\n2022-02-03T10:08:19.128Z        WARN    This OS version is no longer supported by the distribution: alpine 3.15.0\n2022-02-03T10:08:19.128Z        WARN    The vulnerability detection may be insufficient because security updates are not provided\n\nruby-3.1.tar (alpine 3.15.0)\n============================\nTotal: 3 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 3, CRITICAL: 0)\n\n+----------+------------------+----------+-------------------+---------------+---------------------------------------+\n| LIBRARY  | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |\n+----------+------------------+----------+-------------------+---------------+---------------------------------------+\n| gmp      | CVE-2021-43618   | HIGH     | 6.2.1-r0          | 6.2.1-r1      | gmp: Integer overflow and resultant   |\n|          |                  |          |                   |               | buffer overflow via crafted input     |\n|          |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-43618 |\n+----------+                  +          +                   +               +                                       +\n| gmp-dev  |                  |          |                   |               |                                       |\n|          |                  |          |                   |               |                                       |\n|          |                  |          |                   |               |                                       |\n+----------+                  +          +                   +               +                                       +\n| libgmpxx |                  |          |                   |               |                                       |\n|          |                  |          |                   |               |                                       |\n|          |                  |          |                   |               |                                       |\n+----------+------------------+----------+-------------------+---------------+---------------------------------------+\n\nNode.js (node-pkg)\n==================\nTotal: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)\n\n\nRuby (gemspec)\n==============\nTotal: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)\n
","title":"Tar Files"},{"location":"docs/vulnerability/scanning/rootfs/","text":"

Scan a root filesystem (such as a host machine, a virtual machine image, or an unpacked container image filesystem).

$ trivy rootfs /path/to/rootfs\n
","title":"Rootfs"},{"location":"docs/vulnerability/scanning/rootfs/#from-inside-containers","text":"

Scan your container from inside the container.

$ docker run --rm -it alpine:3.11\n/ # curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin\n/ # trivy rootfs /\n
Result
2021-03-08T05:22:26.378Z        INFO    Need to update DB\n2021-03-08T05:22:26.380Z        INFO    Downloading DB...\n20.37 MiB / 20.37 MiB [-------------------------------------------------------------------------------------------------------------------------------------] 100.00% 8.24 MiB p/s 2s\n2021-03-08T05:22:30.134Z        INFO    Detecting Alpine vulnerabilities...\n2021-03-08T05:22:30.138Z        INFO    Trivy skips scanning programming language libraries because no supported file was detected\n\n313430f09696 (alpine 3.11.7)\n============================\nTotal: 6 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 6, CRITICAL: 0)\n\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n|   LIBRARY    | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |                 TITLE                 |\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n| libcrypto1.1 | CVE-2021-23839   | HIGH     | 1.1.1i-r0         | 1.1.1j-r0     | openssl: incorrect SSLv2              |\n|              |                  |          |                   |               | rollback protection                   |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |\n|              |                  |          |                   |               | overflow in CipherUpdate              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |\n|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |\n+--------------+------------------+          +                   +               +---------------------------------------+\n| libssl1.1    | CVE-2021-23839   |          |                   |               | openssl: incorrect SSLv2              |\n|              |                  |          |                   |               | rollback protection                   |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23839 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23840   |          |                   |               | openssl: integer                      |\n|              |                  |          |                   |               | overflow in CipherUpdate              |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23840 |\n+              +------------------+          +                   +               +---------------------------------------+\n|              | CVE-2021-23841   |          |                   |               | openssl: NULL pointer dereference     |\n|              |                  |          |                   |               | in X509_issuer_and_serial_hash()      |\n|              |                  |          |                   |               | -->avd.aquasec.com/nvd/cve-2021-23841 |\n+--------------+------------------+----------+-------------------+---------------+---------------------------------------+\n
","title":"From Inside Containers"},{"location":"docs/vulnerability/scanning/rootfs/#other-examples","text":"
  • Embed in Dockerfile
  • Unpacked container image filesystem
","title":"Other Examples"},{"location":"getting-started/further/","text":"","title":"Further Reading"},{"location":"getting-started/further/#presentations","text":"
  • Aqua Security YouTube Channel
    • Trivy - container image scanning
    • Using Trivy in client server mode
    • Tweaking Trivy output to fit your workflow
    • How does a vulnerability scanner identify packages?
  • CNCF Webinar 2020
    • Trivy Open Source Scanner for Container Images \u2013 Just Download and Run!
  • KubeCon + CloudNativeCon Europe 2020 Virtual
    • Handling Container Vulnerabilities with Open Policy Agent - Teppei Fukuda, Aqua Security
","title":"Presentations"},{"location":"getting-started/further/#blogs","text":"
  • Trivy Vulnerability Scanner Joins the Aqua Open-source Family
  • Trivy Image Vulnerability Scanner Now Under Apache 2.0 License
  • DevSecOps with Trivy and GitHub Actions
  • Find Image Vulnerabilities Using GitHub and Aqua Security Trivy Action
  • Using Trivy to Discover Vulnerabilities in VS Code Projects
","title":"Blogs"},{"location":"getting-started/installation/","text":"","title":"Installation"},{"location":"getting-started/installation/#rhelcentos","text":"Repository

Add repository setting to /etc/yum.repos.d.

$ sudo vim /etc/yum.repos.d/trivy.repo\n[trivy]\nname=Trivy repository\nbaseurl=https://aquasecurity.github.io/trivy-repo/rpm/releases/$releasever/$basearch/\ngpgcheck=0\nenabled=1\n$ sudo yum -y update\n$ sudo yum -y install trivy\n
RPM
rpm -ivh https://github.com/aquasecurity/trivy/releases/download/v0.25.4/trivy_0.25.4_Linux-64bit.rpm\n
","title":"RHEL/CentOS"},{"location":"getting-started/installation/#debianubuntu","text":"Repository

Add repository setting to /etc/apt/sources.list.d.

sudo apt-get install wget apt-transport-https gnupg lsb-release\nwget -qO - https://aquasecurity.github.io/trivy-repo/deb/public.key | sudo apt-key add -\necho deb https://aquasecurity.github.io/trivy-repo/deb $(lsb_release -sc) main | sudo tee -a /etc/apt/sources.list.d/trivy.list\nsudo apt-get update\nsudo apt-get install trivy\n
DEB
wget https://github.com/aquasecurity/trivy/releases/download/v0.25.4/trivy_0.25.4_Linux-64bit.deb\nsudo dpkg -i trivy_0.25.4_Linux-64bit.deb\n
","title":"Debian/Ubuntu"},{"location":"getting-started/installation/#arch-linux","text":"

Package trivy-bin can be installed from the Arch User Repository.

pikaur
pikaur -Sy trivy-bin\n
yay
yay -Sy trivy-bin\n
","title":"Arch Linux"},{"location":"getting-started/installation/#homebrew","text":"

You can use homebrew on macOS and Linux.

brew install aquasecurity/trivy/trivy\n
","title":"Homebrew"},{"location":"getting-started/installation/#nixnixos","text":"

You can use nix on Linux or macOS and on others unofficially.

Note that trivy is currently only in the unstable channels.

nix-env --install trivy\n

Or through your configuration on NixOS or with home-manager as usual

","title":"Nix/NixOS"},{"location":"getting-started/installation/#install-script","text":"

This script downloads Trivy binary based on your OS and architecture.

curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin v0.25.4\n
","title":"Install Script"},{"location":"getting-started/installation/#binary","text":"

Download the archive file for your operating system/architecture from here. Unpack the archive, and put the binary somewhere in your $PATH (on UNIX-y systems, /usr/local/bin or the like). Make sure it has execution bits turned on.

","title":"Binary"},{"location":"getting-started/installation/#from-source","text":"
mkdir -p $GOPATH/src/github.com/aquasecurity\ncd $GOPATH/src/github.com/aquasecurity\ngit clone --depth 1 --branch v0.25.4 https://github.com/aquasecurity/trivy\ncd trivy/cmd/trivy/\nexport GO111MODULE=on\ngo install\n
","title":"From source"},{"location":"getting-started/installation/#docker","text":"","title":"Docker"},{"location":"getting-started/installation/#docker-hub","text":"

Replace [YOUR_CACHE_DIR] with the cache directory on your machine.

docker pull aquasec/trivy:0.25.4\n

Example:

Linux
docker run --rm -v [YOUR_CACHE_DIR]:/root/.cache/ aquasec/trivy:0.25.4 image [YOUR_IMAGE_NAME]\n
macOS
docker run --rm -v $HOME/Library/Caches:/root/.cache/ aquasec/trivy:0.25.4 image [YOUR_IMAGE_NAME\n

If you would like to scan the image on your host machine, you need to mount docker.sock.

docker run --rm -v /var/run/docker.sock:/var/run/docker.sock \\\n    -v $HOME/Library/Caches:/root/.cache/ aquasec/trivy:0.25.4 python:3.4-alpine\n

Please re-pull latest aquasec/trivy if an error occurred.

Result
2019-05-16T01:20:43.180+0900    INFO    Updating vulnerability database...\n2019-05-16T01:20:53.029+0900    INFO    Detecting Alpine vulnerabilities...\n\npython:3.4-alpine3.9 (alpine 3.9.2)\n===================================\nTotal: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)\n\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |\n|         |                  |          |                   |               | with long nonces               |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n
","title":"Docker Hub"},{"location":"getting-started/installation/#github-container-registry","text":"

The same image is hosted on GitHub Container Registry as well.

docker pull ghcr.io/aquasecurity/trivy:0.25.4\n
","title":"GitHub Container Registry"},{"location":"getting-started/installation/#amazon-ecr-public","text":"

The same image is hosted on Amazon ECR Public as well.

docker pull public.ecr.aws/aquasecurity/trivy:0.25.4\n
","title":"Amazon ECR Public"},{"location":"getting-started/installation/#helm","text":"","title":"Helm"},{"location":"getting-started/installation/#installing-from-the-the-aqua-chart-repository","text":"
helm repo add aquasecurity https://aquasecurity.github.io/helm-charts/\nhelm repo update\nhelm search repo trivy\nhelm install my-trivy aquasecurity/trivy\n
","title":"Installing from the the Aqua Chart Repository"},{"location":"getting-started/installation/#installing-the-chart","text":"

To install the chart with the release name my-release:

helm install my-release .\n

The command deploys Trivy on the Kubernetes cluster in the default configuration. The Parameters section lists the parameters that can be configured during installation.

Tip: List all releases using helm list.

","title":"Installing the Chart"},{"location":"getting-started/overview/","text":"

Trivy detects two types of security issues:

  • Vulnerabilities
    • OS packages (Alpine, Red Hat Universal Base Image, Red Hat Enterprise Linux, CentOS, AlmaLinux, Rocky Linux, CBL-Mariner, Oracle Linux, Debian, Ubuntu, Amazon Linux, openSUSE Leap, SUSE Enterprise Linux, Photon OS and Distroless)
    • Language-specific packages (Bundler, Composer, Pipenv, Poetry, npm, yarn, Cargo, NuGet, Maven, and Go)
  • Misconfigurations
    • Kubernetes
    • Docker
    • Terraform
    • CloudFormation
    • more coming soon

Trivy can scan three different artifacts:

  • Container Images
  • Filesystem
  • Git Repositories

It is designed to be used in CI. Before pushing to a container registry or deploying your application, you can scan your local container image and other artifacts easily. See Integrations for details.

","title":"Overview"},{"location":"getting-started/quickstart/","text":"","title":"Quick Start"},{"location":"getting-started/quickstart/#scan-image-for-vulnerabilities","text":"

Simply specify an image name (and a tag).

$ trivy image [YOUR_IMAGE_NAME]\n

For example:

$ trivy image python:3.4-alpine\n
Result
2019-05-16T01:20:43.180+0900    INFO    Updating vulnerability database...\n2019-05-16T01:20:53.029+0900    INFO    Detecting Alpine vulnerabilities...\n\npython:3.4-alpine3.9 (alpine 3.9.2)\n===================================\nTotal: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 1, HIGH: 0, CRITICAL: 0)\n\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| LIBRARY | VULNERABILITY ID | SEVERITY | INSTALLED VERSION | FIXED VERSION |             TITLE              |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n| openssl | CVE-2019-1543    | MEDIUM   | 1.1.1a-r1         | 1.1.1b-r1     | openssl: ChaCha20-Poly1305     |\n|         |                  |          |                   |               | with long nonces               |\n+---------+------------------+----------+-------------------+---------------+--------------------------------+\n

For more details, see here.

","title":"Scan image for vulnerabilities"},{"location":"getting-started/quickstart/#scan-directory-for-misconfigurations","text":"

Simply specify a directory containing IaC files such as Terraform and Dockerfile.

$ trivy config [YOUR_IAC_DIR]\n

For example:

$ ls build/\nDockerfile\n$ trivy config ./build\n
Result
2021-07-09T10:06:29.188+0300    INFO    Need to update the built-in policies\n2021-07-09T10:06:29.188+0300    INFO    Downloading the built-in policies...\n2021-07-09T10:06:30.520+0300    INFO    Detected config files: 1\n\nDockerfile (dockerfile)\n=======================\nTests: 23 (SUCCESSES: 22, FAILURES: 1, EXCEPTIONS: 0)\nFailures: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)\n\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n|           TYPE            | MISCONF ID |        CHECK         | SEVERITY |                 MESSAGE                  |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n| Dockerfile Security Check |   DS002    | Image user is 'root' |   HIGH   | Last USER command in                     |\n|                           |            |                      |          | Dockerfile should not be 'root'          |\n|                           |            |                      |          | -->avd.aquasec.com/appshield/ds002       |\n+---------------------------+------------+----------------------+----------+------------------------------------------+\n

For more details, see here.

","title":"Scan directory for misconfigurations"}]} \ No newline at end of file diff --git a/v0.25.4/sitemap.xml b/v0.25.4/sitemap.xml new file mode 100644 index 0000000000..a9a96846ad --- /dev/null +++ b/v0.25.4/sitemap.xml @@ -0,0 +1,408 @@ + + + + https://aquasecurity.github.io/trivy/v0.25.4/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/cks/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/credit/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/references/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/tools/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/contribute/issue/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/contribute/pr/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/maintainer/help-wanted/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/community/maintainer/triage/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/air-gap/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/plugins/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/container/embed-in-dockerfile/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/container/oci/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/container/podman/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/container/unpacked-filesystem/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/private-registries/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/private-registries/acr/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/private-registries/docker-hub/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/private-registries/ecr/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/private-registries/gcr/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/advanced/private-registries/self/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/aws-codepipeline/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/aws-security-hub/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/bitbucket/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/circleci/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/github-actions/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/gitlab-ci/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/integrations/travis-ci/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/filesystem/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/iac/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/comparison/cfsec/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/comparison/conftest/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/comparison/tfsec/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/custom/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/custom/combine/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/custom/data/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/custom/debug/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/custom/examples/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/custom/testing/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/options/filter/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/options/others/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/options/policy/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/options/report/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/policy/builtin/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/misconfiguration/policy/exceptions/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/troubleshooting/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/client/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/config/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/fs/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/image/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/plugins/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/repo/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/rootfs/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/sbom/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/cli/server/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/modes/client-server/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/references/modes/standalone/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/sbom/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/sbom/cyclonedx/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/detection/data-source/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/detection/language/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/detection/os/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/detection/supported/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/examples/cache/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/examples/db/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/examples/filter/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/examples/others/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/examples/report/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/scanning/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/scanning/filesystem/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/scanning/git-repository/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/scanning/image/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/docs/vulnerability/scanning/rootfs/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/getting-started/further/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/getting-started/installation/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/getting-started/overview/ + 2022-04-11 + daily + + + https://aquasecurity.github.io/trivy/v0.25.4/getting-started/quickstart/ + 2022-04-11 + daily + + \ No newline at end of file diff --git a/v0.25.4/sitemap.xml.gz b/v0.25.4/sitemap.xml.gz new file mode 100644 index 0000000000..db3d5d6ffe Binary files /dev/null and b/v0.25.4/sitemap.xml.gz differ diff --git a/versions.json b/versions.json index d665251b07..ecbafe67b2 100644 --- a/versions.json +++ b/versions.json @@ -1 +1 @@ -[{"version": "v0.25.3", "title": "v0.25.3", "aliases": ["latest"]}, {"version": "v0.25.2", "title": "v0.25.2", "aliases": []}, {"version": "v0.25.1", "title": "v0.25.1", "aliases": []}, {"version": "v0.25.0", "title": "v0.25.0", "aliases": []}, {"version": "v0.24.4", "title": "v0.24.4", "aliases": []}, {"version": "v0.24.3", "title": "v0.24.3", "aliases": []}, {"version": "v0.24.2", "title": "v0.24.2", "aliases": []}, {"version": "v0.24.1", "title": "v0.24.1", "aliases": []}, {"version": "v0.24.0", "title": "v0.24.0", "aliases": []}, {"version": "v0.23.0", "title": "v0.23.0", "aliases": []}, {"version": "v0.22.0", "title": "v0.22.0", "aliases": []}, {"version": "v0.21.3", "title": "v0.21.3", "aliases": []}, {"version": "v0.21.2", "title": "v0.21.2", "aliases": []}, {"version": "v0.21.1", "title": "v0.21.1", "aliases": []}, {"version": "v0.21.0", "title": "v0.21.0", "aliases": []}, {"version": "v0.20.2", "title": "v0.20.2", "aliases": []}, {"version": "v0.20.1", "title": "v0.20.1", "aliases": []}, {"version": "v0.20.0", "title": "v0.20.0", "aliases": []}, {"version": "v0.19.2", "title": "v0.19.2", "aliases": []}, {"version": "v0.19.1", "title": "v0.19.1", "aliases": []}, {"version": "v0.19.0", "title": "v0.19.0", "aliases": []}, {"version": "v0.18.3", "title": "v0.18.3", "aliases": []}, {"version": "v0.18.2", "title": "v0.18.2", "aliases": []}, {"version": "v0.18.1", "title": "v0.18.1", "aliases": []}, {"version": "v0.18.0", "title": "v0.18.0", "aliases": []}, {"version": "v0.17.2", "title": "v0.17.2", "aliases": []}, {"version": "v0.17.1", "title": "v0.17.1", "aliases": []}, {"version": "v0.17.0", "title": "v0.17.0", "aliases": []}, {"version": "v0.16.0", "title": "v0.16.0", "aliases": []}, {"version": "v0.15.0", "title": "v0.15.0", "aliases": []}, {"version": "dev", "title": "dev", "aliases": []}] \ No newline at end of file +[{"version": "v0.25.4", "title": "v0.25.4", "aliases": ["latest"]}, {"version": "v0.25.3", "title": "v0.25.3", "aliases": []}, {"version": "v0.25.2", "title": "v0.25.2", "aliases": []}, {"version": "v0.25.1", "title": "v0.25.1", "aliases": []}, {"version": "v0.25.0", "title": "v0.25.0", "aliases": []}, {"version": "v0.24.4", "title": "v0.24.4", "aliases": []}, {"version": "v0.24.3", "title": "v0.24.3", "aliases": []}, {"version": "v0.24.2", "title": "v0.24.2", "aliases": []}, {"version": "v0.24.1", "title": "v0.24.1", "aliases": []}, {"version": "v0.24.0", "title": "v0.24.0", "aliases": []}, {"version": "v0.23.0", "title": "v0.23.0", "aliases": []}, {"version": "v0.22.0", "title": "v0.22.0", "aliases": []}, {"version": "v0.21.3", "title": "v0.21.3", "aliases": []}, {"version": "v0.21.2", "title": "v0.21.2", "aliases": []}, {"version": "v0.21.1", "title": "v0.21.1", "aliases": []}, {"version": "v0.21.0", "title": "v0.21.0", "aliases": []}, {"version": "v0.20.2", "title": "v0.20.2", "aliases": []}, {"version": "v0.20.1", "title": "v0.20.1", "aliases": []}, {"version": "v0.20.0", "title": "v0.20.0", "aliases": []}, {"version": "v0.19.2", "title": "v0.19.2", "aliases": []}, {"version": "v0.19.1", "title": "v0.19.1", "aliases": []}, {"version": "v0.19.0", "title": "v0.19.0", "aliases": []}, {"version": "v0.18.3", "title": "v0.18.3", "aliases": []}, {"version": "v0.18.2", "title": "v0.18.2", "aliases": []}, {"version": "v0.18.1", "title": "v0.18.1", "aliases": []}, {"version": "v0.18.0", "title": "v0.18.0", "aliases": []}, {"version": "v0.17.2", "title": "v0.17.2", "aliases": []}, {"version": "v0.17.1", "title": "v0.17.1", "aliases": []}, {"version": "v0.17.0", "title": "v0.17.0", "aliases": []}, {"version": "v0.16.0", "title": "v0.16.0", "aliases": []}, {"version": "v0.15.0", "title": "v0.15.0", "aliases": []}, {"version": "dev", "title": "dev", "aliases": []}] \ No newline at end of file