mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Li Zefan <lizefan@huawei.com>
Cc: LSM <linux-security-module@vger.kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Cgroups <cgroups@vger.kernel.org>,
	Containers <containers@lists.linux-foundation.org>,
	Casey Schaufler <casey@schaufler-ca.com>,
	Ivan Bulatovic <combuster@archlinux.us>
Subject: Re: [PATCH] cgroup: initialize xattr before calling d_instantiate()
Date: Tue, 14 May 2013 08:38:10 -0700	[thread overview]
Message-ID: <20130514153810.GD6795@mtj.dyndns.org> (raw)
In-Reply-To: <51922394.2020002@huawei.com>

On Tue, May 14, 2013 at 07:44:20PM +0800, Li Zefan wrote:
> cgroup_create_file() calls d_instantiate(), which may decide to look
> at the xattrs on the file. Smack always does this and SELinux can be
> configured to do so.
> 
> But cgroup_add_file() didn't initialize xattrs before calling
> cgroup_create_file(), which finally leads to dereferencing NULL
> dentry->d_fsdata.
> 
> This bug has been there since cgroup xattr was introduced.
> 
> Cc: <stable@vger.kernel.org> # 3.8.x
> Reported-by: Ivan Bulatovic <combuster@archlinux.us>
> Reported-by: Casey Schaufler <casey@schaufler-ca.com>
> Signed-off-by: Li Zefan <lizefan@huawei.com>

Applied to cgroup/for-3.10-fixes.

Thanks.

-- 
tejun

      reply	other threads:[~2013-05-14 15:38 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-14 11:44 Li Zefan
2013-05-14 15:38 ` Tejun Heo [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130514153810.GD6795@mtj.dyndns.org \
    --to=tj@kernel.org \
    --cc=casey@schaufler-ca.com \
    --cc=cgroups@vger.kernel.org \
    --cc=combuster@archlinux.us \
    --cc=containers@lists.linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=lizefan@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®