Accepting request 487271 from home:jordimassaguerpla:branch:V:c:runc:ignore_cgroup_v2_mountpoints

- fix bsc#1028113 - runc: make sure to ignore cgroup v2 mountpoints

OBS-URL: https://build.opensuse.org/request/show/487271
OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/runc?expand=0&rev=41
This commit is contained in:
Aleksa Sarai 2017-04-11 09:56:51 +00:00 committed by Git OBS Bridge
parent b55f5ac831
commit b0463e5979
3 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,13 @@
diff --git a/libcontainer/cgroups/utils.go.orig b/libcontainer/cgroups/utils.go
index 8946dd5..c6db003 100644
--- a/libcontainer/cgroups/utils.go.orig
+++ b/libcontainer/cgroups/utils.go
@@ -149,7 +149,7 @@ func getCgroupMountsHelper(ss map[string]bool, mi io.Reader, all bool) ([]Mount,
if sepIdx == -1 {
return nil, fmt.Errorf("invalid mountinfo format")
}
- if txt[sepIdx+3:sepIdx+9] != "cgroup" {
+ if txt[sepIdx+3:sepIdx+10] == "cgroup2" || txt[sepIdx+3:sepIdx+9] != "cgroup" {
continue
}
fields := strings.Split(txt, " ")

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Wed Mar 29 15:47:52 UTC 2017 - jmassaguerpla@suse.com
- fix bsc#1028113 - runc: make sure to ignore cgroup v2 mountpoints
-------------------------------------------------------------------
Fri Feb 24 18:08:10 UTC 2017 - jmassaguerpla@suse.com

View File

@ -58,6 +58,7 @@ Group: System/Management
Url: https://github.com/opencontainers/runc
Source: %{name}-git.%{git_version}.tar.xz
Patch0: CVE-2016-9962.patch
Patch1: ignore_cgroup2_mountpoint.patch
BuildRequires: fdupes
%ifarch %go_arches
BuildRequires: go >= 1.5
@ -104,6 +105,9 @@ Test package for runc. It contains the source code and the tests.
%prep
%setup -q -n %{name}-git.%{git_version}
%patch0 -p1
%if 0%{?suse_version} > 1320
%patch1 -p1
%endif
%build
# Do not use symlinks. If you want to run the unit tests for this package at