From: Vasiliy Kulikov <segooon@gmail.com>
To: linux-kernel@vger.kernel.org,
linux-security-module@vger.kernel.org,
Ingo Molnar <mingo@elte.hu>,
Peter Zijlstra <peterz@infradead.org>,
kernel-hardening@lists.openwall.com
Subject: [kernel-hardening] How to temporary change 'current' (task)
Date: Fri, 17 Jun 2011 12:36:51 +0400 [thread overview]
Message-ID: <20110617083651.GA5625@albatros> (raw)
Hi,
I wonder whether there is a simple way to temporary switch 'current' to
another task and then switch it back with minimum side effects? I need
it to call "reversed" ptrace_may_access() with swapped current and
target task. Introducing ptrace_task_may_access_me() would produce too
much noise in LSM (it also needs reversed security_ptrace_access_check()),
which is too loud for my needs.
Specifically, I need it to filter taskstats and proc connector requests
for a restriction of getting other processes' information:
http://permalink.gmane.org/gmane.linux.kernel/1155354
As the check is handled in the context of the ptrace target process,
ptrace_may_access() doesn't fit my needs.
Thanks,
--
Vasiliy
WARNING: multiple messages have this Message-ID (diff)
From: Vasiliy Kulikov <segooon@gmail.com>
To: linux-kernel@vger.kernel.org,
linux-security-module@vger.kernel.org,
Ingo Molnar <mingo@elte.hu>,
Peter Zijlstra <peterz@infradead.org>,
kernel-hardening@lists.openwall.com
Subject: How to temporary change 'current' (task)
Date: Fri, 17 Jun 2011 12:36:51 +0400 [thread overview]
Message-ID: <20110617083651.GA5625@albatros> (raw)
Hi,
I wonder whether there is a simple way to temporary switch 'current' to
another task and then switch it back with minimum side effects? I need
it to call "reversed" ptrace_may_access() with swapped current and
target task. Introducing ptrace_task_may_access_me() would produce too
much noise in LSM (it also needs reversed security_ptrace_access_check()),
which is too loud for my needs.
Specifically, I need it to filter taskstats and proc connector requests
for a restriction of getting other processes' information:
http://permalink.gmane.org/gmane.linux.kernel/1155354
As the check is handled in the context of the ptrace target process,
ptrace_may_access() doesn't fit my needs.
Thanks,
--
Vasiliy
next reply other threads:[~2011-06-17 8:36 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-17 8:36 Vasiliy Kulikov [this message]
2011-06-17 8:36 ` How to temporary change 'current' (task) Vasiliy Kulikov
2011-06-17 8:59 ` [kernel-hardening] " Solar Designer
2011-06-17 9:25 ` Vasiliy Kulikov
2011-06-17 10:01 ` Vasiliy Kulikov
2011-06-17 10:11 ` Vasiliy Kulikov
2011-06-17 9:29 ` [kernel-hardening] " Peter Zijlstra
2011-06-17 9:29 ` Peter Zijlstra
2011-06-17 9:56 ` [kernel-hardening] " Vasiliy Kulikov
2011-06-17 9:56 ` Vasiliy Kulikov
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=20110617083651.GA5625@albatros \
--to=segooon@gmail.com \
--cc=kernel-hardening@lists.openwall.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.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.