All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
To: ebiederm@xmission.com
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 00/23] Removal of binary sysctl support
Date: Mon, 09 Nov 2009 09:12:15 +0900	[thread overview]
Message-ID: <200911090012.nA90CF2i016994@www262.sakura.ne.jp> (raw)
In-Reply-To: <m1bpjch9hy.fsf@fess.ebiederm.org>

Eric W. Biederman wrote:
> There has been a gradual transition from the assumption that the table ends with
> !ctl_name to the assumption that procname == NULL.  There is no sysctl entry
> with a valid ctl_name without a valid procname.

I see. Then, please add below one to your patchset.

Regards.
----------
[PATCH] sysctl security/tomoyo: Don't look at ctl_name

ctl_name field was removed. Always use procname field.

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
---
 security/tomoyo/tomoyo.c |   10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

--- security-testing-2.6.orig/security/tomoyo/tomoyo.c
+++ security-testing-2.6/security/tomoyo/tomoyo.c
@@ -122,15 +122,7 @@ static char *tomoyo_sysctl_path(struct c
 	*--end = '\0';
 	buflen--;
 	while (table) {
-		char num[32];
-		const char *sp = table->procname;
-
-		if (!sp) {
-			memset(num, 0, sizeof(num));
-			snprintf(num, sizeof(num) - 1, "=%d=", table->ctl_name);
-			sp = num;
-		}
-		if (tomoyo_prepend(&end, &buflen, sp) ||
+		if (tomoyo_prepend(&end, &buflen, table->procname) ||
 		    tomoyo_prepend(&end, &buflen, "/"))
 			goto out;
 		table = table->parent;

  reply	other threads:[~2009-11-09  0:12 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-08 12:20 [PATCH 00/23] Removal of binary sysctl support Eric W. Biederman
2009-11-08 13:15 ` Tetsuo Handa
2009-11-08 23:39   ` Eric W. Biederman
2009-11-09  0:12     ` Tetsuo Handa [this message]
2009-11-09  0:35       ` Eric W. Biederman
2009-11-18 18:44       ` Eric W. Biederman
2009-11-18 22:04         ` Tetsuo Handa
2009-11-18 22:45           ` Eric W. Biederman
2009-11-19 14:33             ` Tetsuo Handa
2009-11-19 17:49               ` Eric W. Biederman
2009-11-19 22:17                 ` Tetsuo Handa
2009-11-19 22:22                   ` Eric W. Biederman
2009-11-19 22:35                     ` John Johansen
  -- strict thread matches above, loose matches on Subject: below --
2009-11-08 12:16 Eric W. Biederman
2009-11-08 13:06 ` Arnd Bergmann
2009-11-09  3:44   ` Eric W. Biederman
2009-11-08 12:15 Eric W. Biederman

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=200911090012.nA90CF2i016994@www262.sakura.ne.jp \
    --to=penguin-kernel@i-love.sakura.ne.jp \
    --cc=ebiederm@xmission.com \
    --cc=linux-kernel@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.