public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Casey Schaufler <casey@schaufler-ca.com>
To: Rafal Krypa <r.krypa@samsung.com>
Cc: linux-security-module@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Casey Schaufler <casey@schaufler-ca.com>
Subject: Re: [PATCH] Smack: prevent revoke-subject from failing when unseen label is written to it
Date: Tue, 27 Nov 2012 09:22:57 -0800	[thread overview]
Message-ID: <50B4F6F1.7020800@schaufler-ca.com> (raw)
In-Reply-To: <1354030091-32501-1-git-send-email-r.krypa@samsung.com>

On 11/27/2012 7:28 AM, Rafal Krypa wrote:
> Special file /smack/revoke-subject will silently accept labels that are not
> present on the subject label list. Nothing has to be done for such labels,
> as there are no rules for them to revoke.
>
> Targeted for git://git.gitorious.org/smack-next/kernel.git

I will queue this for 3.9 as I've just submitted the 3.8 Smack
changes.

>
> Signed-off-by: Rafal Krypa <r.krypa@samsung.com>
> ---
>  security/smack/smackfs.c |    4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/security/smack/smackfs.c b/security/smack/smackfs.c
> index 76a5dca..337e32c 100644
> --- a/security/smack/smackfs.c
> +++ b/security/smack/smackfs.c
> @@ -2035,10 +2035,8 @@ static ssize_t smk_write_revoke_subj(struct file *file, const char __user *buf,
>  	}
>  
>  	skp = smk_find_entry(cp);
> -	if (skp == NULL) {
> -		rc = -EINVAL;
> +	if (skp == NULL)
>  		goto free_out;
> -	}
>  
>  	rule_list = &skp->smk_rules;
>  	rule_lock = &skp->smk_rules_lock;


  reply	other threads:[~2012-11-27 17:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-27 15:28 [PATCH] Smack: prevent revoke-subject from failing when unseen label is written to it Rafal Krypa
2012-11-27 17:22 ` Casey Schaufler [this message]
2013-01-09 19:16 ` Casey Schaufler

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=50B4F6F1.7020800@schaufler-ca.com \
    --to=casey@schaufler-ca.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=r.krypa@samsung.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