From: Paul Moore <paul@paul-moore.com>
To: Wang Weiyang <wangweiyang2@huawei.com>
Cc: jmorris@namei.org, serge@hallyn.com, serge.hallyn@canonical.com,
akpm@linux-foundation.org, aris@redhat.com,
linux-security-module@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] device_cgroup: Roll back to original exceptions after copy failure
Date: Wed, 16 Nov 2022 18:33:53 -0500 [thread overview]
Message-ID: <CAHC9VhRa16htUXSN0AXrbUwadRa-qQv+UX8ZO_8W_z2eL=6trw@mail.gmail.com> (raw)
In-Reply-To: <20221025113101.41132-1-wangweiyang2@huawei.com>
On Tue, Oct 25, 2022 at 7:02 AM Wang Weiyang <wangweiyang2@huawei.com> wrote:
>
> When add the 'a *:* rwm' entry to devcgroup A's whitelist, at first A's
> exceptions will be cleaned and A's behavior is changed to
> DEVCG_DEFAULT_ALLOW. Then parent's exceptions will be copyed to A's
> whitelist. If copy failure occurs, just return leaving A to grant
> permissions to all devices. And A may grant more permissions than
> parent.
>
> Backup A's whitelist and recover original exceptions after copy
> failure.
>
> Fixes: 4cef7299b478 ("device_cgroup: add proper checking when changing default behavior")
> Signed-off-by: Wang Weiyang <wangweiyang2@huawei.com>
> ---
> security/device_cgroup.c | 33 +++++++++++++++++++++++++++++----
> 1 file changed, 29 insertions(+), 4 deletions(-)
Merged into lsm/next, but with a stable@vger tag. Normally I would
merge something like this into lsm/stable-X.Y and send it up to Linus
after a few days, but I'd really like this to spend some time in
linux-next before going up to Linus.
--
paul-moore.com
next prev parent reply other threads:[~2022-11-16 23:34 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-25 11:31 [PATCH] device_cgroup: Roll back to original exceptions after copy failure Wang Weiyang
2022-10-28 11:19 ` Paul Moore
2022-11-15 3:54 ` wangweiyang
2022-11-15 20:55 ` Paul Moore
2022-11-07 18:56 ` Aristeu Rozanski
2022-11-16 23:33 ` Paul Moore [this message]
2022-11-17 7:27 ` wangweiyang
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='CAHC9VhRa16htUXSN0AXrbUwadRa-qQv+UX8ZO_8W_z2eL=6trw@mail.gmail.com' \
--to=paul@paul-moore.com \
--cc=akpm@linux-foundation.org \
--cc=aris@redhat.com \
--cc=jmorris@namei.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=serge.hallyn@canonical.com \
--cc=serge@hallyn.com \
--cc=wangweiyang2@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;
as well as URLs for NNTP newsgroup(s).