All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul Moore <paul@paul-moore.com>
To: selinux@vger.kernel.org
Cc: rsiddoji@codeaurora.org, Stephen Smalley <sds@tycho.nsa.gov>,
	linux-security-module@vger.kernel.org
Subject: Re: [RFC PATCH] selinux: ensure we cleanup the internal AVC counters on error in avc_insert()
Date: Mon, 9 Dec 2019 20:54:43 -0500	[thread overview]
Message-ID: <CAHC9VhSoY3amLrsuzSOcu3NogehOhVj9KoiuxiN-vGtCVtLR2g@mail.gmail.com> (raw)
In-Reply-To: <157594281322.676903.11041338053333686450.stgit@chester>

On Mon, Dec 9, 2019 at 8:53 PM Paul Moore <paul@paul-moore.com> wrote:
> In AVC insert we don't call avc_node_kill() when avc_xperms_populate()
> fails, resulting in the avc->avc_cache.active_nodes counter having a
> false value.  This patch corrects this problem and does some cleanup
> in avc_insert() while we are there.
>
> Reported-by: rsiddoji@codeaurora.org
> Suggested-by: Stephen Smalley <sds@tycho.nsa.gov>
> Signed-off-by: Paul Moore <paul@paul-moore.com>
> ---
>  security/selinux/avc.c |   51 +++++++++++++++++++++++-------------------------
>  1 file changed, 24 insertions(+), 27 deletions(-)

FYI, only compiled tested, thus the RFC.

-- 
paul moore
www.paul-moore.com

  reply	other threads:[~2019-12-10  1:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-10  1:53 [RFC PATCH] selinux: ensure we cleanup the internal AVC counters on error in avc_insert() Paul Moore
2019-12-10  1:54 ` Paul Moore [this message]
2019-12-10 13:44 ` Stephen Smalley
2019-12-10 15:54   ` Paul Moore
2019-12-10 16:12     ` Stephen Smalley
2019-12-10 19:19       ` Paul Moore

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=CAHC9VhSoY3amLrsuzSOcu3NogehOhVj9KoiuxiN-vGtCVtLR2g@mail.gmail.com \
    --to=paul@paul-moore.com \
    --cc=linux-security-module@vger.kernel.org \
    --cc=rsiddoji@codeaurora.org \
    --cc=sds@tycho.nsa.gov \
    --cc=selinux@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.