{"action":"created","comment":{"url":"https://api.github.com/repos/opencontainers/runc/pulls/comments/48703232","id":48703232,"diff_hunk":"@@ -95,6 +95,10 @@ func (s *CpusetGroup) ensureParent(current, root string) error {\n \tif filepath.Clean(parent) == root {\n \t\treturn nil\n \t}\n+\t// Avoid infinite recursion.\n+\tif parent == current {\n+\t\treturn nil\n+\t}","path":"libcontainer/cgroups/fs/cpuset.go","position":7,"original_position":7,"commit_id":"bc738fbe8b856aaeb0ef732be9a9b217d054d7ac","original_commit_id":"bc738fbe8b856aaeb0ef732be9a9b217d054d7ac","user":{"login":"hqhq","id":6415670,"avatar_url":"https://avatars.githubusercontent.com/u/6415670?v=3","gravatar_id":"","url":"https://api.github.com/users/hqhq","html_url":"https://github.com/hqhq","followers_url":"https://api.github.com/users/hqhq/followers","following_url":"https://api.github.com/users/hqhq/following{/other_user}","gists_url":"https://api.github.com/users/hqhq/gists{/gist_id}","starred_url":"https://api.github.com/users/hqhq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hqhq/subscriptions","organizations_url":"https://api.github.com/users/hqhq/orgs","repos_url":"https://api.github.com/users/hqhq/repos","events_url":"https://api.github.com/users/hqhq/events{/privacy}","received_events_url":"https://api.github.com/users/hqhq/received_events","type":"User","site_admin":false},"body":"In what case would parent equals to current? Did you hit this in real life?","created_at":"2016-01-04T04:03:03Z","updated_at":"2016-01-04T04:03:03Z","html_url":"https://github.com/opencontainers/runc/pull/451#discussion_r48703232","pull_request_url":"https://api.github.com/repos/opencontainers/runc/pulls/451","_links":{"self":{"href":"https://api.github.com/repos/opencontainers/runc/pulls/comments/48703232"},"html":{"href":"https://github.com/opencontainers/runc/pull/451#discussion_r48703232"},"pull_request":{"href":"https://api.github.com/repos/opencontainers/runc/pulls/451"}}},"pull_request":{"url":"https://api.github.com/repos/opencontainers/runc/pulls/451","id":54882154,"html_url":"https://github.com/opencontainers/runc/pull/451","diff_url":"https://github.com/opencontainers/runc/pull/451.diff","patch_url":"https://github.com/opencontainers/runc/pull/451.patch","issue_url":"https://api.github.com/repos/opencontainers/runc/issues/451","number":451,"state":"open","locked":false,"title":"cgroups: fs: fix cgroup.Parent path sanitisation","user":{"login":"cyphar","id":2888411,"avatar_url":"https://avatars.githubusercontent.com/u/2888411?v=3","gravatar_id":"","url":"https://api.github.com/users/cyphar","html_url":"https://github.com/cyphar","followers_url":"https://api.github.com/users/cyphar/followers","following_url":"https://api.github.com/users/cyphar/following{/other_user}","gists_url":"https://api.github.com/users/cyphar/gists{/gist_id}","starred_url":"https://api.github.com/users/cyphar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cyphar/subscriptions","organizations_url":"https://api.github.com/users/cyphar/orgs","repos_url":"https://api.github.com/users/cyphar/repos","events_url":"https://api.github.com/users/cyphar/events{/privacy}","received_events_url":"https://api.github.com/users/cyphar/received_events","type":"User","site_admin":false},"body":"Properly sanitise the --cgroup-parent path, to avoid potential issues\r\n(as it starts creating directories and writing to files as root). In\r\naddition, fix an infinite recursion due to incomplete base cases.\r\n\r\nSigned-off-by: Aleksa Sarai <asarai@suse.com>\r\n\r\n/cc @security-team @diogomonica","created_at":"2015-12-31T22:04:53Z","updated_at":"2016-01-04T04:03:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ccaa859f34bc721a4d35669a351995e0e06a1614","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/opencontainers/runc/pulls/451/commits","review_comments_url":"https://api.github.com/repos/opencontainers/runc/pulls/451/comments","review_comment_url":"https://api.github.com/repos/opencontainers/runc/pulls/comments{/number}","comments_url":"https://api.github.com/repos/opencontainers/runc/issues/451/comments","statuses_url":"https://api.github.com/repos/opencontainers/runc/statuses/bc738fbe8b856aaeb0ef732be9a9b217d054d7ac","head":{"label":"cyphar:fix-infinite-recursion","ref":"fix-infinite-recursion","sha":"bc738fbe8b856aaeb0ef732be9a9b217d054d7ac","user":{"login":"cyphar","id":2888411,"avatar_url":"https://avatars.githubusercontent.com/u/2888411?v=3","gravatar_id":"","url":"https://api.github.com/users/cyphar","html_url":"https://github.com/cyphar","followers_url":"https://api.github.com/users/cyphar/followers","following_url":"https://api.github.com/users/cyphar/following{/other_user}","gists_url":"https://api.github.com/users/cyphar/gists{/gist_id}","starred_url":"https://api.github.com/users/cyphar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cyphar/subscriptions","organizations_url":"https://api.github.com/users/cyphar/orgs","repos_url":"https://api.github.com/users/cyphar/repos","events_url":"https://api.github.com/users/cyphar/events{/privacy}","received_events_url":"https://api.github.com/users/cyphar/received_events","type":"User","site_admin":false},"repo":{"id":38178794,"name":"runc","full_name":"cyphar/runc","owner":{"login":"cyphar","id":2888411,"avatar_url":"https://avatars.githubusercontent.com/u/2888411?v=3","gravatar_id":"","url":"https://api.github.com/users/cyphar","html_url":"https://github.com/cyphar","followers_url":"https://api.github.com/users/cyphar/followers","following_url":"https://api.github.com/users/cyphar/following{/other_user}","gists_url":"https://api.github.com/users/cyphar/gists{/gist_id}","starred_url":"https://api.github.com/users/cyphar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cyphar/subscriptions","organizations_url":"https://api.github.com/users/cyphar/orgs","repos_url":"https://api.github.com/users/cyphar/repos","events_url":"https://api.github.com/users/cyphar/events{/privacy}","received_events_url":"https://api.github.com/users/cyphar/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/cyphar/runc","description":"runc container cli tools","fork":true,"url":"https://api.github.com/repos/cyphar/runc","forks_url":"https://api.github.com/repos/cyphar/runc/forks","keys_url":"https://api.github.com/repos/cyphar/runc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cyphar/runc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cyphar/runc/teams","hooks_url":"https://api.github.com/repos/cyphar/runc/hooks","issue_events_url":"https://api.github.com/repos/cyphar/runc/issues/events{/number}","events_url":"https://api.github.com/repos/cyphar/runc/events","assignees_url":"https://api.github.com/repos/cyphar/runc/assignees{/user}","branches_url":"https://api.github.com/repos/cyphar/runc/branches{/branch}","tags_url":"https://api.github.com/repos/cyphar/runc/tags","blobs_url":"https://api.github.com/repos/cyphar/runc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cyphar/runc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cyphar/runc/git/refs{/sha}","trees_url":"https://api.github.com/repos/cyphar/runc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cyphar/runc/statuses/{sha}","languages_url":"https://api.github.com/repos/cyphar/runc/languages","stargazers_url":"https://api.github.com/repos/cyphar/runc/stargazers","contributors_url":"https://api.github.com/repos/cyphar/runc/contributors","subscribers_url":"https://api.github.com/repos/cyphar/runc/subscribers","subscription_url":"https://api.github.com/repos/cyphar/runc/subscription","commits_url":"https://api.github.com/repos/cyphar/runc/commits{/sha}","git_commits_url":"https://api.github.com/repos/cyphar/runc/git/commits{/sha}","comments_url":"https://api.github.com/repos/cyphar/runc/comments{/number}","issue_comment_url":"https://api.github.com/repos/cyphar/runc/issues/comments{/number}","contents_url":"https://api.github.com/repos/cyphar/runc/contents/{+path}","compare_url":"https://api.github.com/repos/cyphar/runc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cyphar/runc/merges","archive_url":"https://api.github.com/repos/cyphar/runc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cyphar/runc/downloads","issues_url":"https://api.github.com/repos/cyphar/runc/issues{/number}","pulls_url":"https://api.github.com/repos/cyphar/runc/pulls{/number}","milestones_url":"https://api.github.com/repos/cyphar/runc/milestones{/number}","notifications_url":"https://api.github.com/repos/cyphar/runc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cyphar/runc/labels{/name}","releases_url":"https://api.github.com/repos/cyphar/runc/releases{/id}","created_at":"2015-06-27T23:14:24Z","updated_at":"2015-06-27T23:14:26Z","pushed_at":"2016-01-02T16:33:27Z","git_url":"git://github.com/cyphar/runc.git","ssh_url":"git@github.com:cyphar/runc.git","clone_url":"https://github.com/cyphar/runc.git","svn_url":"https://github.com/cyphar/runc","homepage":"","size":2208,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"opencontainers:master","ref":"master","sha":"d97d5e8b007e4657316eed76ea30bc0f690230cf","user":{"login":"opencontainers","id":12563465,"avatar_url":"https://avatars.githubusercontent.com/u/12563465?v=3","gravatar_id":"","url":"https://api.github.com/users/opencontainers","html_url":"https://github.com/opencontainers","followers_url":"https://api.github.com/users/opencontainers/followers","following_url":"https://api.github.com/users/opencontainers/following{/other_user}","gists_url":"https://api.github.com/users/opencontainers/gists{/gist_id}","starred_url":"https://api.github.com/users/opencontainers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opencontainers/subscriptions","organizations_url":"https://api.github.com/users/opencontainers/orgs","repos_url":"https://api.github.com/users/opencontainers/repos","events_url":"https://api.github.com/users/opencontainers/events{/privacy}","received_events_url":"https://api.github.com/users/opencontainers/received_events","type":"Organization","site_admin":false},"repo":{"id":36960321,"name":"runc","full_name":"opencontainers/runc","owner":{"login":"opencontainers","id":12563465,"avatar_url":"https://avatars.githubusercontent.com/u/12563465?v=3","gravatar_id":"","url":"https://api.github.com/users/opencontainers","html_url":"https://github.com/opencontainers","followers_url":"https://api.github.com/users/opencontainers/followers","following_url":"https://api.github.com/users/opencontainers/following{/other_user}","gists_url":"https://api.github.com/users/opencontainers/gists{/gist_id}","starred_url":"https://api.github.com/users/opencontainers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opencontainers/subscriptions","organizations_url":"https://api.github.com/users/opencontainers/orgs","repos_url":"https://api.github.com/users/opencontainers/repos","events_url":"https://api.github.com/users/opencontainers/events{/privacy}","received_events_url":"https://api.github.com/users/opencontainers/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/opencontainers/runc","description":"runc container cli tools","fork":false,"url":"https://api.github.com/repos/opencontainers/runc","forks_url":"https://api.github.com/repos/opencontainers/runc/forks","keys_url":"https://api.github.com/repos/opencontainers/runc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opencontainers/runc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opencontainers/runc/teams","hooks_url":"https://api.github.com/repos/opencontainers/runc/hooks","issue_events_url":"https://api.github.com/repos/opencontainers/runc/issues/events{/number}","events_url":"https://api.github.com/repos/opencontainers/runc/events","assignees_url":"https://api.github.com/repos/opencontainers/runc/assignees{/user}","branches_url":"https://api.github.com/repos/opencontainers/runc/branches{/branch}","tags_url":"https://api.github.com/repos/opencontainers/runc/tags","blobs_url":"https://api.github.com/repos/opencontainers/runc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opencontainers/runc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opencontainers/runc/git/refs{/sha}","trees_url":"https://api.github.com/repos/opencontainers/runc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opencontainers/runc/statuses/{sha}","languages_url":"https://api.github.com/repos/opencontainers/runc/languages","stargazers_url":"https://api.github.com/repos/opencontainers/runc/stargazers","contributors_url":"https://api.github.com/repos/opencontainers/runc/contributors","subscribers_url":"https://api.github.com/repos/opencontainers/runc/subscribers","subscription_url":"https://api.github.com/repos/opencontainers/runc/subscription","commits_url":"https://api.github.com/repos/opencontainers/runc/commits{/sha}","git_commits_url":"https://api.github.com/repos/opencontainers/runc/git/commits{/sha}","comments_url":"https://api.github.com/repos/opencontainers/runc/comments{/number}","issue_comment_url":"https://api.github.com/repos/opencontainers/runc/issues/comments{/number}","contents_url":"https://api.github.com/repos/opencontainers/runc/contents/{+path}","compare_url":"https://api.github.com/repos/opencontainers/runc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opencontainers/runc/merges","archive_url":"https://api.github.com/repos/opencontainers/runc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opencontainers/runc/downloads","issues_url":"https://api.github.com/repos/opencontainers/runc/issues{/number}","pulls_url":"https://api.github.com/repos/opencontainers/runc/pulls{/number}","milestones_url":"https://api.github.com/repos/opencontainers/runc/milestones{/number}","notifications_url":"https://api.github.com/repos/opencontainers/runc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opencontainers/runc/labels{/name}","releases_url":"https://api.github.com/repos/opencontainers/runc/releases{/id}","created_at":"2015-06-05T23:30:45Z","updated_at":"2016-01-03T22:33:07Z","pushed_at":"2016-01-04T01:02:00Z","git_url":"git://github.com/opencontainers/runc.git","ssh_url":"git@github.com:opencontainers/runc.git","clone_url":"https://github.com/opencontainers/runc.git","svn_url":"https://github.com/opencontainers/runc","homepage":"","size":3752,"stargazers_count":2393,"watchers_count":2393,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":279,"mirror_url":null,"open_issues_count":69,"forks":279,"open_issues":69,"watchers":2393,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/opencontainers/runc/pulls/451"},"html":{"href":"https://github.com/opencontainers/runc/pull/451"},"issue":{"href":"https://api.github.com/repos/opencontainers/runc/issues/451"},"comments":{"href":"https://api.github.com/repos/opencontainers/runc/issues/451/comments"},"review_comments":{"href":"https://api.github.com/repos/opencontainers/runc/pulls/451/comments"},"review_comment":{"href":"https://api.github.com/repos/opencontainers/runc/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/opencontainers/runc/pulls/451/commits"},"statuses":{"href":"https://api.github.com/repos/opencontainers/runc/statuses/bc738fbe8b856aaeb0ef732be9a9b217d054d7ac"}}}}