Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix all known trivy scan vulnerabilities #1516

Merged
merged 2 commits into from
Nov 19, 2022

Conversation

hookenz
Copy link
Contributor

@hookenz hookenz commented Aug 28, 2022

Since the last go modules update I did was merged, more vulnerabilities have since been reported.

This update, fixes those as well.

Before:

❯ trivy fs .
2022-08-29T09:22:17.963+1200	INFO	Number of language-specific files: 2
2022-08-29T09:22:17.963+1200	INFO	Detecting bundler vulnerabilities...
2022-08-29T09:22:17.963+1200	INFO	Detecting gomod vulnerabilities...

docs/Gemfile.lock (bundler)

Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 1, CRITICAL: 0)

┌─────────┬────────────────┬──────────┬───────────────────┬──────────────────────┬────────────────────────────────────────────┐
│ Library │ Vulnerability  │ Severity │ Installed Version │    Fixed Version     │                   Title                    │
├─────────┼────────────────┼──────────┼───────────────────┼──────────────────────┼────────────────────────────────────────────┤
│ tzinfo  │ CVE-2022-31163 │ HIGH     │ 1.2.9             │ ~> 0.3.61, >= 1.2.10 │ rubygem-tzinfo: arbitrary code execution   │
│         │                │          │                   │                      │ https://avd.aquasec.com/nvd/cve-2022-31163 │
└─────────┴────────────────┴──────────┴───────────────────┴──────────────────────┴────────────────────────────────────────────┘

go.mod (gomod)

Total: 7 (UNKNOWN: 3, LOW: 0, MEDIUM: 2, HIGH: 1, CRITICAL: 1)

┌──────────────────────────────────┬─────────────────────┬──────────┬───────────────────────────────────┬───────────────────────────────────┬──────────────────────────────────────────────────────────────┐
│             Library              │    Vulnerability    │ Severity │         Installed Version         │           Fixed Version           │                            Title                             │
├──────────────────────────────────┼─────────────────────┼──────────┼───────────────────────────────────┼───────────────────────────────────┼──────────────────────────────────────────────────────────────┤
│ github.com/containerd/containerd │ CVE-2022-31030      │ MEDIUM   │ 1.6.4                             │ v1.5.13, v1.6.6                   │ containerd is an open source container runtime. A bug was    │
│                                  │                     │          │                                   │                                   │ found in...                                                  │
│                                  │                     │          │                                   │                                   │ https://avd.aquasec.com/nvd/cve-2022-31030                   │
│                                  ├─────────────────────┼──────────┤                                   │                                   ├──────────────────────────────────────────────────────────────┤
│                                  │ GHSA-5ffw-gxpp-mxpf │ UNKNOWN  │                                   │                                   │ Improper Neutralization of Special Elements used in an OS    │
│                                  │                     │          │                                   │                                   │ Command ('OS Command...                                      │
│                                  │                     │          │                                   │                                   │ https://github.com/advisories/GHSA-5ffw-gxpp-mxpf            │
├──────────────────────────────────┼─────────────────────┼──────────┼───────────────────────────────────┼───────────────────────────────────┼──────────────────────────────────────────────────────────────┤
│ github.com/emicklei/go-restful   │ CVE-2022-1996       │ CRITICAL │ 2.9.5+incompatible                │ 2.16.0                            │ go-restful: Authorization Bypass Through User-Controlled Key │
│                                  │                     │          │                                   │                                   │ https://avd.aquasec.com/nvd/cve-2022-1996                    │
├──────────────────────────────────┼─────────────────────┼──────────┼───────────────────────────────────┼───────────────────────────────────┼──────────────────────────────────────────────────────────────┤
│ github.com/emicklei/go-restful   │ GHSA-r48q-9g5r-8q2h │ UNKNOWN  │ 2.9.5+incompatible                │ 2.16.0                            │ CORS filters that use an AllowedDomains configuration        │
│                                  │                     │          │                                   │                                   │ parameter                                                    │
│                                  │                     │          │                                   │                                   │ can match domains outside the...                             │
│                                  │                     │          │                                   │                                   │ https://github.com/advisories/GHSA-r48q-9g5r-8q2h            │
├──────────────────────────────────┼─────────────────────┼──────────┼───────────────────────────────────┼───────────────────────────────────┼──────────────────────────────────────────────────────────────┤
│ golang.org/x/crypto              │ CVE-2022-27191      │ HIGH     │ 0.0.0-20210817164053-32db794688a5 │ 0.0.0-20220314234659-1baeb1ce4c0b │ golang: crash in a golang.org/x/crypto/ssh server            │
│                                  │                     │          │                                   │                                   │ https://avd.aquasec.com/nvd/cve-2022-27191                   │
├──────────────────────────────────┼─────────────────────┼──────────┼───────────────────────────────────┼───────────────────────────────────┼──────────────────────────────────────────────────────────────┤
│ golang.org/x/crypto              │ GHSA-8c26-wmh5-6g9v │ UNKNOWN  │ 0.0.0-20210817164053-32db794688a5 │ 0.0.0-20220314234659-1baeb1ce4c0b │ Attackers can cause a crash in SSH servers when the server   │
│                                  │                     │          │                                   │                                   │ has...                                                       │
│                                  │                     │          │                                   │                                   │ https://github.com/advisories/GHSA-8c26-wmh5-6g9v            │
├──────────────────────────────────┼─────────────────────┼──────────┼───────────────────────────────────┼───────────────────────────────────┼──────────────────────────────────────────────────────────────┤
│ golang.org/x/sys                 │ CVE-2022-29526      │ MEDIUM   │ 0.0.0-20220319134239-a9b59b0215f8 │ 0.0.0-20220412211240-33da011f77ad │ golang: syscall: faccessat checks wrong group                │
│                                  │                     │          │                                   │                                   │ https://avd.aquasec.com/nvd/cve-2022-29526                   │
└──────────────────────────────────┴─────────────────────┴──────────┴───────────────────────────────────┴───────────────────────────────────┴──────────────────────────────────────────────────────────────┘

After:

❯ trivy fs .
2022-08-29T09:14:32.395+1200	INFO	Number of language-specific files: 2
2022-08-29T09:14:32.395+1200	INFO	Detecting bundler vulnerabilities...
2022-08-29T09:14:32.396+1200	INFO	Detecting gomod vulnerabilities...

docs/Gemfile.lock (bundler)

Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)


go.mod (gomod)

Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Aug 28, 2022
Copy link
Contributor Author

@hookenz hookenz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/assign @cdrage

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 12, 2022
@hookenz hookenz force-pushed the chore/fix-trivy-scan-issues branch from f42c5c8 to 779dbf8 Compare November 16, 2022 20:58
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 16, 2022
@hangyan
Copy link
Contributor

hangyan commented Nov 19, 2022

Looks good. Thanks

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hangyan, hookenz

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 19, 2022
@hangyan hangyan merged commit af82f7e into kubernetes:master Nov 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants