GHSA-w2j5-3rcx-vx7x: Github.com/cri o/cri o Sysctls Applied To Containers With Vulnerability
MODERATEGHSA-w2j5-3rcx-vx7x is a MODERATE sysctls applied to containers with vulnerability (General Security Weakness) affecting Github.com/cri o/cri o libraries in the Go ecosystem. The issue involves sysctls applied to containers with host ipc or host network namespaces can affect the host. Remediation is available by upgrading affected packages to version 1.23.1, 1.22.2, 1.21.5, 1.20.6, 1.19.5.
GHSA-w2j5-3rcx-vx7x at a Glance
How to Fix GHSA-w2j5-3rcx-vx7x
To remediate this vulnerability, upgrade all affected Github.com/cri o/cri o dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade github.com/cri-o/cri-o to 1.23.1
Upgrade github.com/cri-o/cri-o to 1.22.2
Upgrade github.com/cri-o/cri-o to 1.21.5
Upgrade github.com/cri-o/cri-o to 1.20.6
Upgrade github.com/cri-o/cri-o to 1.19.5
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/cri-o/cri-o
How to Check if You Are Affected
To determine whether your application is affected by GHSA-w2j5-3rcx-vx7x, inspect your project dependencies for Github.com/cri o/cri o:
inspect dependencies for github.com/cri-o/cri-o
Analyze the terminal output to locate any version of Github.com/cri o/cri o in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.23.1), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under General Security Weakness. In Github.com/cri o/cri o, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-w2j5-3rcx-vx7x Affected Github.com/cri o/cri o Versions
5 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/cri-o/cri-o
|
Go |
≥ 1.23.0
< 1.23.1
|
1.23.1
|
|
github.com/cri-o/cri-o
|
Go |
≥ 1.22.0
< 1.22.2
|
1.22.2
|
|
github.com/cri-o/cri-o
|
Go |
≥ 1.21.0
< 1.21.5
|
1.21.5
|
|
github.com/cri-o/cri-o
|
Go |
≥ 1.20.0
< 1.20.6
|
1.20.6
|
|
github.com/cri-o/cri-o
|
Go |
≥ 1.18.0
< 1.19.5
|
1.19.5
|
References
Frequently Asked Questions
What is GHSA-w2j5-3rcx-vx7x?
Which Github.com/cri o/cri o versions are affected?
What version fixes GHSA-w2j5-3rcx-vx7x?
Is github.com/cri-o/cri-o affected?
What CWE is associated with GHSA-w2j5-3rcx-vx7x?
How can I check Go dependencies for GHSA-w2j5-3rcx-vx7x?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-w2j5-3rcx-vx7x",
"modified" : "2022-03-15T20:02:54Z",
"published" : "2022-03-15T20:02:54Z",
"aliases" : [ ],
"summary" : "Sysctls applied to containers with host IPC or host network namespaces can affect the host",
"details" : "### Impact\nBefore setting the sysctls for a pod, the pods namespaces must be unshared (created). However, in cases where the pod is using a host network or IPC namespace, a bug in CRI-O caused the namespace creating tool [pinns](https://github.com/cri-o/cri-o/tree/main/pinns/) to configure the sysctls of the host. This allows a malicious user to set sysctls on the host, assuming they have access to hostNetwork and hostIPC.\n\nAny CRI-O cluster after CRI-O 1.18 that drops the infra container\n1.22 and 1.23 clusters drop infra container by default, and are thus vulnerable by default.\n\n### Patches\nCRI-O versions 1.24.0, 1.23.1, 1.22.2, 1.21.5, 1.20.6, 1.19.5 all have the patches.\n\n### Workarounds\nUsers can set `manage_ns_lifecycle` to false, which causes the sysctls to be configured by the OCI runtime, which typically filter these cases. This option is available in 1.20 and 1.19. Newer versions don't have this option.\nAn admission webhook could also be created to deny pods that use host IPC or network namespaces and also attempt to configure sysctls related to that namespace.\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open an issue in [the CRI-O repo](http://github.com/cri-o/cri-o/issues)\n* To make a report, email your vulnerability to the private\n[cncf-crio-security@lists.cncf.io](mailto:cncf-crio-security@lists.cncf.io) list\nwith the security details and the details expected for [all CRI-O bug\nreports](https://github.com/cri-o/cri-o/blob/main/.github/ISSUE_TEMPLATE/bug-report.yml).",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/cri-o/cri-o"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.23.0"
}, {
"fixed" : "1.23.1"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/cri-o/cri-o"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.22.0"
}, {
"fixed" : "1.22.2"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/cri-o/cri-o"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.21.0"
}, {
"fixed" : "1.21.5"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/cri-o/cri-o"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.20.0"
}, {
"fixed" : "1.20.6"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/cri-o/cri-o"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.18.0"
}, {
"fixed" : "1.19.5"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/cri-o/cri-o/security/advisories/GHSA-w2j5-3rcx-vx7x"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/cri-o/cri-o"
} ],
"database_specific" : {
"cwe_ids" : [ ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2022-03-15T20:02:54Z",
"nvd_published_at" : null
}
}