linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chuck Ebbert <76306.1226@compuserve.com>
To: Bernhard Kaindl <bk@suse.de>, Jeff Dike <jdike@karaya.com>,
	Matthew Grant <grantma@anathoth.gen.nz>
Cc: linux-kernel <linux-kernel@vger.kernel.org>
Subject: [patch] Fix -EPERM returned by kernel_thead() if traced...
Date: Mon, 12 May 2003 21:57:30 -0400	[thread overview]
Message-ID: <200305122200_MC3-1-3890-B10A@compuserve.com> (raw)

Bernhard Kaindl wrote:

> -     task_lock(task);
> -     if (task->ptrace) {
> -             task_unlock(task);
> -             return -EPERM;
> -     }
> -
>       old_task_dumpable = task->task_dumpable;
> +     /* prevent ptrace_attach() on the new task: */
>       task->task_dumpable = 0;
> -     task_unlock(task);

  Is it safe to remove the task_lock()?


>  So I really have to assume that CLONE_PTRACE is never passed
>  to create a kernel thread. If you are paranoid, you could just
>  unmask it in kernel_thread() if you want.

  I would mask it if it's a possible problem.  Someone might
try to pass that option in future code...



             reply	other threads:[~2003-05-13  1:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-13  1:57 Chuck Ebbert [this message]
2003-05-13 16:18 ` [patch] Fix -EPERM returned by kernel_thead() if traced Bernhard Kaindl
  -- strict thread matches above, loose matches on Subject: below --
2003-05-13  0:43 Bernhard Kaindl

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=200305122200_MC3-1-3890-B10A@compuserve.com \
    --to=76306.1226@compuserve.com \
    --cc=bk@suse.de \
    --cc=grantma@anathoth.gen.nz \
    --cc=jdike@karaya.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 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).